diff --git a/src/base/SMPInstr.cpp b/src/base/SMPInstr.cpp index ab2647e4b0c4a2fbe854fcdbd82112cd5b9cdb68..5525826a0fa7879fac216b510672381f1ba73049 100644 --- a/src/base/SMPInstr.cpp +++ b/src/base/SMPInstr.cpp @@ -359,6 +359,9 @@ void SMPInstr::PrintSPARKAdaOperand(const STARSOpndTypePtr &Opnd, FILE *OutFile, else { // no SIB info uint16_t BaseReg = Opnd->GetReg(); STARSOpndTypePtr BaseOp = this->STARSInstPtr->MakeRegOpnd(BaseReg); + if (this->MDIsAddressing64bit()) { + BaseOp->SetByteWidth(8); + } if (Opnd->HasSegReg() && (!((STARS_x86_R_ss == Opnd->GetSegReg()) && MDIsStackAccessOpnd(Opnd, UseFP)))) { // We have a segment selector that is not just a redundant SS: selector for an RSP-relative access. STARSOpndTypePtr SegRegOp = this->STARSInstPtr->MakeRegOpnd(Opnd->GetSegReg()); @@ -393,6 +396,9 @@ void SMPInstr::PrintSPARKAdaOperand(const STARSOpndTypePtr &Opnd, FILE *OutFile, else { uint16_t BaseReg = Opnd->GetReg(); STARSOpndTypePtr BaseOp = this->STARSInstPtr->MakeRegOpnd(BaseReg); + if (this->MDIsAddressing64bit()) { + BaseOp->SetByteWidth(8); + } if (Opnd->HasSegReg() && (!((STARS_x86_R_ss == Opnd->GetSegReg()) && MDIsStackAccessOpnd(Opnd, UseFP)))) { // We have a segment selector that is not just a redundant SS: selector for an RSP-relative access. STARSOpndTypePtr SegRegOp = this->STARSInstPtr->MakeRegOpnd(Opnd->GetSegReg());