Displaying 2 results from an estimated 2 matches for "indexreg16".
Did you mean:
indexreg
2013 Dec 12
3
[LLVMdev] [RFC PATCH 1/2] x86: Fix ModR/M byte output in 16-bit addressing mode
..."16-Bit Addressing Forms with the ModR/M byte"
+ static const int R16Table[] = { 0, 0, 0, 7, 0, 6, 4, 5 };
+ unsigned RMfield = R16Table[BaseRegNo];
+
+ assert(RMfield && "invalid 16-bit base register");
+
+ if (IndexReg.getReg()) {
+ unsigned IndexReg16 = R16Table[GetX86RegNum(IndexReg)];
+
+ // Must have one of SI,DI (4,5), and one of BP/BX (6,7)
+ assert(((IndexReg16 ^ RMfield) & 2) &&
+ "invalid 16-bit base/index register combination");
+ assert(Scale.getImm() == 1 &&
+...
2013 Dec 16
0
[LLVMdev] [RFC PATCH 1/2] x86: Fix ModR/M byte output in 16-bit addressing mode
...the ModR/M byte"
> + static const int R16Table[] = { 0, 0, 0, 7, 0, 6, 4, 5 };
> + unsigned RMfield = R16Table[BaseRegNo];
> +
> + assert(RMfield && "invalid 16-bit base register");
> +
> + if (IndexReg.getReg()) {
> + unsigned IndexReg16 = R16Table[GetX86RegNum(IndexReg)];
> +
> + // Must have one of SI,DI (4,5), and one of BP/BX (6,7)
> + assert(((IndexReg16 ^ RMfield) & 2) &&
> + "invalid 16-bit base/index register combination");
> + assert(Scale.getImm() ==...