summaryrefslogtreecommitdiffstats
path: root/clang/lib
Commit message (Collapse)AuthorAgeFilesLines
* Add support for member pointers to const_cast.Sebastian Redl2009-01-261-2/+6
| | | | llvm-svn: 63055
* Silence warning.Ted Kremenek2009-01-261-1/+1
| | | | llvm-svn: 63054
* Add version number checking to PTH files.Ted Kremenek2009-01-261-2/+8
| | | | llvm-svn: 63047
* Embed the offset of the PTH table inside the prologue of the PTH file. This ↵Ted Kremenek2009-01-261-9/+10
| | | | | | will help improve gradual versioning of PTH files instead of relying that the PTH table is at a fixed offset. llvm-svn: 63045
* Method decription meta-data and its setting in class_ro_t Fariborz Jahanian2009-01-261-17/+102
| | | | | | meta-data. llvm-svn: 63043
* Add Ignore ABIArgInfo kind, for handling void & empty structures.Daniel Dunbar2009-01-261-4/+40
| | | | llvm-svn: 63039
* Skip emission of final return block if possible (e.g., functions withDaniel Dunbar2009-01-261-3/+7
| | | | | | a unified return). llvm-svn: 63038
* remove my hacks that aggressively threw away multiple Chris Lattner2009-01-264-32/+1
| | | | | | | | | | | instantiation history in an effort to speed up c99-intconst-1.c. Now that multiple nested instantiations are allowed, we just make them and don't pay the cost of lookups. With the other changes that went in before this, reverting this is actually a speedup for c99-intconst-1.c, speeding it up from 1.96s to 1.80s, and preserves much better loc info. llvm-svn: 63036
* allow _Pragmas formed from #defines to keep their full instantiationChris Lattner2009-01-261-2/+1
| | | | | | history llvm-svn: 63035
* now that everything properly handles multiply instantiatedChris Lattner2009-01-261-8/+0
| | | | | | | source locations, allow creation of them. We can now say that a token was instantiated here, then here, then here. llvm-svn: 63034
* make getInstantiationLoc and getSpellingLoc handle multiply instantiatedChris Lattner2009-01-261-0/+21
| | | | | | locations, and move the slow case out of line. No perf change on cocoa.h llvm-svn: 63033
* Remove an implemented FIXME and extend test cases. Follow-up on Doug's review.Sebastian Redl2009-01-261-9/+8
| | | | llvm-svn: 63032
* Correct size assumption; fixes a crash on amd64.Sebastian Redl2009-01-261-1/+2
| | | | llvm-svn: 63031
* fix a negated conditional in getDecomposedInstantiationLocSlowCase,Chris Lattner2009-01-261-7/+13
| | | | | | | which I think is rdar://6527005, and make getDecomposedSpellingLocSlowCase handle nested spelling locations. llvm-svn: 63030
* This change refactors some of the low-level lexer interfaces a bit.Chris Lattner2009-01-269-53/+82
| | | | | | | | | | | | | Token now has a class of kinds for "literals", which include numeric constants, strings, etc. These tokens can optionally have a pointer to the start of the token in the lexer buffer. This makes it faster to get spelling and do other gymnastics, because we don't have to go through source locations. This change is performance neutral, but will make other changes more feasible down the road. llvm-svn: 63028
* Meta-data for nonfragile-abi's categoriesFariborz Jahanian2009-01-261-2/+51
| | | | llvm-svn: 63020
* Comment fix.Daniel Dunbar2009-01-261-1/+1
| | | | llvm-svn: 63016
* start plumbing together the line table information. So far we justChris Lattner2009-01-262-6/+108
| | | | | | unique the Filenames in #line directives, assigning them UIDs. llvm-svn: 63010
* Lazily paging in file contents is a big win for PTH, strip out the oldChris Lattner2009-01-261-20/+2
| | | | | | testing code. llvm-svn: 63006
* add parsing and constraint enforcement for GNU line marker directives.Chris Lattner2009-01-261-35/+148
| | | | llvm-svn: 63003
* Use tag classes instead of typedefs for GDM entries 'ConstNotEq' and ↵Ted Kremenek2009-01-261-29/+33
| | | | | | 'ConstEq'. This avoids collisions in the GDM. llvm-svn: 63002
* a few minor cleanupsChris Lattner2009-01-261-2/+6
| | | | llvm-svn: 63000
* parse and enforce required constraints on #line directives. Right nowChris Lattner2009-01-261-14/+86
| | | | | | we just discard them. llvm-svn: 62999
* eagerly resolve the spelling locations of macro argument preexpansions.Chris Lattner2009-01-262-3/+10
| | | | | | | | | | | | | | | This reduces fsyntax-only time on c99-intconst-1.c from 2.43s down to 2.01s (20%), reducing the number of fileid lookups from 2529040 linear and 64771121 binary to 5625902 linear and 4151182 binary. This knocks getFileID down to only 4.6% of compile time on this testcase. At this point, malloc/free is over 35% of compile time, primarily allocating MacroArgs objects and their argument preexpansion vectors. I don't feel like malloc avoiding right now, so I'm just going to call this good. llvm-svn: 62994
* Eagerly resolve the spelling location of the tokens in a definitionChris Lattner2009-01-262-0/+18
| | | | | | | | | | | | of a macro. Since these tokens may themselves be from macro expansions, we need to resolve down to the spelling loc when the macro ends up being instantiated. Instead of resolving this for each token expanded from the macro definition, just do it once when the macro is defined. This speeds up clang on c99-intconst-1.c from 2.66s to 2.43s (9.5%), reducing the FileID lookups from 407244 linear and 114175649 binary to 2529040 linear and 64771121 binary. llvm-svn: 62993
* Only resolve a macro's instantiation loc once per macro, instead of onceChris Lattner2009-01-261-0/+7
| | | | | | | | per token lexed from it. This speeds up clang on c99-intconst-1.c from the GCC testsuite from 3.64s to 2.66s (36%). This reduces the number of binary search FileID lookups from 251570522 to 114175649 on this testcase. llvm-svn: 62992
* PR3269: create an empty InitListExpr as a child for the Eli Friedman2009-01-261-3/+7
| | | | | | CompoundLiteralExpr so that there aren't any null pointers in the AST. llvm-svn: 62981
* Check in the long promised SourceLocation rewrite. This lays theChris Lattner2009-01-268-175/+255
| | | | | | | | | | ground work for implementing #line, and fixes the "out of macro ID's" problem. There is nothing particularly tricky about the code, other than the very performance sensitive SourceManager::getFileID() method. llvm-svn: 62978
* Implement implicit conversions for pointers-to-member.Sebastian Redl2009-01-254-10/+116
| | | | llvm-svn: 62971
* Introduce an explicit case for member pointers in CodeGenTypes. However, it ↵Sebastian Redl2009-01-251-0/+7
| | | | | | simply asserts. llvm-svn: 62960
* Fix compile error from r62953.Sebastian Redl2009-01-251-1/+2
| | | | llvm-svn: 62959
* One more case for Expr::isConstantInitializer; I think this covers Eli Friedman2009-01-251-0/+2
| | | | | | everything that we aren't intending to implement in Expr::Evaluate. llvm-svn: 62953
* Enhancements to Expr::isConstantInitializer to deal with a few Eli Friedman2009-01-251-6/+25
| | | | | | cases it couldn't deal with before. llvm-svn: 62952
* Rename Expr::isConstantExpr to Expr::isConstantInitializer; this more Eli Friedman2009-01-254-7/+6
| | | | | | | | accurately states what the function is trying to do and how it is different from Expr::isEvaluatable. Also get rid of a parameter that is both unused and inaccurate. llvm-svn: 62951
* Get rid of some code that should be unnecessary.Eli Friedman2009-01-251-52/+0
| | | | llvm-svn: 62950
* Make the constant folder aware of Eli Friedman2009-01-253-2/+18
| | | | | | | __builtin___CFStringMakeConstantString. (We get into trouble in GenerateStaticBlockVarDecl if the constant folder isn't accurate.) llvm-svn: 62949
* Fix the address of a label to be properly considered and emitted as aEli Friedman2009-01-252-0/+8
| | | | | | constant. llvm-svn: 62948
* Fix for PR2100: merge types for variables.Eli Friedman2009-01-241-4/+4
| | | | llvm-svn: 62947
* Compute instaceStart/instanceSize fields of the class_ro_t meta-dataFariborz Jahanian2009-01-241-2/+41
| | | | | | for objc2's non-fragile abi. llvm-svn: 62945
* Make tentative parsing of pointer-to-member decls work, and fix other stuff ↵Sebastian Redl2009-01-243-5/+12
| | | | | | pointed out by Doug. llvm-svn: 62944
* PR3062: statement expressions should be illegal at file scope. I don't Eli Friedman2009-01-241-0/+5
| | | | | | | think this has any significant effects at the moment, but it could matter if we start constant-folding statement expressions like gcc does. llvm-svn: 62943
* Fix for PR2910: implement CodeGen for non-constant offsetof.Eli Friedman2009-01-241-7/+42
| | | | | | Note that there are still other issues in this area; see PR3396. llvm-svn: 62942
* Refactor sizeof handling to use constant folding logic for constant Eli Friedman2009-01-242-41/+24
| | | | | | sizeof expressions. llvm-svn: 62941
* add initial support for the gcc "alignof(decl) is the alignment of the declChris Lattner2009-01-242-5/+34
| | | | | | | not the type" semantics. This can definitely be improved, but is better than what we had. llvm-svn: 62939
* Implement C99 6.5.3.4p1, rejecting sizeof(bitfield)Chris Lattner2009-01-241-4/+8
| | | | llvm-svn: 62936
* Patch to build class meta-data for each implementation Fariborz Jahanian2009-01-241-9/+44
| | | | | | of class in objc2's nonfragile abi. llvm-svn: 62935
* Add support for declaring pointers to members.Sebastian Redl2009-01-246-27/+227
| | | | | | Add serialization support for ReferenceType. llvm-svn: 62934
* remove a bunch of alignment handling code out of CGExprScalar, sinceChris Lattner2009-01-241-20/+18
| | | | | | | alignment must always be a constant. Just let the constant folder do it. llvm-svn: 62933
* Improve handling of alignof. alignof(VLA) now works properly for example.Chris Lattner2009-01-241-13/+50
| | | | llvm-svn: 62932
* remove dead code.Chris Lattner2009-01-241-15/+0
| | | | llvm-svn: 62930
OpenPOWER on IntegriCloud