[Lldb-commits] [PATCH] D17022: [LLDB][MIPS] Provide CPU string to compiler for appropriate code generation for MIPS

Zachary Turner via lldb-commits lldb-commits at lists.llvm.org
Tue Feb 9 22:39:52 PST 2016


zturner added a subscriber: zturner.
zturner requested changes to this revision.
zturner added a reviewer: zturner.
This revision now requires changes to proceed.

================
Comment at: source/Plugins/ExpressionParser/Clang/ClangExpressionParser.cpp:206-210
@@ -199,1 +205,7 @@
 
+    if (target_machine == llvm::Triple::mips ||
+        target_machine == llvm::Triple::mipsel ||
+        target_machine == llvm::Triple::mips64 ||
+        target_machine == llvm::Triple::mips64el)
+    {
+        std::string cpu;
----------------
I don't like this big switch statement.  This logic should be somewhere else, for example on the `ArchSpec` class.  And it should handle not just mips, but everything.


Repository:
  rL LLVM

http://reviews.llvm.org/D17022





More information about the lldb-commits mailing list