mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-23 14:25:07 +00:00
Feeding isSafeToSpeculativelyExecute its DataLayout pointer
isSafeToSpeculativelyExecute can optionally take a DataLayout pointer. In the past, this was mainly used to make better decisions regarding divisions known not to trap, and so was not all that important for users concerned with "cheap" instructions. However, now it also helps look through bitcasts for dereferencable loads, and will also be important if/when we add a dereferencable pointer attribute. This is some initial work to feed a DataLayout pointer through to callers of isSafeToSpeculativelyExecute, generally where one was already available. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@212720 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -148,7 +148,7 @@ bool FlattenCFG(BasicBlock *BB, AliasAnalysis *AA = nullptr);
|
||||
/// and if a predecessor branches to us and one of our successors, fold the
|
||||
/// setcc into the predecessor and use logical operations to pick the right
|
||||
/// destination.
|
||||
bool FoldBranchToCommonDest(BranchInst *BI);
|
||||
bool FoldBranchToCommonDest(BranchInst *BI, const DataLayout *DL = nullptr);
|
||||
|
||||
/// DemoteRegToStack - This function takes a virtual register computed by an
|
||||
/// Instruction and replaces it with a slot in the stack frame, allocated via
|
||||
|
@@ -17,6 +17,7 @@
|
||||
namespace llvm {
|
||||
class AliasAnalysis;
|
||||
class BasicBlock;
|
||||
class DataLayout;
|
||||
class DominatorTree;
|
||||
class Loop;
|
||||
class LoopInfo;
|
||||
@@ -32,7 +33,8 @@ BasicBlock *InsertPreheaderForLoop(Loop *L, Pass *P);
|
||||
/// will optionally update \c AliasAnalysis and \c ScalarEvolution analyses if
|
||||
/// passed into it.
|
||||
bool simplifyLoop(Loop *L, DominatorTree *DT, LoopInfo *LI, Pass *PP,
|
||||
AliasAnalysis *AA = nullptr, ScalarEvolution *SE = nullptr);
|
||||
AliasAnalysis *AA = nullptr, ScalarEvolution *SE = nullptr,
|
||||
const DataLayout *DL = nullptr);
|
||||
|
||||
/// \brief Put loop into LCSSA form.
|
||||
///
|
||||
|
Reference in New Issue
Block a user