mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-13 04:30:23 +00:00
use range-based for loops; NFCI
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@241592 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
75a855e853
commit
08c4cbeeae
@ -269,14 +269,11 @@ X86InstrInfo::X86InstrInfo(X86Subtarget &STI)
|
|||||||
{ X86::XOR8rr, X86::XOR8mr, 0 }
|
{ X86::XOR8rr, X86::XOR8mr, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
for (unsigned i = 0, e = array_lengthof(MemoryFoldTable2Addr); i != e; ++i) {
|
for (X86MemoryFoldTableEntry Entry : MemoryFoldTable2Addr) {
|
||||||
unsigned RegOp = MemoryFoldTable2Addr[i].RegOp;
|
|
||||||
unsigned MemOp = MemoryFoldTable2Addr[i].MemOp;
|
|
||||||
unsigned Flags = MemoryFoldTable2Addr[i].Flags;
|
|
||||||
AddTableEntry(RegOp2MemOpTable2Addr, MemOp2RegOpTable,
|
AddTableEntry(RegOp2MemOpTable2Addr, MemOp2RegOpTable,
|
||||||
RegOp, MemOp,
|
Entry.RegOp, Entry.MemOp,
|
||||||
// Index 0, folded load and store, no alignment requirement.
|
// Index 0, folded load and store, no alignment requirement.
|
||||||
Flags | TB_INDEX_0 | TB_FOLDED_LOAD | TB_FOLDED_STORE);
|
Entry.Flags | TB_INDEX_0 | TB_FOLDED_LOAD | TB_FOLDED_STORE);
|
||||||
}
|
}
|
||||||
|
|
||||||
static const X86MemoryFoldTableEntry MemoryFoldTable0[] = {
|
static const X86MemoryFoldTableEntry MemoryFoldTable0[] = {
|
||||||
@ -424,12 +421,9 @@ X86InstrInfo::X86InstrInfo(X86Subtarget &STI)
|
|||||||
{ X86::VCVTPS2PHYrr, X86::VCVTPS2PHYmr, TB_FOLDED_STORE }
|
{ X86::VCVTPS2PHYrr, X86::VCVTPS2PHYmr, TB_FOLDED_STORE }
|
||||||
};
|
};
|
||||||
|
|
||||||
for (unsigned i = 0, e = array_lengthof(MemoryFoldTable0); i != e; ++i) {
|
for (X86MemoryFoldTableEntry Entry : MemoryFoldTable0) {
|
||||||
unsigned RegOp = MemoryFoldTable0[i].RegOp;
|
|
||||||
unsigned MemOp = MemoryFoldTable0[i].MemOp;
|
|
||||||
unsigned Flags = MemoryFoldTable0[i].Flags;
|
|
||||||
AddTableEntry(RegOp2MemOpTable0, MemOp2RegOpTable,
|
AddTableEntry(RegOp2MemOpTable0, MemOp2RegOpTable,
|
||||||
RegOp, MemOp, TB_INDEX_0 | Flags);
|
Entry.RegOp, Entry.MemOp, TB_INDEX_0 | Entry.Flags);
|
||||||
}
|
}
|
||||||
|
|
||||||
static const X86MemoryFoldTableEntry MemoryFoldTable1[] = {
|
static const X86MemoryFoldTableEntry MemoryFoldTable1[] = {
|
||||||
@ -862,14 +856,11 @@ X86InstrInfo::X86InstrInfo(X86Subtarget &STI)
|
|||||||
{ X86::VAESKEYGENASSIST128rr, X86::VAESKEYGENASSIST128rm, 0 }
|
{ X86::VAESKEYGENASSIST128rr, X86::VAESKEYGENASSIST128rm, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
for (unsigned i = 0, e = array_lengthof(MemoryFoldTable1); i != e; ++i) {
|
for (X86MemoryFoldTableEntry Entry : MemoryFoldTable1) {
|
||||||
unsigned RegOp = MemoryFoldTable1[i].RegOp;
|
|
||||||
unsigned MemOp = MemoryFoldTable1[i].MemOp;
|
|
||||||
unsigned Flags = MemoryFoldTable1[i].Flags;
|
|
||||||
AddTableEntry(RegOp2MemOpTable1, MemOp2RegOpTable,
|
AddTableEntry(RegOp2MemOpTable1, MemOp2RegOpTable,
|
||||||
RegOp, MemOp,
|
Entry.RegOp, Entry.MemOp,
|
||||||
// Index 1, folded load
|
// Index 1, folded load
|
||||||
Flags | TB_INDEX_1 | TB_FOLDED_LOAD);
|
Entry.Flags | TB_INDEX_1 | TB_FOLDED_LOAD);
|
||||||
}
|
}
|
||||||
|
|
||||||
static const X86MemoryFoldTableEntry MemoryFoldTable2[] = {
|
static const X86MemoryFoldTableEntry MemoryFoldTable2[] = {
|
||||||
@ -1733,14 +1724,11 @@ X86InstrInfo::X86InstrInfo(X86Subtarget &STI)
|
|||||||
{ X86::SHA256RNDS2rr, X86::SHA256RNDS2rm, TB_ALIGN_16 }
|
{ X86::SHA256RNDS2rr, X86::SHA256RNDS2rm, TB_ALIGN_16 }
|
||||||
};
|
};
|
||||||
|
|
||||||
for (unsigned i = 0, e = array_lengthof(MemoryFoldTable2); i != e; ++i) {
|
for (X86MemoryFoldTableEntry Entry : MemoryFoldTable2) {
|
||||||
unsigned RegOp = MemoryFoldTable2[i].RegOp;
|
|
||||||
unsigned MemOp = MemoryFoldTable2[i].MemOp;
|
|
||||||
unsigned Flags = MemoryFoldTable2[i].Flags;
|
|
||||||
AddTableEntry(RegOp2MemOpTable2, MemOp2RegOpTable,
|
AddTableEntry(RegOp2MemOpTable2, MemOp2RegOpTable,
|
||||||
RegOp, MemOp,
|
Entry.RegOp, Entry.MemOp,
|
||||||
// Index 2, folded load
|
// Index 2, folded load
|
||||||
Flags | TB_INDEX_2 | TB_FOLDED_LOAD);
|
Entry.Flags | TB_INDEX_2 | TB_FOLDED_LOAD);
|
||||||
}
|
}
|
||||||
|
|
||||||
static const X86MemoryFoldTableEntry MemoryFoldTable3[] = {
|
static const X86MemoryFoldTableEntry MemoryFoldTable3[] = {
|
||||||
@ -1949,14 +1937,11 @@ X86InstrInfo::X86InstrInfo(X86Subtarget &STI)
|
|||||||
{ X86::VMAXPDZ128rrkz, X86::VMAXPDZ128rmkz, 0 }
|
{ X86::VMAXPDZ128rrkz, X86::VMAXPDZ128rmkz, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
for (unsigned i = 0, e = array_lengthof(MemoryFoldTable3); i != e; ++i) {
|
for (X86MemoryFoldTableEntry Entry : MemoryFoldTable3) {
|
||||||
unsigned RegOp = MemoryFoldTable3[i].RegOp;
|
|
||||||
unsigned MemOp = MemoryFoldTable3[i].MemOp;
|
|
||||||
unsigned Flags = MemoryFoldTable3[i].Flags;
|
|
||||||
AddTableEntry(RegOp2MemOpTable3, MemOp2RegOpTable,
|
AddTableEntry(RegOp2MemOpTable3, MemOp2RegOpTable,
|
||||||
RegOp, MemOp,
|
Entry.RegOp, Entry.MemOp,
|
||||||
// Index 3, folded load
|
// Index 3, folded load
|
||||||
Flags | TB_INDEX_3 | TB_FOLDED_LOAD);
|
Entry.Flags | TB_INDEX_3 | TB_FOLDED_LOAD);
|
||||||
}
|
}
|
||||||
|
|
||||||
static const X86MemoryFoldTableEntry MemoryFoldTable4[] = {
|
static const X86MemoryFoldTableEntry MemoryFoldTable4[] = {
|
||||||
@ -2001,14 +1986,11 @@ X86InstrInfo::X86InstrInfo(X86Subtarget &STI)
|
|||||||
{ X86::VMAXPDZ128rrk, X86::VMAXPDZ128rmk, 0 }
|
{ X86::VMAXPDZ128rrk, X86::VMAXPDZ128rmk, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
for (unsigned i = 0, e = array_lengthof(MemoryFoldTable4); i != e; ++i) {
|
for (X86MemoryFoldTableEntry Entry : MemoryFoldTable4) {
|
||||||
unsigned RegOp = MemoryFoldTable4[i].RegOp;
|
|
||||||
unsigned MemOp = MemoryFoldTable4[i].MemOp;
|
|
||||||
unsigned Flags = MemoryFoldTable4[i].Flags;
|
|
||||||
AddTableEntry(RegOp2MemOpTable4, MemOp2RegOpTable,
|
AddTableEntry(RegOp2MemOpTable4, MemOp2RegOpTable,
|
||||||
RegOp, MemOp,
|
Entry.RegOp, Entry.MemOp,
|
||||||
// Index 4, folded load
|
// Index 4, folded load
|
||||||
Flags | TB_INDEX_4 | TB_FOLDED_LOAD);
|
Entry.Flags | TB_INDEX_4 | TB_FOLDED_LOAD);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user