summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen
Commit message (Collapse)AuthorAgeFilesLines
...
* Do not use clang type name to name a local variable, e.g. Decl.Devang Patel2010-02-011-44/+44
| | | | llvm-svn: 95010
* Do not use clang type name to name a local variable, e.g. Decl.Devang Patel2010-02-011-29/+25
| | | | llvm-svn: 95009
* Use DeclContext as getContextDescriptor() argument.Devang Patel2010-02-011-18/+27
| | | | llvm-svn: 95008
* NeXT: Add support for -fobjc-legacy-dispatch.Daniel Dunbar2010-02-011-0/+4
| | | | llvm-svn: 95005
* Don't explicitly force utf strings into the __TEXT,__ustringChris Lattner2010-02-011-4/+0
| | | | | | | | | | by setting the section of the generated global. This is an optimization done by the code generator, and the code being removed didn't handle the case when the string contained an embedded nul (which the code generator does correctly handle). This is rdar://7589850 llvm-svn: 95003
* In C++, an initializer on a variable doesn't necessarily mean it's the ↵Sebastian Redl2010-02-011-1/+1
| | | | | | definition. With that in mind, rename getDefinition to getAnyInitializer (to distinguish it from getInit) and reimplement it in terms of isThisDeclarationADefinition. Update all code to use this new function. llvm-svn: 94999
* Emit debug info for namespaces.Devang Patel2010-02-012-1/+29
| | | | llvm-svn: 94991
* Switch expressions like T() and T(1,2) over to new-style initialization. I'mEli Friedman2010-01-311-1/+1
| | | | | | | not quite sure what we want to do about the AST representation; comments welcome. llvm-svn: 94967
* Simplify EmitMemberInitializer; no intended functionality change.Eli Friedman2010-01-311-19/+1
| | | | llvm-svn: 94965
* Start creating CXXBindReferenceExpr nodes when binding complex types to ↵Anders Carlsson2010-01-314-0/+31
| | | | | | references. llvm-svn: 94964
* Rework base and member initialization in constructors, with severalDouglas Gregor2010-01-312-41/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (necessarily simultaneous) changes: - CXXBaseOrMemberInitializer now contains only a single initializer rather than a set of initialiation arguments + a constructor. The single initializer covers all aspects of initialization, including constructor calls as necessary but also cleanup of temporaries created by the initializer (which we never handled before!). - Rework + simplify code generation for CXXBaseOrMemberInitializers, since we can now just emit the initializer as an initializer. - Switched base and member initialization over to the new initialization code (InitializationSequence), so that it - Improved diagnostics for the new initialization code when initializing bases and members, to match the diagnostics produced by the previous (special-purpose) code. - Simplify the representation of type-checked constructor initializers in templates; instead of keeping the fully-type-checked AST, which is rather hard to undo at template instantiation time, throw away the type-checked AST and store the raw expressions in the AST. This simplifies instantiation, but loses a little but of information in the AST. - When type-checking implicit base or member initializers within a dependent context, don't add the generated initializers into the AST, because they'll look like they were explicit. - Record in CXXConstructExpr when the constructor call is to initialize a base class, so that CodeGen does not have to infer it from context. This ensures that we call the right kind of constructor. There are also a few "opportunity" fixes here that were needed to not regress, for example: - Diagnose default-initialization of a const-qualified class that does not have a user-declared default constructor. We had this diagnostic specifically for bases and members, but missed it for variables. That's fixed now. - When defining the implicit constructors, destructor, and copy-assignment operator, set the CurContext to that constructor when we're defining the body. llvm-svn: 94952
* When performing a derived-to-base cast that we know will not change the ↵Anders Carlsson2010-01-311-52/+49
| | | | | | offset, we don't need to null check the input pointer. Fixes PR5965. llvm-svn: 94942
* When doing a base-to-derived cast we don't need to null check the derived ↵Anders Carlsson2010-01-311-10/+15
| | | | | | value if the class offset is 0. llvm-svn: 94939
* Some class related cleanup.Anders Carlsson2010-01-316-41/+39
| | | | llvm-svn: 94938
* More asm cleanup.Anders Carlsson2010-01-301-6/+6
| | | | llvm-svn: 94920
* Yay for more StringRefs.Anders Carlsson2010-01-301-3/+2
| | | | llvm-svn: 94917
* Use appropriate context for typedefs. Devang Patel2010-01-291-7/+5
| | | | llvm-svn: 94849
* Maintain a map of regions (lexical scopes) and use it to find context for a ↵Devang Patel2010-01-292-11/+10
| | | | | | global variable. llvm-svn: 94817
* Name mangling for cast expressions, from Matthias Schiffer! Fixes PR5876.Douglas Gregor2010-01-291-0/+18
| | | | llvm-svn: 94811
* Use EmitLValueForFieldInitialization when synthesizing the copy ctor as well.Anders Carlsson2010-01-291-19/+2
| | | | llvm-svn: 94800
* Add a new EmitLValueForFieldInitialization that will be used for ↵Anders Carlsson2010-01-293-11/+27
| | | | | | initializing fields (and reference type fields in particular). llvm-svn: 94799
* Simplify EmitLValueForField - we can get whether the field is part of a ↵Anders Carlsson2010-01-295-29/+18
| | | | | | union or not from the FieldDecl (through its DeclContext). llvm-svn: 94798
* ARM/APCS ABI: Fix some problems with bit-fields in structures. After rereadingDaniel Dunbar2010-01-291-18/+18
| | | | | | | the ABI spec, this turns out to simplify the code. We still have some annoying code which mismatches the spec with regard to empty structures. llvm-svn: 94796
* Add an CXXBindReferenceExpr (not used just yet).Anders Carlsson2010-01-291-0/+2
| | | | llvm-svn: 94791
* s/CGDebugInfo::getContext/CGDebugInfo::getContextDescriptor/g to avoid ↵Devang Patel2010-01-282-7/+8
| | | | | | confusion. llvm-svn: 94760
* Fix indentation.Devang Patel2010-01-281-30/+30
| | | | llvm-svn: 94758
* Static methods do not need "this" pointer argument.Devang Patel2010-01-281-0/+5
| | | | llvm-svn: 94756
* Emit base classes info first, as expected by the debugger.Devang Patel2010-01-281-3/+3
| | | | llvm-svn: 94755
* Fix an incorrect union layout assert. Fixes PR6164.Anders Carlsson2010-01-281-1/+6
| | | | llvm-svn: 94754
* s/FunctionNames/DebugInfoNames/gDevang Patel2010-01-282-4/+4
| | | | llvm-svn: 94753
* Emit vtable info.Devang Patel2010-01-282-1/+82
| | | | llvm-svn: 94751
* While emitting debugging infor for a C++ class, identify the holder of ↵Devang Patel2010-01-281-1/+11
| | | | | | class's vtable, if any. llvm-svn: 94712
* Include "this" pointer argument while emitting debug info for a C++ method.Devang Patel2010-01-282-1/+41
| | | | llvm-svn: 94710
* Change the return type of ASTContext::getDeclAlignInBytes() to CharUnits and,Ken Dyck2010-01-274-24/+28
| | | | | | | now that the "InBytes" part of the name is implied by the return type, rename it to getDeclAlign(). llvm-svn: 94681
* Unique ObjC strings (GNU Runtime); fix for PR6142. Note: Doing this in the ↵David Chisnall2010-01-271-2/+10
| | | | | | runtime-specific code is a bit ugly. It would be a good idea to hoist all of the string / protocol uniqueing code up into CGObjCRuntime or CodeGenModule and only handle emitting the original versions in the runtime-specific code. llvm-svn: 94676
* Structs and classes with non-trivial destructors or copy constructors should ↵Anders Carlsson2010-01-271-2/+10
| | | | | | be passed indirectly in the 32-bit ABI. Fixes PR6094. llvm-svn: 94656
* Refine the non-virtual this adjustments for thunks by using the offsetMike Stump2010-01-261-0/+6
| | | | | | to the declaring class from the nearest virtual base class. WIP. llvm-svn: 94606
* Refine the non-virtual this adjustments for thunks by using the offsetMike Stump2010-01-261-7/+24
| | | | | | | | to the declaring class from the nearest virtual base class. WIP. This fixes 40% of all the problems remaining in one of my testcases. llvm-svn: 94592
* Convert one last size variable to CharUnits (follow-on to 94577).Ken Dyck2010-01-261-2/+3
| | | | llvm-svn: 94579
* Use CharUnits for sizes, offsets, alignments, and padding amounts for valuesKen Dyck2010-01-261-35/+39
| | | | | | that are in character units. llvm-svn: 94577
* Use CharUnits for alignments in character units.Ken Dyck2010-01-263-14/+17
| | | | llvm-svn: 94571
* Use CharUnits for alignment of UTF16 string in GetAddrOfConstantCFString().Ken Dyck2010-01-261-2/+2
| | | | llvm-svn: 94564
* Use CharUnits for alignment in EmitNullInitializationLValue().Ken Dyck2010-01-261-2/+2
| | | | llvm-svn: 94563
* Use the right definition when emitting a global variable. Fixes PR5564.Anders Carlsson2010-01-261-3/+5
| | | | llvm-svn: 94555
* Change getUnique to return a GlobalDecl. Fixes PR6147.Anders Carlsson2010-01-261-8/+20
| | | | llvm-svn: 94554
* Introduce CodeGenModule::GetTargetTypeStoreSize() to calculate the store sizeKen Dyck2010-01-264-7/+16
| | | | | | of LLVM types in character units. llvm-svn: 94542
* If a global variable has an initializer with side effects, it can never be ↵Anders Carlsson2010-01-261-3/+2
| | | | | | deferred (even if it's in an anonymous namespace). llvm-svn: 94525
* Fix another debug info crash with virtual bases.Anders Carlsson2010-01-261-4/+11
| | | | llvm-svn: 94520
* Fix the test I broke, and also fix a crash when declaring a virtual ↵Anders Carlsson2010-01-262-22/+26
| | | | | | destructor. Add debug info support for pure virtual member functions. llvm-svn: 94519
* Factor creating the DISubprogram for a member function out into a separate ↵Anders Carlsson2010-01-262-51/+68
| | | | | | function. llvm-svn: 94513
OpenPOWER on IntegriCloud