search for: bc_from_api

Displaying 3 results from an estimated 3 matches for "bc_from_api".

2015 Aug 22
3
loop unrolling introduces conditional branch
Hi, Mehdi, For example, I have this very simple source code: void foo( int n, int array_x[]) { for (int i=0; i < n; i++) array_x[i] = i; } After I use "clang -emit-llvm -o bc_from_clang.bc -c try.cc", I get bc_from_clang.bc. With my code (using LLVM IRbuilder API), I get bc_from_api.bc. Attachment please find thse two files. I also past the IR here. ******************************** Clang Generate IR Start *********************************************************** ; ModuleID = 'bc_from_clang.bc' target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128" targ...
2015 Aug 22
2
loop unrolling introduces conditional branch
...ery simple source code: > void foo( int n, int array_x[]) > { > for (int i=0; i < n; i++) > array_x[i] = i; > } > > After I use "clang -emit-llvm -o bc_from_clang.bc -c try.cc", I get > bc_from_clang.bc. With my code (using LLVM IRbuilder API), I get > bc_from_api.bc. Attachment please find thse two files. I also past the IR > here. > ******************************** Clang Generate IR Start > *********************************************************** > ; ModuleID = 'bc_from_clang.bc' > target datalayout = "e-m:e-i64:64-f80:128-n8...
2015 Aug 22
2
loop unrolling introduces conditional branch
Hi, I just tried llvm-3.8 (LLVM SVN Repository). With this version, -fno-rtti can help me to compile my code and -irce can help me to do a better job for loop unrolling. However, I still have one question. If I use Clang to compile a piece of c++ code to .bc and then use 'opt -loop-rotate -loop-unroll -irce', I can get what I want. I mean, there is no conditional branch at the end of each