[PATCH] D73220: [llvm-exegesis] Don't use unsupported aliasing instructions
Miloš Stojanović via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 22 12:24:00 PST 2020
mstojanovic created this revision.
mstojanovic added reviewers: gchatelet, courbet, petarj.
Herald added a subscriber: tschuett.
Herald added a project: LLVM.
Since some instruction types aren't allowed as the main instruction also don't allow them for aliasing instructions.
https://reviews.llvm.org/D73220
Files:
llvm/tools/llvm-exegesis/lib/SerialSnippetGenerator.cpp
Index: llvm/tools/llvm-exegesis/lib/SerialSnippetGenerator.cpp
===================================================================
--- llvm/tools/llvm-exegesis/lib/SerialSnippetGenerator.cpp
+++ llvm/tools/llvm-exegesis/lib/SerialSnippetGenerator.cpp
@@ -48,6 +48,13 @@
if (OtherOpcode == Instr->Description.getOpcode())
continue;
const Instruction &OtherInstr = State.getIC().getInstr(OtherOpcode);
+ const MCInstrDesc &OtherInstrDesc = OtherInstr.Description;
+ // Ignore instructions that we cannot run.
+ if (OtherInstrDesc.isPseudo() ||
+ OtherInstrDesc.isBranch() || OtherInstrDesc.isIndirectBranch() ||
+ OtherInstrDesc.isCall() || OtherInstrDesc.isReturn()) {
+ continue;
+ }
if (OtherInstr.hasMemoryOperands())
continue;
if (Instr->hasAliasingRegistersThrough(OtherInstr, ForbiddenRegisters))
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D73220.239668.patch
Type: text/x-patch
Size: 871 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200122/917baa66/attachment.bin>
More information about the llvm-commits
mailing list