Questions tagged [llvm-gcc]

llvm-gcc is a modified version of gcc that compiles C/ObjC programs into native objects, LLVM bitcode or LLVM assembly language, depending upon the options.

llvm-gcc is a modified version of gcc that compiles C/ObjC programs into native objects, LLVM bitcode or LLVM assembly language, depending upon the options.

218 questions
2
votes
0 answers

fatal error: 'bits/c++config.h' file not found

I am getting the following error when I compile STABILIZER: fatal error: 'bits/c++config.h' file not found. I am using ubuntu14.04,gcc-4.6.
Tang Wendy
  • 21
  • 1
2
votes
2 answers

LLVM-GCC ASM to LLVM in XCode

I got the 2 following definition that compile (and work) just fine using XCode LLVM-GCC compiler: #define SAVE_STACK(v)__asm { mov v, ESP } #define RESTORE_STACK __asm {sub ESP, s } However when I change the compiler to Apple LLVM I got the…
McBob
  • 1,011
  • 2
  • 13
  • 25
2
votes
1 answer

Difference between i686-apple-darwin11-llvm-gcc-4.2 and llvm-gcc-4.2

looking into /usr/llvm-gcc-4.2/bin I have 544416 Oct 31 17:10 i686-apple-darwin11-llvm-g++-4.2* 544416 Oct 31 17:10 i686-apple-darwin11-llvm-gcc-4.2* 117168 Oct 31 17:10 llvm-c++-4.2* 257552 Oct 31 17:10 llvm-cpp-4.2* 117168 Oct 31 17:10…
magopieri
  • 80
  • 8
2
votes
1 answer

klee with loops strange behaviour with similar code

I have a question about how is working KLEE (symbolic execution tool) in case of loops with symbolic parameters: int loop(int data) { int i, result=0; for (i=0;i
2
votes
1 answer

Why doesn't the compiler allocate and deallocate local var with "sub*" and "add*" on the stack?

According to some textbooks, the compiler will use sub* to allocate memory for local variables. For example, I write a Hello World program: int main() { puts("hello world"); return 0; } I guess this will be compiled to some assembly code on…
Ghjhdf
  • 161
  • 8
2
votes
3 answers

xcode 4.5, iOS 6.0 SDK Compile error - base.h

I upgraded from xcode 4.4.3 to 4.5 and can no longer build our application. I receive the following compile error in iOS 6.0 SDK…
imobilizer
  • 161
  • 1
  • 13
2
votes
0 answers

Apple gcc: What is the difference between /usr/bin/gcc-4.2 and /usr/bin/i686-apple-darwin11-llvm-gcc-4.2?

I'm running Lion. I have these two versions of gcc that both claim to be the same thing, but diff claims that the binaries differ. I am trying to understand the situation with gcc on OS X. What is the difference between them? $ /usr/bin/gcc-4.2…
speedarius
  • 1,006
  • 1
  • 8
  • 15
2
votes
2 answers

IOS: Library not found for -lz.1.2.3

I don't understand my error: Ld Library/Developer/Xcode/DerivedData/Test-aywxyvnakaqhmwfbwellynwqmoik/Build/Products/Debug-iphonesimulator/Test.app/Test normal i386 cd /Users/lol/Desktop/Test setenv MACOSX_DEPLOYMENT_TARGET 10.6 setenv PATH…
david55
  • 71
  • 6
1
vote
1 answer

Execute Openmp program in LLVM-3.0

I generated a .ll file using llvm-gcc for a Openmp program(written in c). Then Optimized using opt(version 3.0) But when I try to execute the optimized .ll file using lli or llvm-ld, getting the following errors, LLVM ERROR: Program used…
shashikiran
  • 369
  • 1
  • 5
  • 17
1
vote
1 answer

Strange compilation of inline assembly in LLVM GCC 4.2

I'm trying to optimize the following C macro: rotate(v0, v1) a0 = v0, b0 = v1, v0 = a0*c - b0*s, v1 = a0*s + b0*c where all variables are doubles for the Cortex-A8 processor. The inline assembly looks the following: __asm__…
Alex
  • 9,891
  • 11
  • 53
  • 87
1
vote
1 answer

LLVM on Mac OS X Lion

I am trying to make LLVM to work on my Mac. I want to write cpp code and generate LLVM IR. I have installed llvm-gcc42 and all the dependencies using MacPorts: expat @2.0.1_1 (active) gettext @0.18.1.1_2 (active) gmp @5.0.2_1 (active) gperf @3.0.4_2…
1
vote
3 answers

Why my program is receiving SIGABRT when I use OpenMP to make a for loop parallel?

I'm writing a scientific program to solve Maxwell's equation with C++. The task in data parallel and I want to use OpenMP to make the program parallel. But when I use OpenMP to parallelise a for loop in side a function it. When I run my code the…
Raiyan Kabir
  • 1,016
  • 2
  • 11
  • 23
1
vote
1 answer

Command /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/llvm-g++-4.2 failed with exit code 1

My XCode version is 4.2 for iOS 5.0. I choose "LLVM GCC 4.2" as the compiler. When I compile my project, it show me the following error: ld: warning: directory not found for option…
user901737
  • 11
  • 1
  • 3
1
vote
2 answers

How to hint types when compiling with llvm-gcc?

In some C code, I'm defining a simple static array as a function argument, say: void foo(float color[3]); When I compile it with llvm-gcc, it produces the following LLVM assembly language output: define void @foo(float* %n1) nounwind ssp { Is…
smokris
  • 11,740
  • 2
  • 39
  • 59
1
vote
1 answer

llvm IR use functions in libc

How does llvm IR use functions in libc, such as open socket, etc. is there a specific example,How does llvm IR use functions in libc, such as open socket, etc. is there a specific example,How does llvm IR use functions in libc, such as open socket,…
django
  • 29
  • 1