[PATCH] D48316: [llvm-exegesis] Use a Prototype to defer picking a value for free vars.

Clement Courbet via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jun 19 06:29:40 PDT 2018


courbet added inline comments.


================
Comment at: tools/llvm-exegesis/lib/MCInstrDescView.cpp:131
+llvm::MCInst InstructionInstance::randomizeImmediateVariablesAndBuild() {
+  return {};
+}
----------------
?


================
Comment at: tools/llvm-exegesis/lib/MCInstrDescView.h:91
+  // Moving is OK.
+  InstructionInstance(InstructionInstance &&) = default;
+  InstructionInstance &operator=(InstructionInstance &&) = default;
----------------
[nit] noexcept


================
Comment at: tools/llvm-exegesis/lib/MCInstrDescView.h:91
+  // Moving is OK.
+  InstructionInstance(InstructionInstance &&) = default;
+  InstructionInstance &operator=(InstructionInstance &&) = default;
----------------
courbet wrote:
> [nit] noexcept
class InstructionInstance {
  InstructionInstance(InstructionInstance&&) noexcept;
};

inline InstructionInstance::InstructionInstance(InstructionInstance&&) noexcept = default;

To force the compiler to actually generate the code.


================
Comment at: tools/llvm-exegesis/lib/MCInstrDescView.h:103
 
-  const Instruction &Instr;
+  llvm::MCInst randomizeImmediateVariablesAndBuild();
+
----------------
Did you want to add this is a separate patch ? It's not called and not implemented.


================
Comment at: tools/llvm-exegesis/lib/MCInstrDescView.h:121
+  // Moving is OK.
+  SnippetPrototype(SnippetPrototype &&) = default;
+  SnippetPrototype &operator=(SnippetPrototype &&) = default;
----------------
ditto


Repository:
  rL LLVM

https://reviews.llvm.org/D48316





More information about the llvm-commits mailing list