summaryrefslogtreecommitdiffstats
path: root/llvm/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* Initial implementation of PPCTargetTransformInfoHal Finkel2013-01-255-0/+237
| | | | | | | | | | This provides a place to add customized operation cost information and control some other target-specific IR-level transformations. The only non-trivial logic in this checkin assigns a higher cost to unaligned loads and stores (covered by the included test case). llvm-svn: 173520
* Fix a warning in the new DWARFheader. Add a new line at the end of the file.Nadav Rotem2013-01-251-1/+2
| | | | llvm-svn: 173518
* Add support for applying in-memory relocations to the .debug_line section ↵Andrew Kaylor2013-01-257-8/+57
| | | | | | and, in the case of ELF files, using symbol addresses when available for relocations to the .debug_info section. Also extending the llvm-rtdyld tool to add the ability to dump line number information for testing purposes. llvm-svn: 173517
* In this patch, we teach X86_64TargetMachine that it has a ILP32Eli Bendersky2013-01-254-18/+39
| | | | | | | | | | | | | | | | | | | | | (defined by the x32 ABI) mode, in which case its pointers are 32-bits in size. This knowledge is also added to X86RegisterInfo that now returns the appropriate registers in getPointerRegClass. There are many outcomes to this change. In order to keep the patches separate and manageable, we start by focusing on some simple testable cases. The patch adds a test with passing a pointer to a function - focusing on the difference between the two data models for x86-64. Another test is added for handling of 'sret' arguments (and functionality is added in X86ISelLowering to make it work). A note on naming: the "x32 ABI" document refers to the AMD64 architecture (in LLVM it's distinguished by being is64Bits() in the x86 subtarget) with two variations: the LP64 (default) data model, and the ILP32 data model. This patch adds predicates to the subtarget which are consistent with this naming scheme. llvm-svn: 173503
* Add instruction encodings / disassembly support for l4r instructions.Richard Osborne2013-01-253-18/+83
| | | | llvm-svn: 173501
* LoopVectorize: Refactor the code that vectorizes loads/stores to remove ↵Nadav Rotem2013-01-251-145/+113
| | | | | | duplication. llvm-svn: 173500
* Use the new 'getSlotIndex' method to retrieve the attribute's slot index.Bill Wendling2013-01-256-8/+8
| | | | llvm-svn: 173499
* Use const reference instead of vector copying.Jakub Staszak2013-01-251-1/+2
| | | | llvm-svn: 173497
* Add an accessor method to get the slot's index. This will limit the use of ↵Bill Wendling2013-01-253-12/+22
| | | | | | AttributeWithIndex. llvm-svn: 173495
* Use the correct format in the STW / SETPSC instruction names.Richard Osborne2013-01-253-9/+9
| | | | llvm-svn: 173494
* Fix order of operands for crc8_l4rRichard Osborne2013-01-254-27/+48
| | | | | | | | The order in which operands appear in the encoded instruction is different to order in which they appear in assembly. This changes the XCore backend to use the instruction encoding order. llvm-svn: 173493
* When encountering an unknown file format, ObjectFile::createObjectFile shouldEli Bendersky2013-01-251-1/+3
| | | | | | | | | politely report it instead of running into llvm_unreachable. Also patch llvm-dwarfdump to actually check whether the file it's attempting to dump is a valid object file. llvm-svn: 173489
* Add command-line flags for DWARF dumping.Eli Bendersky2013-01-252-63/+83
| | | | | | | Flags for dumping specific DWARF sections added in lib/DebugInfo and llvm-dwarfdump. llvm-svn: 173480
* Add instruction encodings / disassembly support for l5r instructions.Richard Osborne2013-01-253-12/+55
| | | | llvm-svn: 173479
* Fix order of operands for l5r instructions.Richard Osborne2013-01-252-18/+22
| | | | | | | With this change the operands order matches the order in which the operands are encoded in the instruction. llvm-svn: 173477
* Use correct mnemonic / instruction name for ldivu.Richard Osborne2013-01-251-4/+3
| | | | llvm-svn: 173476
* LoopVectorize: Simplify code. No functionality change.Benjamin Kramer2013-01-251-26/+17
| | | | llvm-svn: 173475
* added ability to dynamically change the ExportList of an alreadyPedro Artigas2013-01-251-0/+10
| | | | | | created InternalizePass (useful for pass reuse) llvm-svn: 173474
* LoopVectorizer: Refactor more code to use the IRBuilder. Nadav Rotem2013-01-251-24/+25
| | | | llvm-svn: 173471
* Refactor some code to use the IRBuilder.Nadav Rotem2013-01-251-20/+21
| | | | llvm-svn: 173467
* APFloat: Make sure that we get a well-formed x87 NaN when converting from a ↵Benjamin Kramer2013-01-251-0/+6
| | | | | | | | smaller type. Fixes PR15054. llvm-svn: 173459
* Fix MSVC 2012 warning about a 32-bit shift that should be 64-bitReid Kleckner2013-01-251-2/+2
| | | | llvm-svn: 173454
* [msan] A comment on ICmp handling logic.Evgeniy Stepanov2013-01-251-0/+3
| | | | llvm-svn: 173453
* [msan] Implement exact shadow propagation for relational ICmp.Evgeniy Stepanov2013-01-251-0/+70
| | | | | | | | Only for integers, pointers, and vectors of those. No floats. Instrumentation seems very heavy, and may need to be replaced with some approximation in the future. llvm-svn: 173452
* This patch aims to reduce compile time in LegalizeTypes by using SmallDenseMap,Preston Gurd2013-01-252-9/+9
| | | | | | | | | | | | | with an initial number of elements, instead of DenseMap, which has zero initial elements, in order to avoid the copying of elements when the size changes and to avoid allocating space every time LegalizeTypes is run. This patch will not affect the memory footprint, because DenseMap will increase the element size to 64 when the first element is added. Patch by Wan Xiaofei. llvm-svn: 173448
* More cleanup of PPC register definitions.Hal Finkel2013-01-251-64/+8
| | | | | | | Uses the new !add TableGen operator to do more cleanup of the PPC register definitions. llvm-svn: 173446
* Add an addition operator to TableGenHal Finkel2013-01-254-1/+9
| | | | | | | This adds an !add(a, b) operator to tablegen; this will be used to cleanup the PPC register definitions. llvm-svn: 173445
* Fixed the condition codes for the atomic64 min/umin code generation on ARM. ↵Silviu Baranga2013-01-251-2/+2
| | | | | | If the sutraction of the higher 32 bit parts gives a 0 result, we need to do the store operation. llvm-svn: 173437
* Use the AttributeSet query instead of the Attribute query.Bill Wendling2013-01-251-2/+2
| | | | llvm-svn: 173434
* MIsched: Print block name. No functionality.Andrew Trick2013-01-251-1/+2
| | | | llvm-svn: 173433
* MachineScheduler support for viewGraph.Andrew Trick2013-01-251-1/+88
| | | | llvm-svn: 173432
* ScheduleDAG: colorize the DOT graph and improve formatting.Andrew Trick2013-01-254-2/+21
| | | | llvm-svn: 173431
* ScheduleDAG: Added isBoundaryNode to conveniently detect a common corner case.Andrew Trick2013-01-251-7/+19
| | | | | | This fixes DAG subtree analysis at the boundary. llvm-svn: 173427
* SchedDFS: Complete support for nested subtrees.Andrew Trick2013-01-251-33/+74
| | | | | | | | | Maintain separate per-node and per-tree book-keeping. Track all instructions above a DAG node including nested subtrees. Seperately track instructions within a subtree. Record subtree parents. llvm-svn: 173426
* MIsched: Improve the interface to SchedDFS analysis (subtrees).Andrew Trick2013-01-253-35/+49
| | | | | | | Allow the strategy to select SchedDFS. Allow the results of SchedDFS to affect initialization of the scheduler state. llvm-svn: 173425
* SchedDFS: Initial support for nested subtrees.Andrew Trick2013-01-251-37/+73
| | | | | | | This is mostly refactoring, along with adding an instruction count within the subtrees and ensuring we only look at data edges. llvm-svn: 173420
* Switch this code away from Value::isUsedInBasicBlock. That code eitherChandler Carruth2013-01-251-7/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | loops over instructions in the basic block or the use-def list of the value, neither of which are really efficient when repeatedly querying about values in the same basic block. What's more, we already know that the CondBB is small, and so we can do a much more efficient test by counting the uses in CondBB, and seeing if those account for all of the uses. Finally, we shouldn't blanket fail on any such instruction, instead we should conservatively assume that those instructions are part of the cost. Note that this actually fixes a bug in the pass because isUsedInBasicBlock has a really terrible bug in it. I'll fix that in my next commit, but the fix for it would make this code suddenly take the compile time hit I thought it already was taking, so I wanted to go ahead and migrate this code to a faster & better pattern. The bug in isUsedInBasicBlock was also causing other tests to test the wrong thing entirely: for example we weren't actually disabling speculation for floating point operations as intended (and tested), but the test passed because we failed to speculate them due to the isUsedInBasicBlock failure. llvm-svn: 173417
* MISched: Add SchedDFSResult to ScheduleDAGMI to formalize theAndrew Trick2013-01-251-25/+55
| | | | | | interface and allow other strategies to select it. llvm-svn: 173413
* This patch implements parsing the .wordJack Carter2013-01-251-7/+42
| | | | | | | | directive for the Mips assembler. Contributer: Vladimir Medic llvm-svn: 173407
* [mips] Set flag neverHasSideEffects flag on some of the floating point ↵Akira Hatanaka2013-01-251-12/+8
| | | | | | instructions. llvm-svn: 173401
* SchedDFS: Refactor and tweak the subtree selection criteria.Andrew Trick2013-01-251-24/+32
| | | | | | | | | | For sanity, create a root when NumDataSuccs >= 4. Splitting large subtrees will no longer be detrimental after my next checkin to handle nested tree. A magic number of 4 is fine because single subtrees seldom rejoin more than this. It makes subtrees easier to visualize and heuristics more sane. llvm-svn: 173399
* Avoid creating duplicate CFG edges in the IfConversion pass.Jakob Stoklund Olesen2013-01-241-1/+1
| | | | | | Patch by Stefan Hepp. llvm-svn: 173395
* Moving Cost Tables up to share with other targetsRenato Golin2013-01-241-48/+11
| | | | llvm-svn: 173382
* Added comment to ObjCARC elaborating what is meant by the term 'Provenance' ↵Michael Gottesman2013-01-241-0/+6
| | | | | | in 'Provenance Analysis'. llvm-svn: 173374
* Start cleanup of PPC register definitions using foreach loops.Hal Finkel2013-01-241-65/+7
| | | | | | | | | | | No functionality change intended. This captures the first two cases GPR32/64. For the others, we need an addition operator (if we have one, I've not yet found it). Based on a suggestion made by Tom Stellard in the AArch64 review! llvm-svn: 173366
* Reapply chandlerc's r173342 now that the miscompile it was triggering is fixed.Benjamin Kramer2013-01-241-9/+18
| | | | | | | | | | | | | | | | | | | | Original commit message: Plug TTI into the speculation logic, giving it a real cost interface that can be specialized by targets. The goal here is not to be more aggressive, but to just be more accurate with very obvious cases. There are instructions which are known to be truly free and which were not being modeled as such in this code -- see the regression test which is distilled from an inner loop of zlib. Everywhere the TTI cost model is insufficiently conservative I've added explicit checks with FIXME comments to go add proper modelling of these cost factors. If this causes regressions, the likely solution is to make TTI even more conservative in its cost estimates, but test cases will help here. llvm-svn: 173357
* ConstantFolding: Add a missing folding that leads to a miscompile.Benjamin Kramer2013-01-241-4/+4
| | | | | | | | | | We use constant folding to see if an intrinsic evaluates to the same value as a constant that we know. If we don't take the undefinedness into account we get a value that doesn't match the actual implementation, and miscompiled code. This was uncovered by Chandler's simplifycfg changes. llvm-svn: 173356
* Revert r173342 temporarily. It appears to cause a very late miscompileChandler Carruth2013-01-241-18/+9
| | | | | | of stage2 in a bootstrap. Still investigating.... llvm-svn: 173343
* Plug TTI into the speculation logic, giving it a real cost interfaceChandler Carruth2013-01-241-9/+18
| | | | | | | | | | | | | | | | | | that can be specialized by targets. The goal here is not to be more aggressive, but to just be more accurate with very obvious cases. There are instructions which are known to be truly free and which were not being modeled as such in this code -- see the regression test which is distilled from an inner loop of zlib. Everywhere the TTI cost model is insufficiently conservative I've added explicit checks with FIXME comments to go add proper modelling of these cost factors. If this causes regressions, the likely solution is to make TTI even more conservative in its cost estimates, but test cases will help here. llvm-svn: 173342
* Address a large chunk of this FIXME by accumulating the cost forChandler Carruth2013-01-241-8/+6
| | | | | | | unfolded constant expressions rather than checking each one independently. llvm-svn: 173341
OpenPOWER on IntegriCloud