summaryrefslogtreecommitdiffstats
path: root/clang/CodeGen
Commit message (Collapse)AuthorAgeFilesLines
...
* Visit CompoundLiteralExpr and InitListExprDevang Patel2007-10-241-2/+16
| | | | llvm-svn: 43300
* Constify methods and reuse RecordOrganizer object.Devang Patel2007-10-244-12/+21
| | | | llvm-svn: 43284
* check base type.Devang Patel2007-10-241-1/+1
| | | | llvm-svn: 43283
* Add notes.Devang Patel2007-10-242-0/+4
| | | | llvm-svn: 43282
* Use isUnionType() predicate.Devang Patel2007-10-241-1/+1
| | | | llvm-svn: 43281
* untabifyDevang Patel2007-10-243-10/+10
| | | | llvm-svn: 43280
* Fixed a strange construct, please review.Hartmut Kaiser2007-10-241-1/+1
| | | | llvm-svn: 43278
* Handle nested structs.Devang Patel2007-10-232-1/+31
| | | | | | typdef struct A { int i; struct A *next; } A llvm-svn: 43268
* Handle simple struct member expr.Devang Patel2007-10-231-0/+31
| | | | llvm-svn: 43258
* Begin struct layout work.Devang Patel2007-10-234-6/+167
| | | | llvm-svn: 43236
* Updated VC++ build system.Hartmut Kaiser2007-10-173-3/+4
| | | | | | | | Silenced some VC++ warnings. Had to rephrase a partial specialization of the IntrospectionTrait struct in SerializationTest.cpp, please review. Added a compiler specific workaround in IdentifierTable.h. Is that the way to fix this kind of issues? llvm-svn: 43074
* Generate code for static variables that don't have initializers. Also, ↵Anders Carlsson2007-10-172-1/+26
| | | | | | report an error if a static initializer is not constant. llvm-svn: 43058
* Move type compatibility predicates from Type to ASTContext. In addition, the ↵Steve Naroff2007-10-151-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | predicates are now instance methods (they were previously static class methods on Type). This allowed me to fix the following hack from this weekend... // FIXME: Devise a way to do this without using strcmp. // Would like to say..."return getAsStructureType() == IdStructType;", but // we don't have a pointer to ASTContext. bool Type::isObjcIdType() const { if (const RecordType *RT = getAsStructureType()) return !strcmp(RT->getDecl()->getName(), "objc_object"); return false; } ...which is now... bool isObjcIdType(QualType T) const { return T->getAsStructureType() == IdStructType; } Side notes: - I had to remove a convenience function from the TypesCompatibleExpr class. int typesAreCompatible() const {return Type::typesAreCompatible(Type1,Type2);} Which required a couple clients get a little more verbose... - Result = TCE->typesAreCompatible(); + Result = Ctx.typesAreCompatible(TCE->getArgType1(), TCE->getArgType2()); Overall, I think this change also makes sense for a couple reasons... 1) Since ASTContext vends types, it makes sense for the type compatibility API to be there. 2) This allows the type compatibility predeciates to refer to data not strictly present in the AST (which I have found problematic on several occasions). llvm-svn: 43009
* Add code generation and sema checking for __builtin_va_arg.Anders Carlsson2007-10-151-0/+10
| | | | llvm-svn: 43006
* Fix an incorrect assertion.Anders Carlsson2007-10-131-2/+3
| | | | llvm-svn: 42951
* Generate code for va_start and va_end.Anders Carlsson2007-10-123-3/+25
| | | | llvm-svn: 42939
* Recognize while(1) and avoid extra blocks.Devang Patel2007-10-091-4/+16
| | | | llvm-svn: 42811
* Recognize "do {} while (0)" idiom and avoid extra basic blocks.Devang Patel2007-10-091-5/+18
| | | | llvm-svn: 42808
* Use LLVMFoldingBuilderDevang Patel2007-10-094-4/+4
| | | | llvm-svn: 42807
* Use const& for RHS.Devang Patel2007-10-091-1/+1
| | | | | | Use copy for LHS, because it is incremented using ++ operator. llvm-svn: 42792
* Fix comment. Describe what it is, instead of how it is used.Devang Patel2007-10-091-4/+4
| | | | llvm-svn: 42791
* Added a new class for Interfaces qualified by protocol list.Fariborz Jahanian2007-10-081-0/+4
| | | | | | | Protocols are now sorted and made unique in the list. Enhanced pretty printer for @interface (So, I can see the protocol list). llvm-svn: 42776
* Rename FileVariable -> FileVar for consistency with its class name, Chris Lattner2007-10-081-3/+3
| | | | | | | | | likewise block and param. Reorder the layout of the Decl kind enum so that the inheritance tree is reflected in the ordering. This allows trivial range comparisons to determine whether something is an instance of some abstract class, making classof faster. llvm-svn: 42772
* Code gen case statement ranges.Devang Patel2007-10-083-14/+79
| | | | llvm-svn: 42766
* move IdentifierTable.h from liblex to libbasic.Chris Lattner2007-10-071-1/+0
| | | | llvm-svn: 42730
* Support case statement ranges.Devang Patel2007-10-051-3/+15
| | | | llvm-svn: 42648
* switch statement code gen.Devang Patel2007-10-043-2/+76
| | | | llvm-svn: 42616
* Do not codegen dummy block.Devang Patel2007-09-283-10/+40
| | | | | | Dummy block is an empty block with no predecessors. llvm-svn: 42451
* further apfloat'ize the front-end, allowing codegen to pass Chris Lattner2007-09-221-7/+1
| | | | | | APFloat straight through to LLVM now. llvm-svn: 42236
* fix some warnings, patch by Justin HandvilleChris Lattner2007-09-162-0/+11
| | | | llvm-svn: 42010
* Move Decl::NextDeclarator (w/ setters/getters) down to ScopedDecl/FieldDecl.Steve Naroff2007-09-131-1/+2
| | | | | | Decl is now svelte:-) llvm-svn: 41935
* Phase 2 of making the Decl class more lightweight...Steve Naroff2007-09-133-3/+4
| | | | | | | | Move Identifier/Loc instance variables (and associated getters/setters) down from Decl to ScopedDecl/FieldDecl. Objc AST's can now inherit from Decl without getting instance variables and types that are C specific. For now, I am keeping NextDeclarator, since I believe it may be useful to ObjC. If not, it can be moved later. llvm-svn: 41934
* update to match llvm mainline apiChris Lattner2007-09-132-5/+19
| | | | llvm-svn: 41926
* adjust to a change in the LLVM APIs, this is still very hackish untilChris Lattner2007-09-131-1/+7
| | | | | | the front-end adopts APFloat though. This fixes test/CodeGen/mandel.c llvm-svn: 41908
* When dumping out errors about unsupported stuff, emit loc info.Chris Lattner2007-09-136-9/+9
| | | | llvm-svn: 41907
* Fixed compilation on Windows. Hartmut Kaiser2007-09-072-3/+5
| | | | | | | | Silenced a couple of warnings. Added *.vcproj file for new clangAnalysis library. Renamed Basic to clangBasic projects. llvm-svn: 41767
* Updated calls to CreateGEP to new interface in LLVM mainline.Ted Kremenek2007-09-042-5/+15
| | | | llvm-svn: 41704
* eliminate some VC++ warnings, patch contributed by Hartmut KaiserChris Lattner2007-09-044-6/+7
| | | | llvm-svn: 41692
* add stmtexpr support for aggregatesChris Lattner2007-08-311-0/+5
| | | | llvm-svn: 41662
* add support for complex stmtexpr'sChris Lattner2007-08-311-1/+6
| | | | llvm-svn: 41661
* Generalize RValue to handle complex better, generalize EmitCompoundStmt toChris Lattner2007-08-315-37/+84
| | | | | | support any sort of expr, add a new EmitAnyExpr routine. llvm-svn: 41660
* implement code generation for scalar stmt expressions.Chris Lattner2007-08-313-4/+28
| | | | llvm-svn: 41656
* Implement codegen support for lowering "library builtins" like __builtin_isinf Chris Lattner2007-08-314-9/+14
| | | | | | | to their corresponding library routines (e.g. isinf). This allows us to handle all the stuff in macos math.h, and other stuff as it's added to *Builtins.def. llvm-svn: 41634
* add the ability to get the llvm function corresponding to a library builtin.Chris Lattner2007-08-314-4/+54
| | | | llvm-svn: 41633
* Fix the following redefinition errors submitted by Keith Bauer...Steve Naroff2007-08-301-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | [dylan:~/llvm/tools/clang] admin% cat tentative_decls.c // incorrectly generates redefinition error extern int array[3]; int array[3]; // incorrectly generates a redefinition error extern void nup(int a[3]); void nup(int a[3]) {} It turns out that this exposed a fairly major flaw in the type system, array types were never getting uniqued! This is because all array types contained an expression, which aren't unique. To solve this, we now have 2 array types, ConstantArrayType and VariableArrayType. ConstantArrayType's are unique, VAT's aren't. This is a fairly extensive set of fundamental changes. Fortunately, all the tests pass. Nevertheless, there may be some collateral damage:-) If so, let me know! llvm-svn: 41592
* remove some ugly code now that implicit defs are being generated in this ↵Chris Lattner2007-08-291-15/+0
| | | | | | case, thanks Steve! llvm-svn: 41560
* Change EnumDecl to store its corresponding integer type Chris Lattner2007-08-281-1/+1
| | | | | | | directly in it. Remove TargetInfo::getEnumPolicy, as there is only one policy that we support right now. llvm-svn: 41548
* teach codegen to lay out enum types.Chris Lattner2007-08-271-1/+3
| | | | llvm-svn: 41501
* move EmitAggregateCopy into AggExprEmitterChris Lattner2007-08-262-41/+44
| | | | llvm-svn: 41472
* remove dead codeChris Lattner2007-08-262-5/+0
| | | | llvm-svn: 41470
OpenPOWER on IntegriCloud