[PATCH] D20089: Adding a TargetParser for AArch64

jojo.ma via llvm-commits llvm-commits at lists.llvm.org
Wed May 18 22:48:55 PDT 2016


jojo added inline comments.

================
Comment at: lib/Support/TargetParser.cpp:441
@@ +440,3 @@
+  if (Extensions & AArch64::AEK_PROFILE)
+    Features.push_back("+spe");
+
----------------
bsmith wrote:
> For ARM there is a table that defines these extensions and how they map to backend features, it would be good to do this in a similar manner.
There is a similar one for aarch64.But only in the context of switch-case,they can be map to backend features by table look-up. eg,getArchExtName().
We need to judge the value of "Extensions" by means of bit operations here.It is not possible to use the table.

================
Comment at: lib/Support/TargetParser.cpp:770
@@ +769,3 @@
+      if (A.ID == ARM::AK_ARMV8_2A)
+        Features.push_back("+v8.2a");
+      return A.ID;
----------------
bsmith wrote:
> Why do we need to add these features explicitly, can't we just pass through the correct triple?
Sometimes people do not give a complete and standardized triple, which leads to the obtaining of these features by triple impossible.
It maybe safer to add these features by "-march".


Repository:
  rL LLVM

http://reviews.llvm.org/D20089





More information about the llvm-commits mailing list