mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-15 05:24:01 +00:00
Added invariant field to the DAG.getLoad method and changed all calls.
When this field is true it means that the load is from constant (runt-time or compile-time) and so can be hoisted from loops or moved around other memory accesses git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@144100 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -1253,6 +1253,7 @@ bool MachineInstr::isInvariantLoad(AliasAnalysis *AA) const {
|
||||
E = memoperands_end(); I != E; ++I) {
|
||||
if ((*I)->isVolatile()) return false;
|
||||
if ((*I)->isStore()) return false;
|
||||
if ((*I)->isInvariant()) return true;
|
||||
|
||||
if (const Value *V = (*I)->getValue()) {
|
||||
// A load from a constant PseudoSourceValue is invariant.
|
||||
|
Reference in New Issue
Block a user