search for: hanfengtsin

Displaying 6 results from an estimated 6 matches for "hanfengtsin".

2011 Dec 20
0
[LLVMdev] Loop exit condition analysis
On Mon, Dec 19, 2011 at 10:13 PM, Hanfeng Qin <hanfengtsin at gmail.com> wrote: > Hi all, > I am doing loop exit condition analysis. As the following sample code > segments demonstrated, > > .... > int *c = &a; > while (*c == 0); > .... > > I want to decide which variables are related to ending this spin-loop. E.g., &gt...
2011 Dec 20
2
[LLVMdev] Loop exit condition analysis
Hi all, I am doing loop exit condition analysis. As the following sample code segments demonstrated, .... int *c = &a; while (*c == 0); .... I want to decide which variables are related to ending this spin-loop. E.g., in above sample, c is the direct variable while a is an indirect one. Does LLVM provide any existing analysis tools or APIs I can leverage? I am new to compiler
2011 Sep 25
0
[LLVMdev] POSIX thread library support
Hi chenwj, According to the link, I found that during the compiling process, the option "-emit-llvm" must be added to generate immediate object *.o. [hanfeng at os-wstation02 fft]llvm-gcc -c fft.c -emit-llvm Then using llvm-ld will generate two files - a shell excutable and a llvm bytecode data both of which would run perfect. [hanfeng at os-wstation02 fft]llvm-ld -o FFT fft.o [hanfeng
2011 Sep 26
0
[LLVMdev] POSIX thread library support
Hi chenwj, For the first question, even if I did not specify "-o fft.bc", it still generated fft.o which is also a llvm bitcode file. For the second question, I intended to generate a native executable "FFT". However, it only generate a llvm bitcode file fft.bc and a native POSIX shell excuatable named fft. Howerver, the contents of the shell executable fft is a wrapper to call
2011 Dec 27
1
[LLVMdev] compounding loop exit conditions
Hi all, I got a question on loop exit condition identification based on LLVM. I made an assumption first that loop exit conditions are located in exiting basic blocks. Then I use loop->getExitingBlocks() to get all BBs. However, this policy seemed not work for combinational exit conditions, e.g. compounding conditions consists of conditions with logical predicates. *The problem is that
2011 Sep 25
3
[LLVMdev] POSIX thread library support
Hello all, I caught a problem related to pthread library. I built llvm and llvm-gcc then compiling a multithreaded benchmark written in POSIX thread library. The command "llvm-gcc -o bench bench.c -lpthread" ran well while "llvm-gcc -c bench; llvm-ld -o bench bench.o -lpthread" crashed. It told that "llvm-ld: error: Cannot find library 'pthread'". I could