summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Even though no caller actually uses the new valueDuncan Sands2008-09-011-1/+2
| | | | | | | (what matters is that it is added to the worklist), it seems more logical to return it. llvm-svn: 55606
* Turn this legalize types test on.Duncan Sands2008-09-015-11/+5
| | | | llvm-svn: 55605
* Add a small pass that sets the readnone/readonlyDuncan Sands2008-09-013-0/+75
| | | | | | | | | | | | | | | | | | | | | | | | | attributes on functions, based on the result of alias analysis. It's not hardwired to use GlobalsModRef even though this is the only (AFAIK) alias analysis that results in this pass actually doing something. Enable as follows: opt ... -globalsmodref-aa -markmodref ... Advantages of this pass: (1) records the result of globalsmodref in the bitcode, meaning it is available for use by later passes (currently the pass manager isn't smart enough to magically make an advanced alias analysis available to all later passes), which may expose more optimization opportunities; (2) hopefully speeds up compilation when code is optimized twice, for example when a file is compiled to bitcode, then later LTO is done on it: marking functions readonly/readnone when producing the initial bitcode should speed up alias analysis during LTO; (3) good for discovering that globalsmodref doesn't work very well :) Not currently turned on by default. llvm-svn: 55604
* codegen constant data as such. add QualType::isConstant()Nuno Lopes2008-09-013-0/+14
| | | | llvm-svn: 55603
* Control flow instruction encodings.Evan Cheng2008-09-012-17/+71
| | | | llvm-svn: 55601
* ldm / stm instruction encodings.Evan Cheng2008-09-012-6/+28
| | | | llvm-svn: 55599
* AXI2 and AXI3 instruction encodings.Evan Cheng2008-09-012-10/+94
| | | | llvm-svn: 55598
* Reorganize instruction formats again; AXI1 encoding.Evan Cheng2008-09-011-34/+35
| | | | llvm-svn: 55597
* addrmode3 instruction encodings.Evan Cheng2008-09-012-42/+208
| | | | llvm-svn: 55596
* Reorganize some instruction format definitions. No functionality change.Evan Cheng2008-09-011-18/+29
| | | | llvm-svn: 55594
* Rest of addrmode2 instruction encodings.Evan Cheng2008-09-012-14/+106
| | | | llvm-svn: 55593
* Addr2 word / byte load encodings.Evan Cheng2008-08-312-4/+24
| | | | llvm-svn: 55591
* Addr1 instructions opcodes are encoded in bits 21-24; encode S bit.Evan Cheng2008-08-311-4/+5
| | | | llvm-svn: 55590
* Patch by Kovarththanan Rajaratnam!Ted Kremenek2008-08-311-0/+10
| | | | | | "This minor patch adds markup of string literals with a red colour." llvm-svn: 55589
* fix a bunch of 80-col violationsGabor Greif2008-08-315-33/+65
| | | | llvm-svn: 55588
* Handle mutation while enumerating correctly. Fix some bugs.Anders Carlsson2008-08-314-7/+79
| | | | llvm-svn: 55583
* Revert the "XFAIL" for the rotate_ops.ll testcase. Instead, mark ISD::ROTRBill Wendling2008-08-312-8/+7
| | | | | | | | instructions in CellSPU as "Expand" so that they won't be generated. I added a "FIXME" so that this hack can be addressed and reverted once ISD::ROTR is supported in the .td files. llvm-svn: 55582
* Expand for ROTR with MVT::i64.Bill Wendling2008-08-311-0/+1
| | | | | | Dale, Could you please review this? llvm-svn: 55581
* Initial support for CodeGen of for ... in statements.Anders Carlsson2008-08-311-1/+151
| | | | llvm-svn: 55580
* CellSPU doesn't appear to support fully the "ISD::ROTR" operation. The DAGBill Wendling2008-08-311-0/+6
| | | | | | | | combiner can now generate ROTR if the backend says that it can handle it. Cell SPU says this, but gets an error from code gen saying that it can't select ROTR. I'm xfailing this test until this can be fixed. llvm-svn: 55579
* Cosmetic changes to Machine LICM. No functionality change.Bill Wendling2008-08-311-31/+36
| | | | llvm-svn: 55578
* Another situation where ROTR is cheaper than ROTL.Bill Wendling2008-08-311-3/+3
| | | | llvm-svn: 55577
* For this pattern, ROTR is the cheaper option.Bill Wendling2008-08-311-4/+4
| | | | llvm-svn: 55576
* - Fix comment so that it describes how the code really works:Bill Wendling2008-08-311-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | // fold (or (shl x, (*ext y)), (srl x, (*ext (sub 32, y)))) -> // (rotl x, y) // fold (or (shl x, (*ext y)), (srl x, (*ext (sub 32, y)))) -> // (rotr x, (sub 32, y)) Example: (x == 0xDEADBEEF and y == 4) (x << 4) | (x >> 28) => 0xEADBEEF0 | 0x0000000D => 0xEADBEEFD (rotl x, 4) => 0xEADBEEFD (rotr x, 28) => 0xEADBEEFD - Fix comment and code for second version. It wasn't using the rot* propertly. // fold (or (shl x, (*ext (sub 32, y))), (srl x, (*ext r))) -> // (rotr x, y) // fold (or (shl x, (*ext (sub 32, y))), (srl x, (*ext r))) -> // (rotl x, (sub 32, y)) (x << 28) | (x >> 4) => 0xD0000000 | 0x0DEADBEE => 0xDDEADBEE (rotl x, 4) => 0xEADBEEFD (rotr x, 28) => (0xEADBEEFD) llvm-svn: 55575
* typoGabor Greif2008-08-301-1/+1
| | | | llvm-svn: 55574
* Stub out CodeGenFunction::EmitObjCForCollectionStmt.Anders Carlsson2008-08-305-20/+34
| | | | | | Add CodeGenFunction::EmitMemSetToZero and make AggExprEmitter::EmitAggregateClear use it. llvm-svn: 55573
* Add code to create the fast enumeration state typeAnders Carlsson2008-08-302-1/+33
| | | | llvm-svn: 55572
* fix some 80-col violationsGabor Greif2008-08-301-19/+23
| | | | llvm-svn: 55571
* PR2731: C and Ocaml bindings for setTailCall and isTailCall.Gordon Henriksen2008-08-306-0/+47
| | | | | | Based on patch by Giorgos Korfiatis. llvm-svn: 55570
* Temporarily disable some tests which due to dot-syntaxDaniel Dunbar2008-08-302-2/+2
| | | | | | access of methods. llvm-svn: 55569
* Fix indentation on files in CodeGen and Sema.Anders Carlsson2008-08-301-33/+33
| | | | llvm-svn: 55568
* Simplify some calls to Builder.CreateCallAnders Carlsson2008-08-302-22/+17
| | | | llvm-svn: 55567
* Fix ConstantExpr::getInsertElement.Gordon Henriksen2008-08-301-2/+1
| | | | | | | Breakage was exposed in the Ocaml bindings tests after Chris uncommented an assertion in r55084. llvm-svn: 55566
* fix some 80-col violationsGabor Greif2008-08-303-4/+7
| | | | llvm-svn: 55565
* Re-apply 55467 with fix. If copy is being replaced by remat'ed def, transfer ↵Evan Cheng2008-08-304-6/+87
| | | | | | the implicit defs onto the remat'ed instruction. llvm-svn: 55564
* Fold isRematerializable checks into isSafeToReMat.Evan Cheng2008-08-301-1/+3
| | | | llvm-svn: 55563
* For now, can't mark XOR64rr isAsCheapAsAMove. It's technically correct. But ↵Evan Cheng2008-08-301-1/+1
| | | | | | various passes cannot handle remating these. llvm-svn: 55562
* Add Objective-C property setter support.Daniel Dunbar2008-08-3010-46/+139
| | | | | | | | | | | | | | | | | | | | | | - Change Obj-C runtime message API, drop the ObjCMessageExpr arg in favor of just result type and selector. Necessary so it can be reused in situations where we don't want to cons up an ObjCMessageExpr. - Update aggregate binary assignment to know about special property ref lvalues. - Add CodeGenFunction::EmitCallArg overload which takes an already emitted rvalue. Add CodeGenFunction::StoreComplexIntoAddr. Disabled logic in Sema for parsing Objective-C dot-syntax that accesses methods. This code does not search in the correct order and the AST node has no way of properly representing its results. Updated StmtDumper to print a bit more information about ObjCPropertyRefExprs. llvm-svn: 55561
* Refactor handling of calls:Daniel Dunbar2008-08-306-93/+158
| | | | | | | | | | | | | | | | - Added CodeGenFunction::EmitCall which just takes the callee, return type, and a list of (Value*,QualType) pairs. - Added CodeGenFunction::EmitCallArg which handles emitting code for a call argument and turning it into an appropriate (Value*,QualType) pair. - Changed Objective-C runtime interface so that the actual emission of arguments for message sends is (once again) done in the code to emit a message send. No intended functionality change, this is prep work for better ABI support and for Objective-C property setter support. llvm-svn: 55560
* Add newline at end of file.Daniel Dunbar2008-08-301-1/+1
| | | | llvm-svn: 55559
* Transform (x << (y&31)) -> (x << y). This takes advantage of the fact x86 ↵Evan Cheng2008-08-304-0/+140
| | | | | | shift instructions 2nd operand (shift count) is limited to 0 to 31 (or 63 in the x86-64 case). llvm-svn: 55558
* Enable -fvisibility-inlines-hidden by default for compilers whichDaniel Dunbar2008-08-305-25/+148
| | | | | | support it. llvm-svn: 55557
* Testcases for ppc atomics.Dale Johannesen2008-08-302-0/+1522
| | | | llvm-svn: 55556
* Fix an issue where a use might be selected before a def, and then we didn't ↵Owen Anderson2008-08-302-8/+26
| | | | | | | | | | | respect the pre-chosen vreg assignment when selecting the def. This is the naive solution to the problem: insert a copy to the pre-chosen vreg. Other solutions might be preferable, such as: 1) Passing the dest reg into FastEmit_. However, this would require the higher level code to know about reg classes, which they don't currently. 2) Selecting blocks in reverse postorder. This has some compile time cost for computing the order, and we'd need to measure its impact. llvm-svn: 55555
* Add ppc partial-word ATOMIC_CMP_SWAP.Dale Johannesen2008-08-301-4/+143
| | | | llvm-svn: 55554
* Swap fp comparison operands and change predicate to allow load folding ↵Evan Cheng2008-08-292-17/+51
| | | | | | (safely this time). llvm-svn: 55553
* Use static_cast instead of C style cast.Evan Cheng2008-08-291-1/+2
| | | | llvm-svn: 55552
* Fix 80 col. violations.Evan Cheng2008-08-291-2/+4
| | | | llvm-svn: 55551
* xfail this.Evan Cheng2008-08-291-0/+1
| | | | llvm-svn: 55550
* Back out 55498. It broken Apple style bootstrapping.Evan Cheng2008-08-291-106/+81
| | | | llvm-svn: 55549
OpenPOWER on IntegriCloud