[all-commits] [llvm/llvm-project] a5a337: [libc] Capture floating point encoding and arrange...

HedGarcia via All-commits all-commits at lists.llvm.org
Tue Jul 13 13:44:17 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: a5a337e55ed2e265358ac0a2ce6db1af2dd69e07
      https://github.com/llvm/llvm-project/commit/a5a337e55ed2e265358ac0a2ce6db1af2dd69e07
  Author: Hedin Garca <hedingarcia at google.com>
  Date:   2021-07-13 (Tue, 13 Jul 2021)

  Changed paths:
    M libc/test/src/math/LdExpTest.h
    M libc/test/src/math/NextAfterTest.h
    M libc/test/src/math/RoundToIntegerTest.h
    M libc/test/src/math/SqrtTest.h
    M libc/utils/FPUtil/BasicOperations.h
    M libc/utils/FPUtil/DivisionAndRemainderOperations.h
    M libc/utils/FPUtil/FPBits.h
    M libc/utils/FPUtil/Hypot.h
    M libc/utils/FPUtil/LongDoubleBitsX86.h
    M libc/utils/FPUtil/ManipulationFunctions.h
    M libc/utils/FPUtil/NearestIntegerOperations.h
    M libc/utils/FPUtil/NextAfterLongDoubleX86.h
    M libc/utils/FPUtil/NormalFloat.h
    M libc/utils/FPUtil/Sqrt.h
    M libc/utils/FPUtil/SqrtLongDoubleX86.h
    M libc/utils/FPUtil/TestHelpers.cpp
    M libc/utils/FPUtil/generic/FMA.h

  Log Message:
  -----------
  [libc] Capture floating point encoding and arrange it sequentially in memory

Redefined FPBits.h and LongDoubleBitsX86 so its implementation works for the Windows
and Linux platform while maintaining a packed memory alignment of the precision floating
point numbers. For its size in memory to be the same as the data type of the float point number.
This change was necessary because the previous attribute((packed)) specification in the struct was not working
for Windows like it was for Linux and consequently static_asserts in the FPBits.h file were failing.

Reviewed By: aeubanks, sivachandra

Differential Revision: https://reviews.llvm.org/D105561




More information about the All-commits mailing list