[PATCH] D32684: [X86] Adding new LLVM TableGen backend that generates the X86 backend memory folding tables.
Craig Topper via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue May 9 09:44:42 PDT 2017
craig.topper added a comment.
Can we try not to define so many of the methods inside the class itself? It makes for a very large class and an extra indentation level. I'm thinking if you do that most of the static methods in the class can just be static methods at file scope.
================
Comment at: utils/TableGen/X86FoldTablesEmitter.cpp:213
+
+ bool isExplicitUnalign(const CodeGenInstruction *Inst) {
+ for (const char *InstStr : ExplicitUnalign) {
----------------
This method should be static now right?
================
Comment at: utils/TableGen/X86FoldTablesEmitter.cpp:235
+ // Return true if one of the instruction's operands is a RST register class
+ bool hasRSTRegClass(const CodeGenInstruction *Inst) {
+ return llvm::any_of(Inst->Operands,
----------------
shouldn't this be static?
================
Comment at: utils/TableGen/X86FoldTablesEmitter.cpp:243
+ // Return true if one of the instruction's operands is a ptr_rc_tailcall
+ bool hasPtrTailcallRegClass(const CodeGenInstruction *Inst) {
+ return llvm::any_of(Inst->Operands,
----------------
Shouldn't this be static?
https://reviews.llvm.org/D32684
More information about the llvm-commits
mailing list