[PATCH] D57143: [builtins] Rounding mode support for addxf3/subxf3

Yi Kong via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 24 00:41:18 PST 2019


kongyi created this revision.
Herald added subscribers: Sanitizers, llvm-commits, kristof.beyls, javed.absar, mgorny.

Implement rounding mode support for addxf3/subxf3.

On architectures that implemented the support, this will access the corresponding floating point environment register to apply the correct rounding. For other architectures, it will keep the current behaviour and use IEEE-754 default rounding mode (to nearest, ties to even).

ARM32/AArch64 support implemented in this change. i386 and AMD64 will be added in a follow up change.


Repository:
  rCRT Compiler Runtime

https://reviews.llvm.org/D57143

Files:
  compiler-rt/lib/builtins/CMakeLists.txt
  compiler-rt/lib/builtins/aarch64/fp_mode.c
  compiler-rt/lib/builtins/arm/fp_mode.c
  compiler-rt/lib/builtins/fp_add_impl.inc
  compiler-rt/lib/builtins/fp_mode.c
  compiler-rt/lib/builtins/fp_mode.h
  compiler-rt/test/builtins/Unit/addtf3_test.c
  compiler-rt/test/builtins/Unit/subtf3_test.c

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D57143.183261.patch
Type: text/x-patch
Size: 9031 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190124/410bf109/attachment.bin>


More information about the llvm-commits mailing list