[libc] Add float type and flag for nearest_integer to enable SSE4.2.Add float type and flag for nearest integer to automatically test withand without SSE4.2 flag.Reviewed By: sivachandraDiffer
[libc] Add float type and flag for nearest_integer to enable SSE4.2.Add float type and flag for nearest integer to automatically test withand without SSE4.2 flag.Reviewed By: sivachandraDifferential Revision: https://reviews.llvm.org/D129916
show more ...
[libc] Add nearest integer instructions to fputil.Add round to nearest integer instructions to fputil. This will beused in sinf implementation https://reviews.llvm.org/D123154Reviewed By: micha
[libc] Add nearest integer instructions to fputil.Add round to nearest integer instructions to fputil. This will beused in sinf implementation https://reviews.llvm.org/D123154Reviewed By: michaelrjDifferential Revision: https://reviews.llvm.org/D129776
[libc] Add support for x86-64 targets that do not have FMA instructions.Make FMA flag checks more accurate for x86-64 targets, and refactorpolyeval to use multiply and add instead when FMA instruc
[libc] Add support for x86-64 targets that do not have FMA instructions.Make FMA flag checks more accurate for x86-64 targets, and refactorpolyeval to use multiply and add instead when FMA instructions are notavailable.Reviewed By: michaelrj, sivachandraDifferential Revision: https://reviews.llvm.org/D123335
[libc] Initial support for darwin-aarch64.Add initial support for darwin-aarch64 (macOS M1).Some differences compared to linux-aarch64:- `math.h` defined `math_errhandling` by the compiler built
[libc] Initial support for darwin-aarch64.Add initial support for darwin-aarch64 (macOS M1).Some differences compared to linux-aarch64:- `math.h` defined `math_errhandling` by the compiler builtin `__math_errhandling()` but Apple Clang 13.0.0 on M1 does not support `__math_errhandling()` builtin as a macro function or a constexpr function.- `math.h` defines `UNDERFLOW` and `OVERFLOW` macros.- Besides 5 usual floating point exceptions: `FE_INEXACT`, `FE_UNDERFLOW`, `FE_OVERFLOW`, `FE_DIVBYZERO`, and `FE_INVALID`, `fenv.h` also has another floating point exception: `FE_FLUSHTOZERO`. The corresponding trap for `FE_FLUSHTOZERO` in the control register is at the different location compared to the status register.- `FE_FLUSHTOZERO` exception flag cannot be raised with the default CPU floating point operation mode.Reviewed By: sivachandraDifferential Revision: https://reviews.llvm.org/D120914
[libc] Fix small bugs in aarch64/FEnvImpl.h and simplify feclearexcept_test.Fix small bugs in aarch64/EFnvImpl.h and simplify feclearexcept_test.Reviewed By: sivachandraDifferential Revision: h
[libc] Fix small bugs in aarch64/FEnvImpl.h and simplify feclearexcept_test.Fix small bugs in aarch64/EFnvImpl.h and simplify feclearexcept_test.Reviewed By: sivachandraDifferential Revision: https://reviews.llvm.org/D120997
[libc] Refactor sqrt implementations and add tests for generic sqrt implementations.Re-apply https://reviews.llvm.org/D118173 with fix for aarch64.Reviewed By: michaelrjDifferential Revision: h
[libc] Refactor sqrt implementations and add tests for generic sqrt implementations.Re-apply https://reviews.llvm.org/D118173 with fix for aarch64.Reviewed By: michaelrjDifferential Revision: https://reviews.llvm.org/D118433
[libc] Revert "Refactor sqrt implementations and add tests for generic sqrt implementations."This reverts commit 21c4c82c2026bac1f53be54923c0663d41d0a0aa.
[libc] Refactor sqrt implementations and add tests for generic sqrt implementations.Refactor sqrt implementations:- Move architecture specific instructions from `src/math/<arch>` to `src/__support
[libc] Refactor sqrt implementations and add tests for generic sqrt implementations.Refactor sqrt implementations:- Move architecture specific instructions from `src/math/<arch>` to `src/__support/FPUtil/<arch>` folder.- Move generic implementation of `sqrt` to `src/__support/FPUtil/generic` folder and add it as a header library.- Use `src/__support/FPUtil/sqrt.h` for architecture/generic selections.- Add unit tests for generic implementation of `sqrt`.Reviewed By: sivachandraDifferential Revision: https://reviews.llvm.org/D118173
[libc] Add a naming rule for global constants.Reviewed By: michaelrjDifferential Revision: https://reviews.llvm.org/D117645
[libc] apply new lint rulesThis patch applies the lint rules described in the previous patch. Therewas also a significant amount of effort put into manually fixing things,since all of the templat
[libc] apply new lint rulesThis patch applies the lint rules described in the previous patch. Therewas also a significant amount of effort put into manually fixing things,since all of the templated functions, or structs defined in /spec, werenot updated and had to be handled manually.Reviewed By: sivachandra, lntueDifferential Revision: https://reviews.llvm.org/D114302
[libc] Select FPUtils implementations via code instead of buildWe want to simplify the build system and rely on code to do the implementation selection.This is in preparation of adding a Bazel con
[libc] Select FPUtils implementations via code instead of buildWe want to simplify the build system and rely on code to do the implementation selection.This is in preparation of adding a Bazel configuration (D114712).Differential Revision: https://reviews.llvm.org/D115034
[libc][NFC] Move utils/CPP to src/__support/CPP.The idea is to move all pieces related to the actual libc sources to the"src" directory. This allows downstream users to ship and build just the"sr
[libc][NFC] Move utils/CPP to src/__support/CPP.The idea is to move all pieces related to the actual libc sources to the"src" directory. This allows downstream users to ship and build just the"src" directory.Reviewed By: michaelrjDifferential Revision: https://reviews.llvm.org/D112653
[libc] Add FE_DFL_ENV and handle it in fesetenv.Reviewed By: michaelrjDifferential Revision: https://reviews.llvm.org/D110611
[libc] Skip fenv exception tests on aarch64 if HW doesn't support exceptions.Reviewed By: michaelrjDifferential Revision: https://reviews.llvm.org/D109538
[libc][nfc] move ctype_utils and FPUtils to __supportSome ctype functions are called from other libc functions (e.g. isspaceis used in atoi). By moving ctype_utils.h to __support it becomes easier
[libc][nfc] move ctype_utils and FPUtils to __supportSome ctype functions are called from other libc functions (e.g. isspaceis used in atoi). By moving ctype_utils.h to __support it becomes easierto include just the implementations of these functions. For thesereasons the implementation for isspace was moved intoctype_utils as well.FPUtils was moved to simplify the build order, and to clarify whichfiles are a part of the actual libc.Many files were modified to accomodate these changes, mostly changingthe #include paths.Reviewed By: sivachandraDifferential Revision: https://reviews.llvm.org/D107600