aboutsummaryrefslogtreecommitdiff
path: root/lib/Target/CBackend/CBackend.cpp
AgeCommit message (Collapse)Author
2003-04-23Fix problem where labels were being incorrectly elided, and fix problemChris Lattner
where PHI copies where not emitted for the default label of switch insts git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5882 91177308-0d34-0410-b5e6-96231b3b80d8
2003-04-23Fix the super obnoxious "cast to pointer from integer of different size" ↵Chris Lattner
warnings git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5881 91177308-0d34-0410-b5e6-96231b3b80d8
2003-04-23Remove unneccesary &*Chris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5871 91177308-0d34-0410-b5e6-96231b3b80d8
2003-04-22Add support for the switch instruction to the CWriterChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5847 91177308-0d34-0410-b5e6-96231b3b80d8
2003-02-12Fixed alloca declaration problem on sun.Joel Stanley
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5546 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-20 - Eliminated the deferred symbol table stuff in Module & Function, it reallyChris Lattner
wasn't an optimization and it was causing lots of bugs. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4779 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-18*** empty log message ***Nick Hildenbrandt
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4754 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-18*** empty log message ***Nick Hildenbrandt
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4745 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-07_REALLY_ fix the float constant problemChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4609 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-07Print out 'float' constants correctlyChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4607 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-06Fixes escapeing bug in strings. Fixes test case ↵Nick Hildenbrandt
test/Regression/CBackend/2002-11-06-PrintEscaped.c git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4583 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-06Loads and stores can't be inlined. This fixes test/Singlesource/matrixTransposeNick Hildenbrandt
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4579 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-01Fixed bug in Regression/CBackend/2002-10-30-FunctionPointerAlloca.llNick Hildenbrandt
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4486 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28Casting NULL can cause problems so lets just not cast NULL to anything.Nick Hildenbrandt
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4349 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28*** empty log message ***Nick Hildenbrandt
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4343 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-23Malloc prototyping now works even if the original file had its own prototype ↵Nick Hildenbrandt
for malloc git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4271 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-16Fix bug: CBackend/2002-10-16-External.llChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4201 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-16Fix bug: test/Regression/CBackend/2002-10-15-OpaqueTypeProblem.llChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4190 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-11Instead of adding stdlib we just prototype malloc correctly.Nick Hildenbrandt
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4118 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-11Sun requires you to include stdlib to use mallocNick Hildenbrandt
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4117 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-05Bug fix: In preventing static global variables from being printed twice,Vikram S. Adve
I also prevented external globals from being printed twice, but they should (extern declaration and definition). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4043 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-03Add parens around constant calls to getelemptr to properly associate the ↵Nick Hildenbrandt
reference git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4032 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-02I was wrong on the removing of those references on the last commit.Nick Hildenbrandt
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4023 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-02Removed unneeded reference and dereferences.Nick Hildenbrandt
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4016 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-02Cleaned up my last check-in.Nick Hildenbrandt
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4014 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-02No longer include malloc.h. If protoypes are needed for memory functions ↵Nick Hildenbrandt
they will be present in the byte code and the generated c as well. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4013 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-30Fixed to properly escape quotes in strings.Nick Hildenbrandt
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3991 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-25Strings now handled correctly.Nick Hildenbrandt
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3920 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-23Parenthesis are now added to casts of type array.Nick Hildenbrandt
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3892 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-20Fix cwriter to not output FP constants in ascii, output them in hex instead.Chris Lattner
This fixes a number of FP precision problems, making the output of the power benchmark closer to the right answer. Unfortunately, this only addresses FP constants used directly in functions. Constants referred to by global constants (such as an array of FP values) aren't helped by this. Until this happens power won't work. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3871 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-20Fix bug: 2002-09-20-VarArgPrototypes.llChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3870 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-20Fix output of typedefs to avoid syntax errors.Chris Lattner
* We now can correctly Cify the Olden-power benchmark git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3860 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-20* Add a couple of comments to the output c codeChris Lattner
* _FIX_ infinite recursion problem, due to typedefs of a structure being printed before the structure. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3859 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-20Another change that doesn't affect functionality. Since we are only lookingChris Lattner
at types in the symbol table, only traverse the type plane, saving a loop nest. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3858 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-20Make the StructPrinted set only take memory when it's being used.Chris Lattner
rename parseStruct to printContainedStructs git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3857 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-20No functionality changes, primarily just changing tab indentation to spaceChris Lattner
indentation git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3856 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-17Don't print global variable definitions twice! Sun's pathetic compilerVikram S. Adve
never complained about this. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3774 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-15No longer need to sign-extend array indices to 64 bits since theyVikram S. Adve
are now longs and not unsigned ints. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3731 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-14Fixed problem with printing struct definitions in the correct order.Nick Hildenbrandt
This allows for the Regression/Transforms/ScalarReplacement/scalarize.c to run correctly. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3721 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-12Fix a bug introduced by the Getelementptr changeChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3695 91177308-0d34-0410-b5e6-96231b3b80d8
2002-09-11 - Change getelementptr instruction to use long indexes instead of uintChris Lattner
indexes for sequential types. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3681 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-31 - Fix bug: test/Regression/CBackend/2002-08-20-RecursiveTypes.llChris Lattner
- Converted CWriter to be an LLVM pass. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3558 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-26Fix bug: test/Regression/CBackend/2002-08-26-IndirectCallTest.llChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3511 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-25Fix the way parens are printed around "*ptrName" so thatVikram S. Adve
no parens are printed around *, **, ... alone, except if it is a pointer type for which no name should be printed, as in the result of a cast. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3506 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-24Sign-extend array index expressions to work correctly on non-32 bit machines.Vikram S. Adve
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3496 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-23Changed default value of 3rd parameter in function definitionAnand Shukla
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3492 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-22Load & StoreInst no longer derive from MemAccessInst, so we don't haveChris Lattner
to handle indexing anymore git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3484 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-20Fix bug: 2002-08-20-UnnamedArgument.cChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3401 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-19Implement ConstantExprs in CWriterChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3394 91177308-0d34-0410-b5e6-96231b3b80d8
2002-08-19Incorporate calcTypeNameVar into CWriter class, fixingChris Lattner
test/Regression/CBackend/2002-08-19-FunctionPointer.c in the process git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3392 91177308-0d34-0410-b5e6-96231b3b80d8