summaryrefslogtreecommitdiff
path: root/lib/CodeGen
Commit message (Collapse)AuthorAge
...
* Pretty print DBG_VALUE machine instructions.Evan Cheng2010-04-28
| | | | | | | | | | Before: DBG_VALUE %RSI, 0, !-1; dbg:SimpleRegisterCoalescing.cpp:2707 Now: DBG_VALUE %RSI, 0, !"this"; dbg:SimpleRegisterCoalescing.cpp:2707 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102518 91177308-0d34-0410-b5e6-96231b3b80d8
* Rework global alignment computation again. Now we do round upChris Lattner2010-04-28
| | | | | | | | | alignment of globals to the preferred alignment, but only when there is no section specified on the global (by far the common case). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102515 91177308-0d34-0410-b5e6-96231b3b80d8
* While lowering dbg_declare, emit DBG_VALUE machine instruction if alloca ↵Devang Patel2010-04-28
| | | | | | matching llvm.dbg.declare intrinsic is missing. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102513 91177308-0d34-0410-b5e6-96231b3b80d8
* Recompute kill flags from live intervals after coalescing instead of trying toJakob Stoklund Olesen2010-04-28
| | | | | | | | | | | update them. Computing kill flags is notoriously difficult, and the coalescer would get it wrong sometimes, and it would completely skip physical registers. Now we simply remove kill flags based on the live intervals after coalescing. This is a few percent slower, but now we get correct kill flags for physical registers after coalescing. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102510 91177308-0d34-0410-b5e6-96231b3b80d8
* Try operation promotion only if regular dag combine and target-specific ones ↵Evan Cheng2010-04-28
| | | | | | failed to do anything. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102492 91177308-0d34-0410-b5e6-96231b3b80d8
* Emit debug info for byval parameters.Devang Patel2010-04-28
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102486 91177308-0d34-0410-b5e6-96231b3b80d8
* further simplify EmitAlignment by eliminating the Chris Lattner2010-04-28
| | | | | | | ForcedAlignBits argument, tweaking the single client of it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102484 91177308-0d34-0410-b5e6-96231b3b80d8
* remove a dead argument to EmitAlignment.Chris Lattner2010-04-28
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102483 91177308-0d34-0410-b5e6-96231b3b80d8
* remove some default arguments to EmitAlignment.Chris Lattner2010-04-28
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102482 91177308-0d34-0410-b5e6-96231b3b80d8
* Refactor. Devang Patel2010-04-28
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102481 91177308-0d34-0410-b5e6-96231b3b80d8
* Use isReg(), isImm() and isFPImm().Devang Patel2010-04-27
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102470 91177308-0d34-0410-b5e6-96231b3b80d8
* Check operand type first.Devang Patel2010-04-27
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102468 91177308-0d34-0410-b5e6-96231b3b80d8
* Ignore DBG_VALUE instructions that points to undef values.Devang Patel2010-04-27
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102463 91177308-0d34-0410-b5e6-96231b3b80d8
* - When legal, promote a load to zextload rather than ext load.Evan Cheng2010-04-27
| | | | | | | - Catch more further dag combine opportunities as result of operand promotion, e.g. (i32 anyext (i16 trunc (i32 x))) -> (i32 x) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102455 91177308-0d34-0410-b5e6-96231b3b80d8
* Identify when a lexical scope is split in to multiple instruction ranges. ↵Devang Patel2010-04-27
| | | | | | | | | Emit such ranges using DW_AT_ranges. This patch fixes bug (PR6894) introduced by previous version of this patch. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102454 91177308-0d34-0410-b5e6-96231b3b80d8
* Do not count kill, implicit_def instructions as printed instructions.Evan Cheng2010-04-27
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102453 91177308-0d34-0410-b5e6-96231b3b80d8
* round zero-byte .zerofill directives up to 1 byte. ThisChris Lattner2010-04-27
| | | | | | | | should fix some "g++.dg-struct-layout-1" failures, rdar://7886017 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102421 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert a small part of 102372; this fixes at least oneDale Johannesen2010-04-27
| | | | | | | | | | of the dbg testsuite regressions. I don't think this is really the right fix; this change exposed an existing problem upstream somewhere. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102410 91177308-0d34-0410-b5e6-96231b3b80d8
* add a comment in verbose-asm mode indicating why a noop is being generated.Chris Lattner2010-04-26
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102401 91177308-0d34-0410-b5e6-96231b3b80d8
* on darwin empty functions need to codegen into something of non-zero length,Chris Lattner2010-04-26
| | | | | | | | | | | | | otherwise labels get incorrectly merged. We handled this by emitting a ".byte 0", but this isn't correct on thumb/arm targets where the text segment needs to be a multiple of 2/4 bytes. Handle this by emitting a noop. This is more gross than it should be because arm/ppc are not fully mc'ized yet. This fixes rdar://7908505 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102400 91177308-0d34-0410-b5e6-96231b3b80d8
* Avoid adding a null MD node operand, which crashes with "-debug" when tryingBob Wilson2010-04-26
| | | | | | | to print the operand. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102395 91177308-0d34-0410-b5e6-96231b3b80d8
* Use DW_AT_entry_pc instead of DW_AT_low_pc/DW_AT_high_pc pair. This ↵Devang Patel2010-04-26
| | | | | | simplifies debug range entries. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102394 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove crufty comments.Dale Johannesen2010-04-26
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102380 91177308-0d34-0410-b5e6-96231b3b80d8
* Add DBG_VALUE handling for byval parameters; thisDale Johannesen2010-04-26
| | | | | | | | | produces a comment on targets that support it, but the Dwarf writer is not hooked up yet. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102372 91177308-0d34-0410-b5e6-96231b3b80d8
* Insert dbg_value instructions for function entry block liveins (i.e. ↵Evan Cheng2010-04-26
| | | | | | function arguments). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102368 91177308-0d34-0410-b5e6-96231b3b80d8
* fix PR6921 a different way. Intead of increasing theChris Lattner2010-04-26
| | | | | | | | | alignment of globals with a specified alignment, we fix common variables to obey their alignment. Add a comment explaining why this behavior is important. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102365 91177308-0d34-0410-b5e6-96231b3b80d8
* Re-enable 102323 with fix: do not update dbg_value's with incorrect frame ↵Evan Cheng2010-04-26
| | | | | | indices when the live interval are being re-materialized. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102361 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert r102300/102301, which serious broke objc apps.Chris Lattner2010-04-26
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102359 91177308-0d34-0410-b5e6-96231b3b80d8
* Update MachineSSAUpdater with the same changes I made for the IR-levelBob Wilson2010-04-26
| | | | | | | | SSAUpdater. I'm going to try to refactor this to share most of the code between them. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102353 91177308-0d34-0410-b5e6-96231b3b80d8
* Temporary disable spiller modifying dbg_value. It's breaking build.Evan Cheng2010-04-26
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102327 91177308-0d34-0410-b5e6-96231b3b80d8
* - Move TargetLowering::EmitTargetCodeForFrameDebugValue to TargetInstrInfo ↵Evan Cheng2010-04-26
| | | | | | | | | and rename it to emitFrameIndexDebugValue. - Teach spiller to modify DBG_VALUE instructions to reference spill slots. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102323 91177308-0d34-0410-b5e6-96231b3b80d8
* Stop abusing EmitInstrWithCustomInserter for target-dependentDale Johannesen2010-04-25
| | | | | | | | | | form of DEBUG_VALUE, as it doesn't have reasonable default behavior for unsupported targets. Add a new hook instead. No functional change. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102320 91177308-0d34-0410-b5e6-96231b3b80d8
* Add comment re byval args. Doesn't actually work this way yet.Dale Johannesen2010-04-25
| | | | | | | xs git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102316 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix PR6921: globals were not getting correctly rounded up to theirChris Lattner2010-04-25
| | | | | | | | preferred alignment unless they were common or some other special case. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102300 91177308-0d34-0410-b5e6-96231b3b80d8
* When a load operand is promoted to an extload, replace other uses with uses ↵Evan Cheng2010-04-24
| | | | | | of extload result truncated. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102236 91177308-0d34-0410-b5e6-96231b3b80d8
* Apply a fix for a vector setcc dagcombine from Jan Sjodin. NoDan Gohman2010-04-24
| | | | | | | testcase yet, as the testcase now fails downstream. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102228 91177308-0d34-0410-b5e6-96231b3b80d8
* Code refactoring.Evan Cheng2010-04-23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102202 91177308-0d34-0410-b5e6-96231b3b80d8
* Move FastISel's HandlePHINodesInSuccessorBlocks call down into FastISelDan Gohman2010-04-23
| | | | | | | itself too. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102176 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert 102135, 102129, 102127, 102106, 102104, 102102, 102012, 102004,Dan Gohman2010-04-23
| | | | | | | | because 102004 causes codegen to emit invalid assembly on at least x86_64-unknown-gnu-linux. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102155 91177308-0d34-0410-b5e6-96231b3b80d8
* Add comment.Devang Patel2010-04-22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102129 91177308-0d34-0410-b5e6-96231b3b80d8
* Sink SelectionDAGBuilder's HandlePHINodesInSuccessorBlocks downDan Gohman2010-04-22
| | | | | | | into SelectionDAGBuilder itself. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102128 91177308-0d34-0410-b5e6-96231b3b80d8
* Adjust debug range offsets for isWeakForLinker() functions.Devang Patel2010-04-22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102127 91177308-0d34-0410-b5e6-96231b3b80d8
* Move HandlePHINodesInSuccessorBlocks functions out of SelectionDAGISelDan Gohman2010-04-22
| | | | | | | and into SelectionDAGBuilder and FastISel. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102123 91177308-0d34-0410-b5e6-96231b3b80d8
* - It's not safe to promote rotates (at least not trivially).Evan Cheng2010-04-22
| | | | | | | - Some code refactoring. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102111 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a comment.Dan Gohman2010-04-22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102110 91177308-0d34-0410-b5e6-96231b3b80d8
* Move PHINodesToUpdate out of SelectionDAGBuilder and intoDan Gohman2010-04-22
| | | | | | | | | | FunctionLoweringInfo, as it isn't SelectionDAG-specific. This isn't completely natural, as PHI node state is not per-function but rather per-basic-block, however there's currently no other convenient per-basic-block state to group it with. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102109 91177308-0d34-0410-b5e6-96231b3b80d8
* Rename InsnAfterLabelMap and InsnBeforeLabelMap.Devang Patel2010-04-22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102106 91177308-0d34-0410-b5e6-96231b3b80d8
* Keep track of MCSymbol used to mark beginning of a function.Devang Patel2010-04-22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102104 91177308-0d34-0410-b5e6-96231b3b80d8
* At this point Start and End are not null.Devang Patel2010-04-22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102102 91177308-0d34-0410-b5e6-96231b3b80d8
* Run LiveVariables instead of computing liveness locally in -regalloc=fast.Jakob Stoklund Olesen2010-04-21
| | | | | | | | | | | This actually makes everything slower, but the plan is to have isel add <kill> flags the way it is already adding <dead> flags. Then LiveVariables can be removed again. When ignoring the time spent in LiveVariables, -regalloc=fast is now twice as fast as -regalloc=local. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102034 91177308-0d34-0410-b5e6-96231b3b80d8