aboutsummaryrefslogtreecommitdiffstats
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
* This is not actually unreachable, so don't use llvm_unreachable for it. SinceNick Lewycky2011-08-191-1/+2
| | | | | | | | | | | the intent seems to be to terminate even in Release builds, just use abort() directly. If program flow ever reaches a __builtin_unreachable (which llvm_unreachable is #define'd to on newer GCCs) then the program is undefined. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138068 91177308-0d34-0410-b5e6-96231b3b80d8
* Tab characters.Jim Grosbach2011-08-191-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138066 91177308-0d34-0410-b5e6-96231b3b80d8
* Thumb assembly parsing and encoding for LSL(immediate).Jim Grosbach2011-08-192-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138063 91177308-0d34-0410-b5e6-96231b3b80d8
* Thumb assembly parsing and encoding for LDRSB and LDRSH.Jim Grosbach2011-08-191-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138061 91177308-0d34-0410-b5e6-96231b3b80d8
* Thumb assembly parsing and encoding for LDRH.Jim Grosbach2011-08-192-0/+18
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138060 91177308-0d34-0410-b5e6-96231b3b80d8
* Thumb assembly parsing and encoding for LDRB.Jim Grosbach2011-08-192-0/+18
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138059 91177308-0d34-0410-b5e6-96231b3b80d8
* Fixed a memory bug in the MCDisassembler whereSean Callanan2011-08-191-1/+5
| | | | | | | MCParsedAsmOperand objects were being leaked. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138053 91177308-0d34-0410-b5e6-96231b3b80d8
* Thumb assembly parsing and encoding for LDR(literal).Jim Grosbach2011-08-191-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138052 91177308-0d34-0410-b5e6-96231b3b80d8
* Thumb assembly parsing and encoding for LDR(immediate) form T2.Jim Grosbach2011-08-192-1/+18
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138050 91177308-0d34-0410-b5e6-96231b3b80d8
* Use helper function to check for low registers.Jim Grosbach2011-08-191-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138048 91177308-0d34-0410-b5e6-96231b3b80d8
* Thumb assembly parsing and encoding for LDR(immediate) form T1.Jim Grosbach2011-08-192-1/+20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138047 91177308-0d34-0410-b5e6-96231b3b80d8
* Add explanatory comment.Jim Grosbach2011-08-191-0/+5
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138042 91177308-0d34-0410-b5e6-96231b3b80d8
* Have SPU backend use the external TCE scheduler, if the library is loaded as aKalle Raiskila2011-08-191-0/+11
| | | | | | | | | module. Patch by Pekka Jääskeläinen. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138037 91177308-0d34-0410-b5e6-96231b3b80d8
* Add TB encoding to VEX versions of SSE fp logical operations to fix disassemblerCraig Topper2011-08-191-6/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138034 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix PR10677. Initial patch and idea by Peter Cooper but I've changed theBruno Cardoso Lopes2011-08-191-3/+8
| | | | | | implementation! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138029 91177308-0d34-0410-b5e6-96231b3b80d8
* Add llc flags to disable machine DCE and CSE.Jakob Stoklund Olesen2011-08-191-2/+8
| | | | | | This is useful for unit tests. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138028 91177308-0d34-0410-b5e6-96231b3b80d8
* Make a bunch of symbols private.Benjamin Kramer2011-08-195-5/+7
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138025 91177308-0d34-0410-b5e6-96231b3b80d8
* C API functions must be able to see their extern "C" definitions, or it will ↵Benjamin Kramer2011-08-192-0/+2
| | | | | | be impossible to call them from C. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138022 91177308-0d34-0410-b5e6-96231b3b80d8
* Don't treat a partial <def,undef> operand as a read.Jakob Stoklund Olesen2011-08-191-1/+2
| | | | | | | | | | | | | | | | | | | | | | | Normally, a partial register def is treated as reading the super-register unless it also defines the full register like this: %vreg110:sub_32bit<def> = COPY %vreg77:sub_32bit, %vreg110<imp-def> This patch also uses the <undef> flag on partial defs to recognize non-reading operands: %vreg110:sub_32bit<def,undef> = COPY %vreg77:sub_32bit This fixes a subtle bug in RegisterCoalescer where LIS->shrinkToUses would treat a coalesced copy as still reading the register, extending the live range artificially. My test case only works when I disable DCE so a dead copy is left for RegisterCoalescer, so I am not including it. <rdar://problem/9967101> git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138018 91177308-0d34-0410-b5e6-96231b3b80d8
* Track a retain+release nesting level independently of theDan Gohman2011-08-191-36/+64
| | | | | | | | | known-incremented level, because the two concepts can be used to prove the saftey of a retain+release removal in different ways. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138016 91177308-0d34-0410-b5e6-96231b3b80d8
* Intelligently split the landing pad block.Bill Wendling2011-08-191-5/+16
| | | | | | | | | | | We have to be careful when splitting the landing pad block, because the landingpad instruction is required to remain as the first non-PHI of an invoke's unwind edge. To retain this, we split the block into two blocks, moving the predecessors within the loop to one block and the remaining predecessors to the other. The landingpad instruction is cloned into the new blocks. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138015 91177308-0d34-0410-b5e6-96231b3b80d8
* Add SplitLandingPadPredecessors().Bill Wendling2011-08-191-1/+95
| | | | | | | | | | | | | | | | | SplitLandingPadPredecessors is similar to SplitBlockPredecessors in that it splits the current block and attaches a set of predecessors to the new basic block. However, it differs from SplitBlockPredecessors in that it's specifically designed to handle landing pad blocks. Two new basic blocks are created: one that is has the vector of predecessors as its predecessors and one that has the remaining predecessors as its predecessors. Those two new blocks then receive a cloned copy of the landingpad instruction from the original block. The landingpad instructions are joined in a PHI, etc. Like SplitBlockPredecessors, it updates the LLVM IR, AliasAnalysis, DominatorTree, DominanceFrontier, LoopInfo, and LCCSA analyses. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138014 91177308-0d34-0410-b5e6-96231b3b80d8
* Re-encoded 128-bit AVX versions of SQRT, RSQRT, RCP have 3 operandsBruno Cardoso Lopes2011-08-181-31/+64
| | | | | | | | | | | | | | | | | | instead of 2. They were already defined this way in their regular version, but not for the intrinsics versions (*_Int), and that would work for assembly emission but not for object code, since a MachineOperand would be missing. This commit fix PR10697. Also removed the {VSQRT,VRSQRT,VRCP}r_Int forms and match the intrinsic via INSERT_SUBREG+EXTRACT_SUBREG patterns. The same couldn't be done for memory versions because sse_load_f32/sse_load_f64 operand need special handling and don't work like regular "addr" operands. There are right now 114 "*_Int" and 98 "Int_*" forms! I'm slowly removing them as I step through, but hope we can get rid of these someday, they are really annoying :) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138012 91177308-0d34-0410-b5e6-96231b3b80d8
* There is no need to add file as context for subroutine type. The subroutine ↵Devang Patel2011-08-181-2/+2
| | | | | | type does not need any context. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138010 91177308-0d34-0410-b5e6-96231b3b80d8
* add the comments of each declaration follow it, making it easier to read and ↵Renato Golin2011-08-181-49/+44
| | | | | | compare to GCC's result. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138009 91177308-0d34-0410-b5e6-96231b3b80d8
* Use 'getFirstInsertionPt' when trying to insert new instructions during LICM.Bill Wendling2011-08-181-3/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138008 91177308-0d34-0410-b5e6-96231b3b80d8
* Use subword loads instead of a 4-byte load when the size of a structure (or aAkira Hatanaka2011-08-181-26/+73
| | | | | | | | piece of it) that is being passed by value is smaller than a word. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138007 91177308-0d34-0410-b5e6-96231b3b80d8
* Eliminate unnecessary forwarding function.Devang Patel2011-08-183-19/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138006 91177308-0d34-0410-b5e6-96231b3b80d8
* Add NativeClient operating system support.Ivan Krasin2011-08-181-0/+1
| | | | | | | | | | | | | | | | | This patch adds support of NativeClient (*-*-nacl) OS support to LLVM. It's already supported in autoconf/config.sub. The motivation for this change is to start upstreaming PNaCl work. The whole set of patches include llvm backends (i686, x86_64, ARM), llvm-gcc (probably, would not be upstreamed because it's deprecated) and clang (the work has been just started, the amount of changes is going to be low and the most of the work is expected to be done close to the mainline). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138005 91177308-0d34-0410-b5e6-96231b3b80d8
* STC2L_POST and STC2L_POST should be handled the same as STCL_POST/LDC_POST ↵Owen Anderson2011-08-181-0/+4
| | | | | | | | | for the purposes of decoding all operands except the predicate. Found by randomized testing. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138003 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix the decoding of RFE instruction. RFEs have the load bit set, while SRSs ↵Owen Anderson2011-08-181-8/+42
| | | | | | have it unset. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138000 91177308-0d34-0410-b5e6-96231b3b80d8
* Add new DIE into the map asap.Devang Patel2011-08-181-8/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137998 91177308-0d34-0410-b5e6-96231b3b80d8
* Remember to fill in some operands so we can print _something_ coherent even ↵Owen Anderson2011-08-181-1/+4
| | | | | | when decoding the CPS instruction soft-fails. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137997 91177308-0d34-0410-b5e6-96231b3b80d8
* Improve handling of failure and unpredictable cases for CPS, STR, and SMLA ↵Owen Anderson2011-08-181-11/+18
| | | | | | | | | instructions. Fixes a large class of disassembler crashes found by randomized testing. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137995 91177308-0d34-0410-b5e6-96231b3b80d8
* FastISel: avoid function calls between the materialization of the constant ↵Ivan Krasin2011-08-181-5/+20
| | | | | | and its use. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137993 91177308-0d34-0410-b5e6-96231b3b80d8
* Thumb assembly parsing and encoding for LDM instruction.Jim Grosbach2011-08-183-5/+33
| | | | | | | | | Fix base register type and canonicallize to the "ldm" spelling rather than "ldmia." Add diagnostics for incorrect writeback token and out-of-range registers. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137986 91177308-0d34-0410-b5e6-96231b3b80d8
* Make it clear that this code is iterating in reverse order through the array.Dan Gohman2011-08-181-2/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137985 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert r137871. The loop simplify pass should require all exits from a loop thatBill Wendling2011-08-181-15/+3
| | | | | | | aren't from an indirect branch need to be dominated by the loop header. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137981 91177308-0d34-0410-b5e6-96231b3b80d8
* Split out the updating of PHI nodes after splitting the BB into a separateBill Wendling2011-08-181-43/+53
| | | | | | | function. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137979 91177308-0d34-0410-b5e6-96231b3b80d8
* Use this fantzy ArrayRef thing to pass in the list of predecessors.Bill Wendling2011-08-181-9/+14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137978 91177308-0d34-0410-b5e6-96231b3b80d8
* Make IsShiftedMask a static function rather than defining it in anAkira Hatanaka2011-08-181-16/+14
| | | | | | | | anonymous namespace. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137975 91177308-0d34-0410-b5e6-96231b3b80d8
* The edge from DISubprogram to DICompileUnit has been removed in recent versionsNick Lewycky2011-08-181-1/+1
| | | | | | | of debug info. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137972 91177308-0d34-0410-b5e6-96231b3b80d8
* Thumb assembly parsing and encoding for CMP.Jim Grosbach2011-08-181-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137963 91177308-0d34-0410-b5e6-96231b3b80d8
* Use static instead of anonymous namespace.Bill Wendling2011-08-181-7/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137959 91177308-0d34-0410-b5e6-96231b3b80d8
* Thumb instructions CBZ and CBNZ are Thumb2, not THumb1.Jim Grosbach2011-08-182-25/+28
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137956 91177308-0d34-0410-b5e6-96231b3b80d8
* Rip out the old StructType APIs as warned about on llvmdev last week.Chris Lattner2011-08-181-38/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137953 91177308-0d34-0410-b5e6-96231b3b80d8
* ARM Thumb blx instruction fixup has same data range as bl.Jim Grosbach2011-08-181-1/+1
| | | | | | | | | | These fixups are handled poorly in general, and should have a single contiguous range of bits per fixup type, but that's not how they're currently organized, so for now in complex ones like for blx, we just tell the emitter it's OK for the fixup to munge any bit it wants. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137947 91177308-0d34-0410-b5e6-96231b3b80d8
* 80 columns.Jim Grosbach2011-08-181-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137946 91177308-0d34-0410-b5e6-96231b3b80d8
* Clenup and fix encoding for Mips ins and ext instructionBruno Cardoso Lopes2011-08-181-17/+13
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137943 91177308-0d34-0410-b5e6-96231b3b80d8
* Add missing 'break'.Jim Grosbach2011-08-181-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137941 91177308-0d34-0410-b5e6-96231b3b80d8