[PATCH] D155432: [AArch64][SME] Use `fmov` instead of NEON `movi` for FP value.

hassnaaHamdi via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 18 05:50:48 PDT 2023


hassnaa-arm added inline comments.


================
Comment at: llvm/lib/Target/AArch64/AArch64AsmPrinter.cpp:1333
   if (STI->hasZeroCycleZeroingFP() && !STI->hasZeroCycleZeroingFPWorkaround() &&
-      STI->hasNEON()) {
+      STI->isNeonAvailable()) {
     // Convert H/S register to corresponding D register
----------------
conceptually what is the difference between hasNEON and isNeonAvailable() ?
I saw the implementation of isNeonAvailable which is the opposite of hasNEON or the opposite of streaming mode. 
But I don't understand how the implementation of isNeonAvailable() represents its name.


================
Comment at: llvm/lib/Target/AArch64/AArch64AsmPrinter.cpp:1333
   if (STI->hasZeroCycleZeroingFP() && !STI->hasZeroCycleZeroingFPWorkaround() &&
-      STI->hasNEON()) {
+      STI->isNeonAvailable()) {
     // Convert H/S register to corresponding D register
----------------
hassnaa-arm wrote:
> conceptually what is the difference between hasNEON and isNeonAvailable() ?
> I saw the implementation of isNeonAvailable which is the opposite of hasNEON or the opposite of streaming mode. 
> But I don't understand how the implementation of isNeonAvailable() represents its name.
What is the difference between this class 'AArch64AsmPrinter' and tblgen files ?
Another thing, I see that in the tblgen files there are some conditions about generating code compatible with specific features, so what is the difference between handling the compatible generated code in the tblgen files and handling it here ?


================
Comment at: llvm/test/CodeGen/AArch64/sve-streaming-mode-test-register-mov.ll:36
+; CHECK:       // %bb.0:
+; CHECK-NEXT:    mov z0.d, #0 // =0x0
+; CHECK-NEXT:    // kill: def $q0 killed $q0 killed $z0
----------------
while the initialised vector is double, why is this mov instead of fmov ? 


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D155432/new/

https://reviews.llvm.org/D155432



More information about the llvm-commits mailing list