[PATCH] D65497: [RISCV] Generate extensions for RV64 when lowering LibCall with i32 type

Shiva Chen via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 30 22:45:07 PDT 2019


shiva0217 created this revision.
shiva0217 added reviewers: eli.friedman, asb, lenary.
Herald added subscribers: s.egerton, Jim, benna, psnobl, jocewei, PkmX, rkruppe, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, MaskRay, jrtc27, kito-cheng, niosHD, sabuasal, apazos, simoncook, johnrusso, rbar.
Herald added a project: LLVM.

The patch fixed the issue that RV64 didn't generate extensions when return complex floating value with lp64 ABI.

float _Complex
complex_add(float _Complex a, float _Complex b)
{
 return a + b;
}
RealResult = zero_extend(RealA + RealB)
ImageResult = ImageA + ImageB
Return (RealResult | (ImageResult << 32))

Thanks to Eli's comments from the Bugzilla
https://bugs.llvm.org/show_bug.cgi?id=42820


Repository:
  rL LLVM

https://reviews.llvm.org/D65497

Files:
  lib/Target/RISCV/RISCVISelLowering.cpp
  lib/Target/RISCV/RISCVISelLowering.h
  test/CodeGen/RISCV/calling-conv-lp64.ll
  test/CodeGen/RISCV/rv32i-rv64i-float-double.ll
  test/CodeGen/RISCV/rv64-complex-floating-add.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D65497.212504.patch
Type: text/x-patch
Size: 5209 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190731/554f1ac6/attachment.bin>


More information about the llvm-commits mailing list