[PATCH] D100591: [Clang][AArch64] Disable rounding of return values for AArch64

Andrew Savonichev via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Apr 15 12:05:03 PDT 2021


asavonic created this revision.
asavonic added reviewers: rjmccall, dmgreen, t.p.northover, ostannard, sdesmalen, momchil.velikov, SjoerdMeijer.
Herald added subscribers: mstorsjo, danielkiss, kristof.beyls.
asavonic requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.

If a return value is explicitly rounded to 64 bits, an additional
`zext` instruction is emitted, and in some cases it prevents tail call
optimization.

As discussed in D100225 <https://reviews.llvm.org/D100225>, this rounding is not necessary and can be
disabled.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D100591

Files:
  clang/lib/CodeGen/TargetInfo.cpp
  clang/test/CodeGen/aarch64-varargs.c
  clang/test/CodeGen/arm64-arguments.c
  clang/test/CodeGen/arm64-microsoft-arguments.cpp
  clang/test/CodeGen/attr-noundef.cpp
  clang/test/CodeGenCXX/microsoft-abi-sret-and-byval.cpp
  clang/test/CodeGenCXX/trivial_abi.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D100591.337859.patch
Type: text/x-patch
Size: 8927 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20210415/22385221/attachment.bin>


More information about the cfe-commits mailing list