Skip to content

Commit

Permalink
Auto merge of #120718 - saethlin:reasonable-fast-math, r=nnethercote
Browse files Browse the repository at this point in the history
Add "algebraic" fast-math intrinsics, based on fast-math ops that cannot return poison

Setting all of LLVM's fast-math flags makes our fast-math intrinsics very dangerous, because some inputs are UB. This set of flags permits common algebraic transformations, but according to the [LangRef](https://llvm.org/docs/LangRef.html#fastmath), only the flags `nnan` (no nans) and `ninf` (no infs) can produce poison.

And this uses the algebraic float ops to fix rust-lang/rust#120720

cc `@orlp`
  • Loading branch information
bors committed Feb 21, 2024
2 parents 33acda0 + 3bd58b5 commit 3e52033
Showing 0 changed files with 0 additions and 0 deletions.

0 comments on commit 3e52033

Please sign in to comment.