summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen
Commit message (Collapse)AuthorAgeFilesLines
...
* Minor refactoring of my last patch.Fariborz Jahanian2010-05-111-4/+5
| | | | llvm-svn: 103475
* Initialize Column.Devang Patel2010-05-101-6/+12
| | | | llvm-svn: 103448
* Objective-C++ Code gen. Handle code gen. for propertyFariborz Jahanian2010-05-102-2/+20
| | | | | | | reference dot-syntax notation in a varierty of cases. Fixes radar 7964490. llvm-svn: 103440
* If variable location is invalid then use current location.Devang Patel2010-05-101-1/+3
| | | | | | This fixes radar 7959934. llvm-svn: 103408
* Tweaked selector mangling again (GNU runtime).David Chisnall2010-05-091-6/+17
| | | | llvm-svn: 103368
* Fixed linkage problem from last commit (GNU runtime).David Chisnall2010-05-081-2/+2
| | | | llvm-svn: 103355
* Tweaked selector generation (GNU runtime). Removed the use of GlobalAliases ↵David Chisnall2010-05-081-9/+15
| | | | | | in the generated bitcode. llvm-svn: 103353
* If there is not any debug info for type then do not emit debug info for this ↵Devang Patel2010-05-071-0/+5
| | | | | | | | | variable. A recent change to tightly verify debug info prepared by FE caught this. This fixes unittest build. llvm-svn: 103320
* Minor mod. to my last patch.Fariborz Jahanian2010-05-071-1/+2
| | | | llvm-svn: 103280
* Fixes a Code gen crash trying to use a dot-syntax forFariborz Jahanian2010-05-071-2/+8
| | | | | | a property of a c++ class object (radar 7957369). llvm-svn: 103279
* Avoid use of DIDescriptor::getNode(). Use overloaded operators instead.Devang Patel2010-05-071-25/+30
| | | | llvm-svn: 103273
* Do not give implicitly-defined virtual members functionsDouglas Gregor2010-05-061-2/+2
| | | | | | | | | | | | | available_externally linkage, since they may not have been given a strong definition in another translation unit. Without this patch, the following test case fails to link with a GCC-compiled libstdc++: #include <sstream> int main() { std::basic_stringbuf<char> bs; } Fixes the last problem with the Boost.IO library. llvm-svn: 103208
* Fix typo in comment; 80 col violationDouglas Gregor2010-05-061-3/+3
| | | | llvm-svn: 103204
* The global variable for the VTT might not have external linkage; allowDouglas Gregor2010-05-061-1/+1
| | | | | | | us to find local variables, too. Fixes the last remaining Boost.Rational failure. llvm-svn: 103203
* Code Gen support for Getter/Setter synthesis of Fariborz Jahanian2010-05-061-3/+23
| | | | | | C++ object properties. (still radar 7468090). llvm-svn: 103182
* simplify EmitAggMemberInitializer a bit and make it work in 32-bit mode,Chris Lattner2010-05-061-3/+2
| | | | | | fixing PR7063. llvm-svn: 103171
* add todos for isinf_sign and isnormal, which I don't intend to implementChris Lattner2010-05-061-1/+8
| | | | | | in the near future. llvm-svn: 103169
* implement codegen support for __builtin_isfinite, part of PR6083Chris Lattner2010-05-061-0/+13
| | | | llvm-svn: 103168
* implement part of PR6083: codegen support for isinf. Like isnan,Chris Lattner2010-05-061-1/+35
| | | | | | | this is generating correct but suboptimal (extra extend to double) code for the float case. Will investigate next. llvm-svn: 103166
* Clean up the {} and else placement. This fixes an ambiguous else as well asChandler Carruth2010-05-061-6/+6
| | | | | | picking a more consistent pattern. llvm-svn: 103142
* Pass the globaldecl into GetOrCreateLLVMFunction so that llvmChris Lattner2010-05-051-1/+1
| | | | | | | | | function attributes like byval get applied to the function definition. This fixes PR7058 and makes i386 llvm/clang bootstrap pass all the same tests as x86-64 bootstrap for me (the llvmc tests still fail in both). llvm-svn: 103131
* This patch deals with Sema Part of Setter/Getter synthesisFariborz Jahanian2010-05-051-6/+0
| | | | | | | of properties which are of C++ objects. Code Gen to follow (Radar 7468090). llvm-svn: 103123
* When we emit a non-constant initializer for a global variable ofDouglas Gregor2010-05-051-2/+4
| | | | | | | | reference type, make sure that the initializer we build is the of the appropriate type for the *reference*, not for the thing that it refers to. Fixes PR7050. llvm-svn: 103115
* For thread-safe static initialization of local statics withDouglas Gregor2010-05-051-33/+48
| | | | | | | | destructors, place the __cxa_atexit call after the __cxa_guard_release call, mimicking GCC/LLVM-GCC behavior. Noticed while debugging something related. llvm-svn: 103088
* Reapplying patch to change StmtNodes.def to StmtNodes.td, this timeAlexis Hunt2010-05-051-1/+1
| | | | | | | with no whitespace. This will allow statements to be referred to in attribute TableGen files. llvm-svn: 103087
* Revert r103072; I accidentally ended up deleting a bunch of trailingAlexis Hunt2010-05-051-24/+24
| | | | | | | whitespace which makes this patch unreadable. Will recommit without the whitespace. llvm-svn: 103086
* Reimplement code generation for copying fields in theDouglas Gregor2010-05-052-226/+147
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | implicitly-generated copy constructor. Previously, Sema would perform some checking and instantiation to determine which copy constructors, etc., would be called, then CodeGen would attempt to figure out which copy constructor to call... but would get it wrong, or poke at an uninstantiated default argument, or fail in other ways. The new scheme is similar to what we now do for the implicit copy-assignment operator, where Sema performs all of the semantic analysis and builds specific ASTs that look similar to the ASTs we'd get from explicitly writing the copy constructor, so that CodeGen need only do a direct translation. However, it's not quite that simple because one cannot explicit write elementwise copy-construction of an array. So, I've extended CXXBaseOrMemberInitializer to contain a list of indexing variables used to copy-construct the elements. For example, if we have: struct A { A(const A&); }; struct B { A array[2][3]; }; then we generate an implicit copy assignment operator for B that looks something like this: B::B(const B &other) : array[i0][i1](other.array[i0][i1]) { } CodeGen will loop over the invented variables i0 and i1 to visit all elements in the array, so that each element in the destination array will be copy-constructed from the corresponding element in the source array. Of course, if we're dealing with arrays of scalars or class types with trivial copy-assignment operators, we just generate a memcpy rather than a loop. Fixes PR6928, PR5989, and PR6887. Boost.Regex now compiles and passes all of its regression tests. Conspicuously missing from this patch is handling for the exceptional case, where we need to destruct those objects that we have constructed. I'll address that case separately. llvm-svn: 103079
* Use a more appropriate LLVM type for the vtable pointer.Anders Carlsson2010-05-051-3/+5
| | | | llvm-svn: 103078
* Unbreak CMake build.Douglas Gregor2010-05-051-0/+2
| | | | llvm-svn: 103077
* Change StmtNodes.def to StmtNodes.td in anticipation of a rewrite of attributesAlexis Hunt2010-05-051-24/+24
| | | | llvm-svn: 103072
* Emit the globals, metadata, etc. associated with static variables even whenJohn McCall2010-05-042-5/+5
| | | | | | | | they're unreachable. This matters because (if they're POD, or if this is C) the scope containing the variable might be reachable even if the variable isn't. Fixes PR7044. llvm-svn: 103052
* Fixes a code gen. crash when ivar object has trivial constructor.Fariborz Jahanian2010-05-041-12/+14
| | | | llvm-svn: 103028
* When instantiating a function that was declared via a typedef, e.g.,Douglas Gregor2010-05-041-1/+4
| | | | | | | | | | | | | typedef int functype(int, int); functype func; also instantiate the synthesized function parameters for the resulting function declaration. With this change, Boost.Wave builds and passes all of its regression tests. llvm-svn: 103025
* Fixes a code gen crash when block is a reference type, etc.Fariborz Jahanian2010-05-041-0/+2
| | | | | | (radar 7495203). llvm-svn: 103022
* When inheriting a default argument expression, inherit the full expression,John McCall2010-05-041-1/+3
| | | | | | | | | not just the inner expression. This is important if the expression has any temporaries. Fixes PR 7028. Basically a symptom of really tragic method names. llvm-svn: 102998
* Fixes a Code Gen. Crash when calling destructor on a __blockFariborz Jahanian2010-05-041-4/+9
| | | | | | | variabe. Blocks and their construction/destruction is wip though. llvm-svn: 102985
* Just bail out immediately when emitting an unreachable function-local staticJohn McCall2010-05-031-0/+3
| | | | | | variable. Surprisingly, this does seem to be the right way to solve this. llvm-svn: 102961
* If we're generating code to create a pointer-to-member functionDouglas Gregor2010-05-031-0/+6
| | | | | | | aggregate and the result of the aggregate is unused, bail out early. Fixes PR7027. llvm-svn: 102942
* When computing the address of a virtual member function pointer, use the ↵Anders Carlsson2010-05-032-2/+12
| | | | | | pointer width instead of hardcoding for 64-bit. llvm-svn: 102921
* Don't build an aggregate constructor loop when the constructor is trivial.Anders Carlsson2010-05-031-5/+7
| | | | llvm-svn: 102912
* Don't copy or initialize empty classes. Fixes PR7012.Anders Carlsson2010-05-032-0/+16
| | | | llvm-svn: 102891
* Store the entire base subobject in SubVTTIndices.Anders Carlsson2010-05-032-16/+13
| | | | llvm-svn: 102890
* Remove OldGetAddressOfBaseClass - bye bye ambiguities.Anders Carlsson2010-05-032-95/+0
| | | | llvm-svn: 102889
* Get rid of the last caller of OldGetAddressOfBaseClass.Anders Carlsson2010-05-031-8/+16
| | | | llvm-svn: 102888
* More work towards getting rid of OldGetAddressOfBaseClass.Anders Carlsson2010-05-032-1/+12
| | | | llvm-svn: 102887
* Get rid of a call to GetAddressOfDirectBaseInCompleteClass.Anders Carlsson2010-05-021-4/+7
| | | | llvm-svn: 102886
* Have getSubVTTIndex take a BaseSubobject instead of just a base.Anders Carlsson2010-05-023-4/+10
| | | | llvm-svn: 102885
* Pass ForVirtualBase all the way to GetVTTParameter.Anders Carlsson2010-05-021-4/+8
| | | | llvm-svn: 102883
* Add the same 'ForVirtualBase' parameter to EmitCXXDestructorCall.Anders Carlsson2010-05-027-15/+27
| | | | llvm-svn: 102882
* Revert my last change and add a 'ForVirtualBase' parameter to ↵Anders Carlsson2010-05-023-12/+15
| | | | | | EmitCXXConstructorCall instead. llvm-svn: 102881
OpenPOWER on IntegriCloud