llvm/llvm-project
在 GitHub 查看scalbln(x, n), scalbn(x, n), ldexp(x, n) are not folded at the compilation time when (x, n) is constant
Open
#112,631 建立於 2024年10月16日
floating-pointgood first issuellvm:optimizationsmissed-optimization
倉庫指標
- Star
- (26,378 star)
- PR 合併指標
- (平均合併 1天 2小時) (30 天內合併 1,000 個 PR)
描述
Consider the following example. https://godbolt.org/z/54xsG8WTr
#include <cmath>
double f1() {
return std::scalbln(3.0, 4);
}
double f2() {
return std::scalbn(3.0, 4);
}
double f3() {
return std::ldexp(3.0, 4);
}