aboutsummaryrefslogtreecommitdiff
path: root/lib/Target/CBackend/CBackend.cpp
AgeCommit message (Collapse)Author
2003-10-23This commit was manufactured by cvs2svn to create branch 'release_1'.cvs2svn
git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_1@9439 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-23Fail gracefully if we have a zero arg varargs functionChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9436 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-20Added LLVM project notice to the top of every C++ source file.John Criswell
Header files will be on the way. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9298 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-18Add support for the new varargs intrinsics and instructionsChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9226 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-16Add support for 'weak' linkage.Chris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9171 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-15Decrease usage of use_size()Chris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9135 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-13Do not allow fallthroughs in switch statements. This fixes PR37,Chris Lattner
253.perlbmk, and test/Programs/SingleSource/UnitTests/2003-10-13-SwitchTest.c! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9101 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-13Use the autoconf macro John wroteChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9095 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-12* Spell "necessary" correctlyChris Lattner
* Print floating point values using C99 hexadecimal style FP if possible. This increases the number of floating point constants that may be emitted inline, and improves precision for global variable initializers which can not be emitted in integer form. This fixes the Olden/Power benchmark with the CBE!!!! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9052 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-12* Be TBAA safeChris Lattner
* Fix isFPCSafeToPrint to find more constants safe to print, which it was failing because ftostr was padding with leading space characters. * Scan the entire module for global constants instead of each function at a time. This has the advantage of allowing us to emit constants at global scope instead of function scope. This speeds FP programs quite a bit. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9048 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-05A couple of minor code cleanups.Chris Lattner
Print literal doubles using ftostr instead of <<, because it yields higher precision numbers. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8855 91177308-0d34-0410-b5e6-96231b3b80d8
2003-09-20Rename Function::getEntryNode -> getEntryBlockChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8625 91177308-0d34-0410-b5e6-96231b3b80d8
2003-09-15Fix problems with programs that prototype printf to something unusualChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8538 91177308-0d34-0410-b5e6-96231b3b80d8
2003-09-11Fixed spelling and grammar.Misha Brukman
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8489 91177308-0d34-0410-b5e6-96231b3b80d8
2003-09-10Remove a bunch of warnings from the CBE generated C codeChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8455 91177308-0d34-0410-b5e6-96231b3b80d8
2003-09-10"the one true solution for compatibility with GCC 3.3+"Chris Lattner
... or so I hope git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8454 91177308-0d34-0410-b5e6-96231b3b80d8
2003-09-08Eliminate support for the llvm.unwind intrinisic, using the Unwind ↵Chris Lattner
instruction instead git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8411 91177308-0d34-0410-b5e6-96231b3b80d8
2003-09-08Add support for the unwind instructionChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8408 91177308-0d34-0410-b5e6-96231b3b80d8
2003-08-28Fix really nasty bugs in the CWriter, handling invoke instructions. TrackingChris Lattner
these down was NOT phun. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8181 91177308-0d34-0410-b5e6-96231b3b80d8
2003-08-24Simplify codeChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8139 91177308-0d34-0410-b5e6-96231b3b80d8
2003-08-24Implement support for the unwind intrinsic in the CBEChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8116 91177308-0d34-0410-b5e6-96231b3b80d8
2003-08-18Add support for the sig(set|long)jmp intrinsicsChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7951 91177308-0d34-0410-b5e6-96231b3b80d8
2003-08-18Spell `necessary' correctly.Misha Brukman
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7944 91177308-0d34-0410-b5e6-96231b3b80d8
2003-08-14Stop annoying warnings about mismatched types with the argument of a freeChris Lattner
implement more constant expressions so that 176.gcc compiles with the CBE git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7847 91177308-0d34-0410-b5e6-96231b3b80d8
2003-08-06The HAVE_JUMP code is dead, these intrinsics should _never_ be expandedChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7642 91177308-0d34-0410-b5e6-96231b3b80d8
2003-07-31Unbreak the CBE outputChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7453 91177308-0d34-0410-b5e6-96231b3b80d8
2003-07-31Modified the code so that it generates (0) for setjmp() and abort() forJohn Criswell
longjmp() (and does not include setjmp.h). This is to fix some problems on Sparc while non-local jumps are still unimplemented. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7449 91177308-0d34-0410-b5e6-96231b3b80d8
2003-07-25Don't include llvm/SlotCalculator.h, or <set>.Brian Gaeke
Move up the inclusion of llvm/Support/Mangler.h. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7320 91177308-0d34-0410-b5e6-96231b3b80d8
2003-07-24Use unified CWriter-X86/Printer name mangler. Do not bother usingBrian Gaeke
SlotCalculator in CWriter. (Unfortunately, all this means a lot of X86/Printer's methods have to be de-constified again. Oh well.) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7299 91177308-0d34-0410-b5e6-96231b3b80d8
2003-07-23Fix program: SingleSource/UnitTests/2003-07-09-SignedArgs with the CBEChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7276 91177308-0d34-0410-b5e6-96231b3b80d8
2003-07-23Simplify code by using ConstantInt::getRawValue instead of checking to seeChris Lattner
whether the constant is signed or unsigned, then casting git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7252 91177308-0d34-0410-b5e6-96231b3b80d8
2003-07-21Eliminated dead code.Misha Brukman
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7209 91177308-0d34-0410-b5e6-96231b3b80d8
2003-07-09Some beautification changes (tabs to spaces, removed extra blank lines);Misha Brukman
no functionality changed. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7138 91177308-0d34-0410-b5e6-96231b3b80d8
2003-07-08Removed size_t from the parameter list of the malloc() prototype in generated CJohn Criswell
code. This prevents a compiler warning on Sparc that causes the tests to fail. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7125 91177308-0d34-0410-b5e6-96231b3b80d8
2003-06-28jmp_buf is really a pointer type that is passed around...Chris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6935 91177308-0d34-0410-b5e6-96231b3b80d8
2003-06-28Add support for the Invoke instruction!Chris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6934 91177308-0d34-0410-b5e6-96231b3b80d8
2003-06-28Preserve compatibility with non-gcc compilersChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6932 91177308-0d34-0410-b5e6-96231b3b80d8
2003-06-28Fix bug: CBackend/2003-06-28-LinkOnceGlobalVars.llxChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6931 91177308-0d34-0410-b5e6-96231b3b80d8
2003-06-25- Fixed name mangling conditions to handle 'linkonce' linkage type. InJoel Stanley
particular, name mangling for GlobalValues only occurs when the linkage type is internal or when the name must be mangled to avoid a collision. See comments in CWriter::getValueName for more information. - 'inline' keyword is now emitted for functions with 'linkonce' linkage type. - Fixed typos. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6898 91177308-0d34-0410-b5e6-96231b3b80d8
2003-06-25It seems likely that floats would need a cast too, because they areBrian Gaeke
ordinarily promoted to doubles. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6894 91177308-0d34-0410-b5e6-96231b3b80d8
2003-06-23Fix 2003-06-23-PromotedExprs.llx -- if we are adding two bytes we betterBrian Gaeke
explicitly cast the result to be a byte, or C will gleefully promote it to int. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6869 91177308-0d34-0410-b5e6-96231b3b80d8
2003-06-17lib/CWriter/Writer.cpp: Copy AsmWriter's ConstantFP checking code hereBrian Gaeke
into a new function FPCSafeToPrint(), and use it in printConstant() and printFunction() to decide whether we should output ConstantFPs as floating-point constants or as references to stack-allocated variables. lib/VMCore/AsmWriter.cpp: Fix an apparent typo in the code mentioned above. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6762 91177308-0d34-0410-b5e6-96231b3b80d8
2003-06-17Fairly major change: emit fixed sized allocas in the entry block as a variable,Chris Lattner
instead of a variable pointer and an alloca. All accesses to the variable then use the address-of operator to access it. This plays better with the internal GCC code generation phases, which bail early on functions which contain allocas. It also makes the code a bit easier to read. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6734 91177308-0d34-0410-b5e6-96231b3b80d8
2003-06-16Don't include alloca.h on FreeBSD.Brian Gaeke
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6728 91177308-0d34-0410-b5e6-96231b3b80d8
2003-06-16Fix typeoChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6704 91177308-0d34-0410-b5e6-96231b3b80d8
2003-06-16Fix bug: CBackend/2003-06-11-HexConstant.llChris Lattner
Fix bug: CBackend/2003-06-11-LiteralStringProblem.ll git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6697 91177308-0d34-0410-b5e6-96231b3b80d8
2003-06-06Don't output explicit initializers for globals that are zero initializedChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6651 91177308-0d34-0410-b5e6-96231b3b80d8
2003-06-02Fix bug: CBackend/2003-06-01-NullPointerType.llChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6526 91177308-0d34-0410-b5e6-96231b3b80d8
2003-06-01Fix a bug with casts to bool. This fixes testcase ↵Chris Lattner
UnitTests/2003-05-31-CastToBool.c git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6507 91177308-0d34-0410-b5e6-96231b3b80d8
2003-05-29Eliminate unnecessary ->get calls that are now automatically handled.Chris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6397 91177308-0d34-0410-b5e6-96231b3b80d8