summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Unused relocation type reloc_arm_absolute removed.Raul Herbster2007-08-301-2/+0
| | | | llvm-svn: 41628
* Comments added. It now generates V5TE multiply instructions. However, it is ↵Raul Herbster2007-08-301-58/+175
| | | | | | still necessary to model PUWLSH bits more clearly. llvm-svn: 41627
* ARM instruction table was modified by adding information to generate ↵Raul Herbster2007-08-301-42/+57
| | | | | | multiply instruction of V5TE. llvm-svn: 41626
* JITInfo now resolves function addrs and also relocations. It always emits a ↵Raul Herbster2007-08-301-30/+43
| | | | | | stub. llvm-svn: 41625
* Final phase of array cleanup (for now), removing a FIXME from yesterday.Steve Naroff2007-08-304-43/+34
| | | | | | | | | | | | | | | | | | | | | | Moved several array constraints checks from Sema::VerifyConstantArrayType() to Sema::GetTypeForDeclarator(). VerifyConstantArrayType() is now very simple, and could be removed eventually. Now, we get the following (correct) messages for BlockVarDecls:-) [dylan:~/llvm/tools/clang] admin% ../../Debug/bin/clang x.c -pedantic x.c:4:20: error: size of array has non-integer type 'float' int size_not_int[f]; ^ x.c:5:21: error: array size is negative int negative_size[1-2]; ^~~ x.c:6:17: warning: zero size arrays are an extension int zero_size[0]; ^ 3 diagnostics generated. llvm-svn: 41624
* Minor cleanups to pretty-printing for loops in CFGs.Ted Kremenek2007-08-301-4/+4
| | | | llvm-svn: 41623
* Fixed a bug in constructing CFG blocks for case statement fall-throughTed Kremenek2007-08-301-3/+5
| | | | | | | | | | introduced by moving "CaseStmt" pointers out of the list of statements and into the explicit "label" associated with a CFGBlock. --This line, and those below, will be ignored-- M AST/CFG.cpp llvm-svn: 41622
* Diff is self small & self explanatory...Steve Naroff2007-08-301-1/+1
| | | | llvm-svn: 41621
* Fixed bug in CFG construction where we failed to handle loop bodies withTed Kremenek2007-08-301-9/+18
| | | | | | no statements (or just full of ';' statements). llvm-svn: 41620
* Fixed bug in CFG construction involving use of labels and "empty"Ted Kremenek2007-08-301-2/+4
| | | | | | | | blocks involving only ';' statements. We now correctly handle the following: void empty_label() { l1: ; } llvm-svn: 41619
* Fix a comment.Steve Naroff2007-08-302-8/+6
| | | | llvm-svn: 41618
* Fixed bug where the CFG would fail to build when an 'if' statement hadTed Kremenek2007-08-301-7/+14
| | | | | | | | | | | | | an empty then or else block (or contained only ';' statements). For example, we now handle the following: int empty_else() { if (0) { int a; } else ; } int empty_then() { if (0) ; else { int a; } } Thanks to Nico Weber for spotting this problem. llvm-svn: 41617
* Polish yesterday's Array/ConstantArray/VariableArray rewrite, removing a ↵Steve Naroff2007-08-305-47/+52
| | | | | | | | | couple FIXME's. Refactored Array/VariableArray, moving SizeModifier/IndexTypeQuals back up to Array. These attributes are not specific to VLA's. Most of them are specific to array parameter types. llvm-svn: 41616
* implement pretty printing of offsetofChris Lattner2007-08-303-1/+35
| | | | llvm-svn: 41615
* a new testcaseChris Lattner2007-08-301-0/+23
| | | | llvm-svn: 41614
* implement initial sema support for __builtin_offsetofChris Lattner2007-08-306-21/+107
| | | | llvm-svn: 41613
* Pass the location of the type.Chris Lattner2007-08-302-2/+3
| | | | llvm-svn: 41612
* Fix 80 col violations.Chris Lattner2007-08-302-3/+3
| | | | llvm-svn: 41611
* Added Graphviz escaping for the '|' character.Ted Kremenek2007-08-301-1/+1
| | | | llvm-svn: 41610
* Fixed bug for CaseStmt where the child_begin/child_end methods were notTed Kremenek2007-08-302-19/+37
| | | | | | | | | | | including the expressions in the case statement itself (not the body of the case). This required moving SubStmt out of SwitchCase into CaseStmt and DefaultStmt respectively. getSubStmt() now is a virtual call for SwitchCase, but is a direct (static) call for CaseStmt and DefaultStmt. llvm-svn: 41609
* Do not run on darwin.Tanya Lattner2007-08-301-2/+2
| | | | llvm-svn: 41608
* make sure to parse postfix expression suffixes after builtinChris Lattner2007-08-301-7/+10
| | | | | | primary expressions. llvm-svn: 41607
* add an action callback for __builtin_offsetofChris Lattner2007-08-302-12/+57
| | | | llvm-svn: 41606
* -C mode doesn't return comments on "#" lines, so the diag checker doesn't ↵Chris Lattner2007-08-302-2/+7
| | | | | | | | pick them up. Test this the hard way. llvm-svn: 41605
* When relexing the file to find expected warnings/errors, make sureChris Lattner2007-08-301-0/+7
| | | | | | to turn off all lexer-related warnings. llvm-svn: 41604
* fix a bug that is causing CodeGen/complex.c to be grumpy.Chris Lattner2007-08-301-1/+1
| | | | llvm-svn: 41603
* Teach the stmtdumper to dump location/range info when a SourceMgr is available.Chris Lattner2007-08-303-9/+67
| | | | | | | | | | | | | | | | | | | | | For example, -parse-ast-dump now prints: static inline int __inline_isinff(float __x) (CompoundStmt 0x2409a20 (ReturnStmt 0x2409a10 (BinaryOperator 0x24099f0 'int' <///usr/include/architecture/i386/math.h:183:63, col:102> '==' (CallExpr 0x24098f0 'float' <col:63, col:82> (ImplicitCastExpr 0x24098e0 'float (*)(float)' <col:63> (DeclRefExpr 0x2409880 'float (float)' <col:63> Decl='__builtin_fabsf' 0x2409840)) (DeclRefExpr 0x24098a0 'float' <col:79> Decl='__x' 0x2409810)) (CallExpr 0x24099c0 'float' <col:87, col:102> (ImplicitCastExpr 0x2409870 'float (*)(void)' <col:87> (DeclRefExpr 0x2409980 'float (void)' <col:87> Decl='__builtin_inff' 0x2409940)))))) where it only prints filename/line# if it changes from the previous value. We really need loc info on stmts though, like we have on exprs. llvm-svn: 41602
* Fix a regression on test/Sema/unused-expr.c by fixing the type predicatesChris Lattner2007-08-301-1/+1
| | | | | | to test for the right type class. llvm-svn: 41601
* constify a method.Chris Lattner2007-08-302-2/+2
| | | | llvm-svn: 41600
* Added support to fold X86 load / store instructions. This allow ↵Evan Cheng2007-08-303-50/+101
| | | | | | rematerialized loads to be folded into their uses. llvm-svn: 41599
* Try fold re-materialized load instructions into its uses.Evan Cheng2007-08-301-11/+22
| | | | llvm-svn: 41598
* Add a variant of foldMemoryOperand to fold any load / store, not just load / ↵Evan Cheng2007-08-307-5/+42
| | | | | | store from / to stack slots. llvm-svn: 41597
* Added CreateFrameIndex to create a FrameIndex MachineOperand without a ↵Evan Cheng2007-08-301-0/+12
| | | | | | MachineInstr. llvm-svn: 41596
* Mark load instructions with isLoad = 1.Evan Cheng2007-08-305-6/+21
| | | | llvm-svn: 41595
* Fix the following redefinition errors submitted by Keith Bauer...Steve Naroff2007-08-306-94/+176
| | | | | | | | | | | | | | | | | | | | | | | | [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
* Previous commit should have been:Chris Lattner2007-08-301-102/+30
| | | | | | | | | | | | Use Ted's child walking interface to allow the dumper to walk the tree in one place and only have node-specific callbacks worry about formatting the nodes (instead of formatting the nodes plus walking the tree). This commit eliminates now default cases by letting them fall through with the normal visitor stuff. llvm-svn: 41591
* Use i64 on a PPC64 machineBill Wendling2007-08-301-1/+1
| | | | llvm-svn: 41590
* elimiante some virtual calls.Chris Lattner2007-08-302-157/+33
| | | | llvm-svn: 41589
* Allow a SourceManager to optionally be passed into Stmt::dumpChris Lattner2007-08-303-5/+25
| | | | llvm-svn: 41588
* Change LegalFPImmediates to use APFloat.Dale Johannesen2007-08-3011-35/+141
| | | | | | | | | Add APFloat interfaces to ConstantFP, SelectionDAG. Fix integer bit in double->APFloat conversion. Convert LegalizeDAG to use APFloat interface in ConstantFPSDNode uses. llvm-svn: 41587
* Added comments about -dump-cfg and -view-cfg modes for the clang driver.Ted Kremenek2007-08-291-10/+19
| | | | llvm-svn: 41586
* Added an (optional) explicit "Label" statement to CFGBlock. If aTed Kremenek2007-08-292-53/+81
| | | | | | | | | | | | block begins with a label or case statement, CFGBlock::getLabel() will return the corresponding LabelStmt/CaseStmt/DefaultStmt. LabelStmts and SwitchCases no longer appear within the "executable" statements of a CFGBlock. More cleanups on visualization/pretty-printing of CFGs (less verbose). llvm-svn: 41585
* Fix use of declaration inside case blockAnton Korobeynikov2007-08-291-1/+2
| | | | llvm-svn: 41584
* cleanup context-sensitive objc keyword recognition. Patch by Fariborz Jahanian.Chris Lattner2007-08-293-5/+20
| | | | llvm-svn: 41583
* Spaces not tabs.Neil Booth2007-08-292-2/+2
| | | | llvm-svn: 41582
* Ensure we diagnose long long literals in C90 mode.Neil Booth2007-08-293-0/+15
| | | | llvm-svn: 41581
* Added GraphTraits to source-level CFGs (CFG and CFGBlock) to allowTed Kremenek2007-08-295-43/+182
| | | | | | | | | | | | | | | | | | | | (LLVM-provided) graph algorithms such as DFS and graph visualization to work effortless on source-level CFGs. Further cleanup on pretty printing of CFGs. CFGBlock::dump and CFGBlock::print now take the parent CFG as an argument. This allows CFGBlocks to print their own appropriate label indicating whether or not they are the Entry/Exit/IndirectGotoBlock without the CFG::print routine doing it instead. Added Graphviz visualization for CFGs: CFG::viewCFG. This employs the GraphTraits just implemented. Added "-view-cfg" mode the to clang driver. This is identical to "-dump-cfg" except that it calls Graphviz to visualize the CFGs instead of dumping them to the terminal. llvm-svn: 41580
* Change LiveRange so it keeps a pointer to the VNInfo rather than an index.Evan Cheng2007-08-295-352/+316
| | | | | | | Changes related modules so VNInfo's are not copied. This decrease copy coalescing time by 45% and overall compilation time by 10% on siod. llvm-svn: 41579
* Lower FRAME_TO_ADDR_OFFSET to zero by default (if not custom lowered)Anton Korobeynikov2007-08-291-1/+13
| | | | llvm-svn: 41578
* Move getX86RegNum into X86RegisterInfo and use itDuncan Sands2007-08-296-88/+80
| | | | | | | | in the trampoline lowering. Lookup the jump and mov opcodes for the trampoline rather than hard coding them. llvm-svn: 41577
OpenPOWER on IntegriCloud