summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGen
Commit message (Collapse)AuthorAgeFilesLines
* Add CodeGen support for alignment on globals, both for unusual natural Eli Friedman2008-05-291-0/+4
| | | | | | alignment and alignment attributes. llvm-svn: 51676
* Tentative declarations are supposed to have common linkage, not weak. Eli Friedman2008-05-291-1/+1
| | | | | | This change makes clang generate the same thing as llvm-gcc. llvm-svn: 51674
* Always use packed structs. This isn't really very nice, but there's Eli Friedman2008-05-292-12/+13
| | | | | | | | | | | | | nothing fundamentally wrong with it. Emitting unpacked structs where possible is more work for almost no practical benefit. We'll probably want to fix it at some point anyway, but it's low priority. The issue with long double in particular is that LLVM thinks an X86 long double is 10 bytes, while clang considers it for all purposes to be either 12 or 16 bytes, depending on the platform, even in a packed struct. llvm-svn: 51673
* Check first member alignment and uses packed struct if required.Devang Patel2008-05-271-0/+3
| | | | llvm-svn: 51619
* Fix test caseDevang Patel2008-05-271-0/+1
| | | | llvm-svn: 51618
* A few more cases for aggregate values.Eli Friedman2008-05-271-0/+14
| | | | llvm-svn: 51596
* Implementation of __builtin_ctlz.Eli Friedman2008-05-271-0/+4
| | | | llvm-svn: 51595
* Don't swap function decls, and add them to the scope as they are Eli Friedman2008-05-271-0/+12
| | | | | | | | | | | | | encountered. Mixing up the decls is unintuitive, and confuses the AST destruction code. Fixes PR2360. Note that there is a need to look up the characteristics and declarations of a function associated with a particular name or decl, but the original swapping code doesn't solve it properly. http://lists.cs.uiuc.edu/pipermail/cfe-dev/2008-May/001644.html is one suggestion for how to fix that. llvm-svn: 51584
* Add a more reliable check for whether a static declaration has already Eli Friedman2008-05-271-0/+5
| | | | | | | been used. In preparation for the fix to PR2360, but also a minor bug in its own right. llvm-svn: 51583
* Generalize the float type generation code, and specifically fix the Eli Friedman2008-05-271-0/+4
| | | | | | codegen of X86 long double. llvm-svn: 51578
* A small testcase; no patch, since it was a bug in a patch I never Eli Friedman2008-05-211-0/+5
| | | | | | committed. llvm-svn: 51370
* Fix test (it was incorrectly succeeding).Eli Friedman2008-05-201-9/+2
| | | | llvm-svn: 51310
* Add codegen support for stack address intrinsics.Eli Friedman2008-05-201-0/+16
| | | | llvm-svn: 51309
* Implement codegen for comma operator for structs.Eli Friedman2008-05-201-0/+4
| | | | llvm-svn: 51304
* Implement CodeGen for __builtin_memcpy.Eli Friedman2008-05-191-0/+3
| | | | llvm-svn: 51282
* Remove illegal test.Eli Friedman2008-05-191-1/+0
| | | | llvm-svn: 51267
* Fix the emission of expressions like char a[10] = "asdf"; previously, Eli Friedman2008-05-191-0/+8
| | | | | | | | they were causing bad code to be emitted. There are two fixes here: one makes sure we emit a string that is long enough, and one makes sure we properly handle string initialization in init lists. llvm-svn: 51259
* Fix support for _Bool bitfields. The issue is that the bitfield width Eli Friedman2008-05-171-0/+54
| | | | | | | | | | | | used for _Bool is not the same as the primitive width (which for _Bool is 1 bit). The load and store changes add some casts to make the types consistent. The EmitLValue changes make sure that the pointer is of an appropriate type for loading the bitfield. This isn't perfect, but it's an improvement, and getting everything right depends on actually laying out structs in an ABI-compliant way. llvm-svn: 51224
* Patch for PR2334, and a similar ObjC bug.Eli Friedman2008-05-161-0/+5
| | | | llvm-svn: 51193
* Implementation of __builtin_shufflevector, a portable builtin capable of Eli Friedman2008-05-141-0/+5
| | | | | | | | | expressing the full flexibility of the LLVM shufflevector instruction. The expected immediate usage is in *mmintrin.h, so that they don't depend on the mess of gcc-inherited (and not completely implemented) shuffle builtins. llvm-svn: 51113
* Add codegen support for block-level compound literals.Eli Friedman2008-05-131-0/+13
| | | | llvm-svn: 51081
* Emit basic block for switch body; fixes PR2307.Eli Friedman2008-05-121-0/+11
| | | | llvm-svn: 50968
* Don't try to take the address of a bitfield; fixes PR2310.Eli Friedman2008-05-121-0/+8
| | | | llvm-svn: 50966
* Added support to generate some atomic operators (add, sub, and, or etc..)Mon P Wang2008-05-091-0/+35
| | | | llvm-svn: 50919
* Begin handling union bitfields.Devang Patel2008-05-071-0/+5
| | | | | | Note, this is just beginning. llvm-svn: 50835
* Fix PR2101 - Codegen crash during bitfield initialization.Devang Patel2008-05-061-0/+4
| | | | llvm-svn: 50769
* add a testcaseChris Lattner2008-05-041-1/+9
| | | | llvm-svn: 50608
* remove the 'unused static' diagnostic from codegen. This should be Chris Lattner2008-04-251-7/+0
| | | | | | | reimplemented in Sema someday. This is tracked in PR2236. Until then disabling it removes some bogus diagnostics (see 2236). llvm-svn: 50263
* Fix PR2236Nate Begeman2008-04-201-0/+7
| | | | | | | Add test Implement feedback from Chris re: PR1998 llvm-svn: 50001
* OCUVector -> ExtVector, shorthand for extended vector, per feedback from Chris.Nate Begeman2008-04-181-2/+2
| | | | llvm-svn: 49942
* this started failing because a GEP was constant folded, Chris Lattner2008-04-131-1/+3
| | | | | | improve the robustness of the test. llvm-svn: 49618
* Add support for C++ default arguments, and rework Parse-Sema Chris Lattner2008-04-081-0/+25
| | | | | | | | interaction for function parameters, fixing PR2046. Patch by Doug Gregor! llvm-svn: 49369
* Fix PR2049, updating Eli's patch that fixes to mainline. This produces ↵Chris Lattner2008-04-041-1/+13
| | | | | | | | incorrect code, but the codegen doesn't crash. I'll file a bugzilla for the AST being wrong. llvm-svn: 49226
* Since isComplexType() no longer returns true for _Complex integers, the codeChris Lattner2008-04-041-1/+6
| | | | | | generator needs to call isAnyComplexType(). This fixes PR1960. llvm-svn: 49220
* Fix PR2081 (problems codegen'ing some recursive structures) patchChris Lattner2008-04-031-0/+13
| | | | | | by Lauro Venancio! llvm-svn: 49144
* Fix several bugs in array -> pointer decomposition.Chris Lattner2008-04-021-1/+1
| | | | | | | | | | | | | | | | First, we got several CVR propagation cases wrong, which Eli pointed out in PR2039. Second, we didn't propagate address space qualifiers correctly, leading to incorrect lowering of code in CodeGen/address-space.c. Third, we didn't uniformly propagate the specifier in the array to the pointer ("int[restrict 4]" -> "int *restrict"). This adds an ASTContext::getArrayDecayedType member that handles the non-trivial logic for this seemingly simple operation. llvm-svn: 49078
* The operand to the visibility attribute is required to be a quoted string, ↵Chris Lattner2008-03-041-2/+2
| | | | | | not a bare identifier. llvm-svn: 47893
* The attribute nothrow maps to llvm attribute nounwind. Fix testcase.Gabor Greif2008-03-031-1/+1
| | | | llvm-svn: 47841
* fix codegen support for functions that are nothrow and noreturn.Chris Lattner2008-03-031-0/+5
| | | | llvm-svn: 47838
* Add a bunch of attributes, patch by Nuno Lopes.Chris Lattner2008-03-031-0/+21
| | | | llvm-svn: 47837
* Implement codegen for the following static var init.Lauro Ramos Venancio2008-02-261-1/+6
| | | | | | | | | | | void g() { static char a[10]; static char *b = a; } Now we can compile wget! llvm-svn: 47627
* Fix a bug in ConvertAsmString function. Lauro Ramos Venancio2008-02-261-0/+6
| | | | llvm-svn: 47618
* Convert x86 target specific inline asm constraints to LLVM.Lauro Ramos Venancio2008-02-261-0/+15
| | | | llvm-svn: 47609
* Some const initializer tests for stuff I just committed.Eli Friedman2008-02-211-0/+13
| | | | llvm-svn: 47442
* implement codegen support for sizeof(void), fixing PR2080.Chris Lattner2008-02-211-0/+11
| | | | llvm-svn: 47429
* Simplify aggregate initilizer implementation. Use the ↵Lauro Ramos Venancio2008-02-191-0/+1
| | | | | | | | | CodeGenModule::EmitConstantExpr method when possible. Fix mediabench/mpeg2/mpeg2dec test. llvm-svn: 47336
* A global without initializer must be emitted as weak.Lauro Ramos Venancio2008-02-191-0/+3
| | | | | | Fix Olden/bh test. llvm-svn: 47292
* Implement multi-dimension array initalizer.Lauro Ramos Venancio2008-02-181-5/+12
| | | | | | Fix McCat/08-main test. llvm-svn: 47286
* implement codegen support for aggregates casted to void.Chris Lattner2008-02-161-1/+6
| | | | llvm-svn: 47226
* Implement extern block var.Lauro Ramos Venancio2008-02-161-0/+6
| | | | llvm-svn: 47223
OpenPOWER on IntegriCloud