History log of /llvm-project-15.0.7/llvm/lib/CodeGen/MachineBasicBlock.cpp (Results 251 – 275 of 410)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: llvmorg-3.1.0, llvmorg-3.1.0-rc3, llvmorg-3.1.0-rc2
# 2d14d8ac 24-Apr-2012 Evan Cheng <[email protected]>

MachineBasicBlock::SplitCriticalEdge() should follow LLVM IR variant and refuse to break edge to EH landing pad. rdar://11300144

llvm-svn: 155470


Revision tags: llvmorg-3.1.0-rc1
# 1f5580b6 16-Apr-2012 Chandler Carruth <[email protected]>

Fix updateTerminator to be resiliant to degenerate terminators where
both fallthrough and a conditional branch target the same successor.
Gracefully delete the conditional branch and introduce any un

Fix updateTerminator to be resiliant to degenerate terminators where
both fallthrough and a conditional branch target the same successor.
Gracefully delete the conditional branch and introduce any unconditional
branch needed to reach the actual successor. This fixes memory
corruption in 2009-06-15-RegScavengerAssert.ll and possibly other tests.

Also, while I'm here fix a latent bug I spotted by inspection. I never
applied the same fundamental fix to this fallthrough successor finding
logic that I did to the logic used when there are no conditional
branches. As a consequence it would have selected landing pads had they
be aligned in just the right way here. I don't have a test case as
I spotted this by inspection, and the previous time I found this
required have of TableGen's source code to produce it. =/ I hate backend
bugs. ;]

Thanks to Jim Grosbach for helping me reason through this and reviewing
the fix.

llvm-svn: 154867

show more ...


# 8e58c90f 28-Mar-2012 Jakob Stoklund Olesen <[email protected]>

Allow removeLiveIn to be called with a register that isn't live-in.

This avoids the silly double search:

if (isLiveIn(Reg))
removeLiveIn(Reg);

llvm-svn: 153592


# 320c7030 07-Mar-2012 Andrew Trick <[email protected]>

Added MachineBasicBlock::getFullName() to standardize/factor codegen diagnostics.

llvm-svn: 152176


# baa41d41 10-Feb-2012 Benjamin Kramer <[email protected]>

Cache iterators. Some of these are expensive to create.

llvm-svn: 150214


# edeea175 09-Feb-2012 Lang Hames <[email protected]>

Preserve physreg kills in MachineBasicBlock::SplitCriticalEdge.

Failure to preserve kills was causing LiveIntervals to miss some EFLAGS live
ranges. Unfortunately I've been unable to reduce a good t

Preserve physreg kills in MachineBasicBlock::SplitCriticalEdge.

Failure to preserve kills was causing LiveIntervals to miss some EFLAGS live
ranges. Unfortunately I've been unable to reduce a good test case yet.

llvm-svn: 150152

show more ...


# 9b61cf31 26-Jan-2012 Chad Rosier <[email protected]>

Update comment for r149070.

llvm-svn: 149075


# 1a1531d6 26-Jan-2012 Chad Rosier <[email protected]>

Replace the use of isPredicable() with isPredicated() in
MachineBasicBlock::canFallThrough(). We're interested in the state of the
instruction (i.e., is this a barrier or not?), not if the instructi

Replace the use of isPredicable() with isPredicated() in
MachineBasicBlock::canFallThrough(). We're interested in the state of the
instruction (i.e., is this a barrier or not?), not if the instruction is
predicable or not.
rdar://10501092

llvm-svn: 149070

show more ...


# 96f8c551 20-Dec-2011 Jakub Staszak <[email protected]>

Add some constantness to BranchProbabilityInfo and BlockFrequnencyInfo.

llvm-svn: 146986


# 7fae11b2 14-Dec-2011 Evan Cheng <[email protected]>

- Add MachineInstrBundle.h and MachineInstrBundle.cpp. This includes a function
to finalize MI bundles (i.e. add BUNDLE instruction and computing register def
and use lists of the BUNDLE instruct

- Add MachineInstrBundle.h and MachineInstrBundle.cpp. This includes a function
to finalize MI bundles (i.e. add BUNDLE instruction and computing register def
and use lists of the BUNDLE instruction) and a pass to unpack bundles.
- Teach more of MachineBasic and MachineInstr methods to be bundle aware.
- Switch Thumb2 IT block to MI bundles and delete the hazard recognizer hack to
prevent IT blocks from being broken apart.

llvm-svn: 146542

show more ...


# 7f8e563a 07-Dec-2011 Evan Cheng <[email protected]>

Add bundle aware API for querying instruction properties and switch the code
generator to it. For non-bundle instructions, these behave exactly the same
as the MC layer API.

For properties like mayL

Add bundle aware API for querying instruction properties and switch the code
generator to it. For non-bundle instructions, these behave exactly the same
as the MC layer API.

For properties like mayLoad / mayStore, look into the bundle and if any of the
bundled instructions has the property it would return true.
For properties like isPredicable, only return true if *all* of the bundled
instructions have the property.
For properties like canFoldAsLoad, isCompare, conservatively return false for
bundles.

llvm-svn: 146026

show more ...


# 2a81dd4a 06-Dec-2011 Evan Cheng <[email protected]>

First chunk of MachineInstr bundle support.
1. Added opcode BUNDLE
2. Taught MachineInstr class to deal with bundled MIs
3. Changed MachineBasicBlock iterator to skip over bundled MIs; added an itera

First chunk of MachineInstr bundle support.
1. Added opcode BUNDLE
2. Taught MachineInstr class to deal with bundled MIs
3. Changed MachineBasicBlock iterator to skip over bundled MIs; added an iterator to walk all the MIs
4. Taught MachineBasicBlock methods about bundled MIs

llvm-svn: 145975

show more ...


# 2a2b37ea 06-Dec-2011 Jakob Stoklund Olesen <[email protected]>

Pretty-print basic block alignment.

llvm-svn: 145965


# 8c68f1f3 23-Nov-2011 Chandler Carruth <[email protected]>

Handle the case of a no-return invoke correctly. It actually still has
successors, they just are all landing pad successors. We handle this the
same way as no successors. Comments attached for the ne

Handle the case of a no-return invoke correctly. It actually still has
successors, they just are all landing pad successors. We handle this the
same way as no successors. Comments attached for the next person to wade
through here and another lovely test case courtesy of Benjamin Kramer's
bugpoint reduction.

llvm-svn: 145098

show more ...


# ee54feb6 22-Nov-2011 Chandler Carruth <[email protected]>

Fix a devilish miscompile exposed by block placement. The
updateTerminator code didn't correctly handle EH terminators in one very
specific case. AnalyzeBranch would find no terminator instruction, a

Fix a devilish miscompile exposed by block placement. The
updateTerminator code didn't correctly handle EH terminators in one very
specific case. AnalyzeBranch would find no terminator instruction, and
so the fallback in updateTerminator is to assume fallthrough. This is
correct, but the destination of the fallthrough was assumed to be the
first successor.

This is *almost always* true, but in certain cases the loop
transformations will cause the landing pad to be the first successor!
Instead of this brittle logic, actually look through the successors for
a non-landing-pad accessor, and to assert if more than one is found.

This will hopefully fix some (if not all) of the self host miscompiles
with block placement. Thanks to Benjamin Kramer for reporting, Nick
Lewycky for an initial stab at a reduction, and Duncan for endless
advice on EH (which I know nothing about) as well as reviewing the
actual fix.

llvm-svn: 145062

show more ...


Revision tags: llvmorg-3.0.0, llvmorg-3.0.0-rc4, llvmorg-3.0.0-rc3, llvmorg-3.0.0-rc2, llvmorg-3.0.0-rc1
# 06b6ccfe 14-Oct-2011 Jakob Stoklund Olesen <[email protected]>

Update live-in lists when splitting critical edges.

Fixes PR10814. Patch by Jan Sjödin!

llvm-svn: 141960


# 6cc775f9 28-Jun-2011 Evan Cheng <[email protected]>

- Rename TargetInstrDesc, TargetOperandInfo to MCInstrDesc and MCOperandInfo and
sink them into MC layer.
- Added MCInstrInfo, which captures the tablegen generated static data. Chang
TargetInstrInfo

- Rename TargetInstrDesc, TargetOperandInfo to MCInstrDesc and MCOperandInfo and
sink them into MC layer.
- Added MCInstrInfo, which captures the tablegen generated static data. Chang
TargetInstrInfo so it's based off MCInstrInfo.

llvm-svn: 134021

show more ...


# 5f45dc76 17-Jun-2011 Jakub Staszak <[email protected]>

getSuccWeight returns now default 0 if Weights vector is empty.

llvm-svn: 133271


# 2ce8399a 17-Jun-2011 Jakub Staszak <[email protected]>

Allow empty Weights vector.

llvm-svn: 133265


# 12a43bdd 16-Jun-2011 Jakub Staszak <[email protected]>

Introduce MachineBranchProbabilityInfo class, which has similar API to
BranchProbabilityInfo (expect setEdgeWeight which is not available here).
Branch Weights are kept in MachineBasicBlocks. To turn

Introduce MachineBranchProbabilityInfo class, which has similar API to
BranchProbabilityInfo (expect setEdgeWeight which is not available here).
Branch Weights are kept in MachineBasicBlocks. To turn off this analysis
set -use-mbpi=false.

llvm-svn: 133184

show more ...


# feadd435 16-Jun-2011 Jakub Staszak <[email protected]>

Test commit.

llvm-svn: 133174


# dd6fcc4e 29-May-2011 Jakob Stoklund Olesen <[email protected]>

Fix PR10046 by updating LiveVariables kill info when splitting live ranges.

This only affects targets like Mips where branch instructions may kill virtual
registers. Most other targets branch on fla

Fix PR10046 by updating LiveVariables kill info when splitting live ranges.

This only affects targets like Mips where branch instructions may kill virtual
registers. Most other targets branch on flag values, so virtual registers are
not involved.

The problem is that MachineBasicBlock::updateTerminator deletes branches and
inserts new ones while LiveVariables keeps a list of pointers to instructions
that kill virtual registers. That list wasn't properly updated in
MBB::SplitCriticalEdge.

llvm-svn: 132298

show more ...


# ec138b4b 18-Apr-2011 Eli Friedman <[email protected]>

Simplify declarations slightly by using typedefs.

llvm-svn: 129720


Revision tags: llvmorg-2.9.0, llvmorg-2.9.0-rc3, llvmorg-2.9.0-rc2, llvmorg-2.9.0-rc1
# 096bd883 04-Feb-2011 Jakob Stoklund Olesen <[email protected]>

Add LiveIntervals::getLastSplitPoint().

A live range cannot be split everywhere in a basic block. A split must go before
the first terminator, and if the variable is live into a landing pad, the spl

Add LiveIntervals::getLastSplitPoint().

A live range cannot be split everywhere in a basic block. A split must go before
the first terminator, and if the variable is live into a landing pad, the split
must happen before the call that can throw.

llvm-svn: 124894

show more ...


# ab3d6ecb 14-Jan-2011 Jakob Stoklund Olesen <[email protected]>

Try for the third time to teach getFirstTerminator() about debug values.

This time let's rephrase to trick gcc-4.3 into not miscompiling.

llvm-svn: 123432


1...<<11121314151617