stdlib.h
I've discovered why so many tests were failing: my cfrontend was wrong. My version of LLVM does not compile anything that imports stdlib.h. I sort of fixed this by copying the sources from the gcc compiler in my OS (gcc 4.0.1) to
I just remember that this may be important: besides my own source code, I am changing the following files from LLVM:
cfrontend/ ppc/ llvm-gcc/ lib/gcc/ powerpc-apple-darwin8.5.0/ 3.4-llvm/ old_include/ stdlib.h
. It seems that it solved this problem, but there are some other problems when compiling cpp
files. I tried many tests by hand, using this script. My compiler passed all of them, with the new gcc front end. Also, I discovered another bug: I am not handling the translation of two address instructions. Now I think I am handling it, at least for the Power PC architecture. I implemented a small pass to make this conversion, after register allocation has been performed. The code is here: .cpp and .h. Actually, my compiler did not pass these tests: 2006-01-23-InitializedBitField.c, 2006-01-23-UnionInit.c
, but linear scan failed too, so I will assume that it is a bug in the platform.I just remember that this may be important: besides my own source code, I am changing the following files from LLVM:
include/llvm/Passes.h
include/llvm/Target/MRegisterInfo.h
lib/Target/X86/X86RegisterInfo.h
lib/Target/X86/X86RegisterInfo.h
lib/Target/PPC/PPCRegisterInfo.h
lib/Target/PPC/PPCRegisterInfo.h
lib/Target/PowerPC/PPCTargetMachine.cpp
lib/CodeGen/Passes.cpp
0 Comments:
Post a Comment
<< Home