Detect if the architecture supports FMA instructions and if
the targets depend on fma.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
libc/cmake/modules/LLVMLibCObjectRules.cmake | ||
---|---|---|
35 | would it be possible to make this a more generic option than just FMA? Perhaps there's a way to use generator expressions? |
libc/cmake/modules/LLVMLibCObjectRules.cmake | ||
---|---|---|
35 | A more general option is now added with https://reviews.llvm.org/D125174. |
libc/cmake/modules/LLVMLibCObjectRules.cmake | ||
---|---|---|
17 | It would make sense to factor the two conditions inside the fma variable. | |
libc/test/src/math/CMakeLists.txt | ||
1204–1205 | I'm not sure I understand the semantic here. Does that mean that the test requires FMA? Maybe I missed something. |
libc/test/src/math/CMakeLists.txt | ||
---|---|---|
1204–1205 | Yes, for this patch, this test does require FMA. That is because without FMA instructions, the current expm1f implementation is not correctly rounded for all float inputs (1 extra exceptional value). This will be fixed in the followup patch: https://reviews.llvm.org/D123440 |
"Skip FMA_OPT flag for target that don't support fma"