summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CodeGenModule.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* Un-namespace-qualify llvm_unreachable. It's a macro, so the qualification gaveJeffrey Yasskin2009-12-121-1/+1
| | | | | | no extra safety anyway. llvm-svn: 91207
* Fix for PR5714: make sure globals that will be modified aren't marked const.Eli Friedman2009-12-111-5/+13
| | | | llvm-svn: 91156
* Random string-related cleanups.Benjamin Kramer2009-12-111-3/+2
| | | | llvm-svn: 91119
* Make sure that explicitly instantiated functions get the right linkage.Anders Carlsson2009-12-101-3/+12
| | | | llvm-svn: 91069
* Fix for PR5709: use the computed type of the declaration instead of theEli Friedman2009-12-091-6/+1
| | | | | | | type of the builtin when generating the function declaration for a builtin library call. llvm-svn: 90936
* Misc key function fixes.Eli Friedman2009-12-081-0/+10
| | | | llvm-svn: 90831
* A bunch more thunk fixes from misc testing.Eli Friedman2009-12-071-1/+7
| | | | | | (Yes, I do intend to commit some tests for this.) llvm-svn: 90818
* Work-in-progess rewrite of thunks: move thunk generation outside of vtableEli Friedman2009-12-061-1/+6
| | | | | | | generation, and make sure we generate thunks when the function is defined rather than when the vtable is defined. llvm-svn: 90722
* Add rudimentary support for member pointers to CGDebugInfo.Anders Carlsson2009-12-061-1/+1
| | | | llvm-svn: 90711
* Don't emit explicit specializations of static member variable declarations.Anders Carlsson2009-12-041-5/+11
| | | | llvm-svn: 90624
* Have ASTRecordLayout keep track of the key function, in preparation of ↵Anders Carlsson2009-11-301-12/+4
| | | | | | fixing a synthetic ctor/dtor bug. llvm-svn: 90168
* Don't try to generate common globals for C++ files, instead of depending on ↵Daniel Dunbar2009-11-301-1/+1
| | | | | | the FE to set NoCommon, and simplify CodeGenOptions initialization. llvm-svn: 90119
* Simplify and fix up the handling of implicit constructors, copy assignmentEli Friedman2009-11-261-130/+7
| | | | | | | | operators, and destructors. Avoids generating declarations/definitions of trivial constructors/destructors, and makes sure the trivial copy assignment operator is generated when necessary. llvm-svn: 89943
* Use new getLinkage() method to correctly compute whether a variable hasEli Friedman2009-11-261-4/+3
| | | | | | internal linkage. Fixes PR5433. llvm-svn: 89931
* Ignore constructor member templates in CodeGenModule::EmitTopLevelDecl.Anders Carlsson2009-11-241-0/+4
| | | | llvm-svn: 89737
* Mangler: Lift shouldMangleDeclName predicate out of CXXNameMangler::mangle.Daniel Dunbar2009-11-211-7/+2
| | | | | | | | - Sometimes we have to mangle things we wouldn't normally (e.g., because they appear in a template expression). - This also tidies up the predicate to be more obvious what is getting mangled. llvm-svn: 89555
* IRgen: Switch the C++ mangler interfaces to take the SmallVector to write into,Daniel Dunbar2009-11-211-2/+1
| | | | | | | instead of requiring clients to make a raw_svector_ostream, which is just an implementation detail. llvm-svn: 89548
* Sink free mangle* methods into MangleContext.Daniel Dunbar2009-11-211-1/+1
| | | | llvm-svn: 89547
* Added rudimentary C++0x attribute support.Alexis Hunt2009-11-211-2/+6
| | | | | | | | | | | | | | The following attributes are currently supported in C++0x attribute lists (and in GNU ones as well): - align() - semantics believed to be conformant to n3000, except for redeclarations and what entities it may apply to - final - semantics believed to be conformant to CWG issue 817's proposed wording, except for redeclarations - noreturn - semantics believed to be conformant to n3000, except for redeclarations - carries_dependency - currently ignored (this is an optimization hint) llvm-svn: 89543
* Fixup key function calculations.Mike Stump2009-11-201-1/+3
| | | | llvm-svn: 89412
* Improve instantiation control for rtti data and allow key functions toMike Stump2009-11-191-0/+10
| | | | | | instantiate a class. WIP. llvm-svn: 89289
* Skip over shadow using decls during codegen.John McCall2009-11-171-0/+1
| | | | llvm-svn: 89079
* The ssp and sspreq function attributes should only be applied to function ↵Anders Carlsson2009-11-161-0/+5
| | | | | | definitions, not declarations or calls. llvm-svn: 88915
* Make GetAddrOfConstantStringFromLiteral return a constant of the correct type.Eli Friedman2009-11-161-1/+8
| | | | | | | This doesn't have any visible effects at the moment because normally the implicit cast code forces the type to the expected type. llvm-svn: 88896
* Move CompileOptions -> CodeGenOptions, and sink it into the CodeGen library.Chandler Carruth2009-11-121-5/+5
| | | | | | This resolves the layering violation where CodeGen depended on Frontend. llvm-svn: 86998
* Rearrange function to avoid recursive use-after-free.Eli Friedman2009-11-091-17/+18
| | | | llvm-svn: 86516
* add missing #includeChris Lattner2009-11-071-0/+1
| | | | llvm-svn: 86368
* Added support for static variables which requireFariborz Jahanian2009-11-051-4/+9
| | | | | | initialization before main. Fixes pr5396. llvm-svn: 86145
* Implement proper linkage for explicit instantiation declarations ofDouglas Gregor2009-10-271-14/+14
| | | | | | | | | | | | | | | | | | | | | inlined functions. For example, given template<typename T> class string { unsigned Len; public: unsigned size() const { return Len; } }; extern template class string<char>; we now give the instantiation of string<char>::size available_externally linkage (if it is ever instantiated!), as permitted by the C++0x standard. llvm-svn: 85340
* Introduce FunctionDecl::isInlined() to tell whether a function shouldDouglas Gregor2009-10-271-2/+2
| | | | | | be inlined. llvm-svn: 85307
* Rename FunctionDecl::isInline/setInline toDouglas Gregor2009-10-271-2/+2
| | | | | | FunctionDecl::isInlineSpecified/setInlineSpecified. llvm-svn: 85305
* Add a PrettyStackTraceDecl in CodeGenModule::EmitGlobalDefinition.Anders Carlsson2009-10-271-0/+4
| | | | llvm-svn: 85237
* assert -> llvm_unreachableDouglas Gregor2009-10-261-1/+1
| | | | llvm-svn: 85125
* Move clients to use IdentifierInfo::getNameStart() instead of getName()Daniel Dunbar2009-10-181-4/+4
| | | | llvm-svn: 84436
* Fix a thinko that John pointed outDouglas Gregor2009-10-141-3/+1
| | | | llvm-svn: 84142
* Give explicit and implicit instantiations of static data members ofDouglas Gregor2009-10-141-3/+42
| | | | | | | | class templates the proper linkage. Daniel, please look over the CodeGenModule bits. llvm-svn: 84140
* Copy metadata associated with CIDevang Patel2009-10-141-0/+4
| | | | llvm-svn: 84114
* fix some cfstring related issues: Chris Lattner2009-10-141-13/+10
| | | | | | | | | | | | | 1) -fwritable-string does affect the non-utf16 version of cfstrings just not the utf16 ones. 2) utf16 strings should always be marked constant, as the __TEXT segment is readonly. 3) The name of the global doesn't matter, remove it from TargetInfo. 4) Trust the asmprinter to drop cstrings into the right section, like llvmgcc does now. This fixes rdar://7115750 llvm-svn: 84077
* unbreak test/CodeGen/builtins.c, reverting Devang's change.Chris Lattner2009-10-141-2/+2
| | | | llvm-svn: 84075
* Check void type before using replaceAllUsesWith().Devang Patel2009-10-131-1/+2
| | | | llvm-svn: 84050
* Remove extra white space line.Devang Patel2009-10-131-1/+0
| | | | llvm-svn: 83979
* Do not check use_empty() before invoking replaceAllUsesWith().Devang Patel2009-10-131-2/+3
| | | | | | Let replaceAllUsesWith() adjust VHs even though there are no uses. llvm-svn: 83978
* Simplify pointer creation with the new Type::getInt*Ptr methods.Benjamin Kramer2009-10-131-4/+2
| | | | llvm-svn: 83964
* Move the vtable builder to CGVtable.cpp, general cleanup.Anders Carlsson2009-10-111-1/+2
| | | | llvm-svn: 83798
* If a global initializer has a non-trivial constructor or destructor, we ↵Anders Carlsson2009-10-081-0/+11
| | | | | | | | | | | | | | | | | | | never want to defer generation of it, even if it is declared static. With this change we're finally able to compile and run the (infamous) #include <string> #include <iostream> int main(int argc, char **argv) { std::cout << "Hello, World" << std::endl; } $ clang hello.cpp -lstdc++ -o hello $ ./hello Hello, World llvm-svn: 83559
* Add a MangleContext and pass it to all mangle functions. It will be used for ↵Anders Carlsson2009-10-071-2/+2
| | | | | | keeping state, such as identifiers assigned to anonymous structs as well as scope encoding. llvm-svn: 83442
* Fix thinko and simplify.Mike Stump2009-10-051-2/+2
| | | | llvm-svn: 83342
* Ensure we have atleast 2-byte alignment for member functions.Mike Stump2009-10-051-0/+3
| | | | llvm-svn: 83337
* Respect alignments better.Mike Stump2009-10-051-0/+3
| | | | llvm-svn: 83328
* Use new predicates for some type equality tests.Benjamin Kramer2009-10-051-1/+1
| | | | llvm-svn: 83303
OpenPOWER on IntegriCloud