[PATCH] D73209: [AIX] Implement caller arguments passed in stack memory

Sean Fertile via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 4 10:58:42 PST 2020


sfertile added inline comments.


================
Comment at: llvm/test/CodeGen/PowerPC/aix-cc-abi.ll:1098
+  %0 = load double, double* @d, align 8
+  %1 = load float, float* @f, align 4
+  call void (i32, i32, i32, i32, i32, i32, ...) @test_stackarg_float2(i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, double %0)
----------------
This is unused in the test.


================
Comment at: llvm/test/CodeGen/PowerPC/aix-cc-abi.ll:1117
+; 32BIT-DAG:   $r8 = LI 6
+; 32BIT-DAG:   STFD renamable $f1, 0, %stack.0 :: (store 8 into %stack.0)
+; 32BIT-DAG:   renamable $r9 = LWZ 0, %stack.0 :: (load 4 from %stack.0, align 8)
----------------
Just to make sure I understand correctly: 

This store is just for moving the double value into the gprs. We don't have to initialize the register image in the parameter save area (even though the call is variadic) because it maps into the gprs available for argument passing. If the gprs were exhausted but we still have available fprs then we have to initialize both the fpr and the register image in the PSA (this case being tested by the following test).


================
Comment at: llvm/test/CodeGen/PowerPC/aix-cc-abi.ll:1265
+; ASM64PWR4-DAG:   li 9, 7
+; ASM64PWR4-NEXT:  bl .test_stackarg_float3
+; ASM64PWR4-NEXT:  nop
----------------
Where do we initialize $r10? I don't think we are checking for the asm that should be generated from 
```
; 64BIT-DAG:   STFD renamable $f1, 0, %stack.0 :: (store 8 into %stack.0)
; 64BIT-DAG:   renamable $x10 = LD 0, %stack.0 :: (load 8 from %stack.0)
```


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

https://reviews.llvm.org/D73209





More information about the llvm-commits mailing list