diff options
author | Philip Reames <listmail@philipreames.com> | 2016-08-23 23:33:29 +0000 |
---|---|---|
committer | Philip Reames <listmail@philipreames.com> | 2016-08-23 23:33:29 +0000 |
commit | e83c4b30ca8f189d5dbd4e0be53110c3a1f7129e (patch) | |
tree | 6b9b32f91eec706ff85d80c08393af8483f4c597 /llvm/lib/Target/PowerPC/PPCInstrInfo.cpp | |
parent | bd63d436c148152aedf13818475e66892449662b (diff) | |
download | bcm5719-llvm-e83c4b30ca8f189d5dbd4e0be53110c3a1f7129e.tar.gz bcm5719-llvm-e83c4b30ca8f189d5dbd4e0be53110c3a1f7129e.zip |
[stackmaps] More extraction of common code [NFCI]
General cleanup before starting to work on the part I want to actually change.
llvm-svn: 279586
Diffstat (limited to 'llvm/lib/Target/PowerPC/PPCInstrInfo.cpp')
-rw-r--r-- | llvm/lib/Target/PowerPC/PPCInstrInfo.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp b/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp index fbbbfc4d0af..ece7e086575 100644 --- a/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp +++ b/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp @@ -1816,10 +1816,11 @@ unsigned PPCInstrInfo::getInstSizeInBytes(const MachineInstr &MI) const { const char *AsmStr = MI.getOperand(0).getSymbolName(); return getInlineAsmLength(AsmStr, *MF->getTarget().getMCAsmInfo()); } else if (Opcode == TargetOpcode::STACKMAP) { - return MI.getOperand(1).getImm(); + StackMapOpers Opers(&MI); + return Opers.getNumPatchBytes(); } else if (Opcode == TargetOpcode::PATCHPOINT) { PatchPointOpers Opers(&MI); - return Opers.getMetaOper(PatchPointOpers::NBytesPos).getImm(); + return Opers.getNumPatchBytes(); } else { const MCInstrDesc &Desc = get(Opcode); return Desc.getSize(); |