[llvm] [GlobalISel][AArch64] Implement `llvm.{get,set}.rounding` lowering (PR #210665)

Nathan Corbyn via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 18 03:00:19 PDT 2026


=?utf-8?q?Ömer_Sinan_Ağacan?= <omeragacan at gmail.com>,
=?utf-8?q?Ömer_Sinan_Ağacan?= <omeragacan at gmail.com>,
=?utf-8?q?Ömer_Sinan_Ağacan?= <omer at osa1.net>
Message-ID:
In-Reply-To: <llvm.org/llvm/llvm-project/pull/210665 at github.com>


cofibrant wrote:

> However I don't see any documentation that says `llvm.{set,get}.rounding` outside of `strictfp` are UB.

The impression I got from @arsenm's comments was that this would be UB on the basis that non-constrained FP operations bake in assumptions about the rounding mode and therefore setting it explicitly without using constrained FP intrinsics would be incorrect but I could very definitely be wrong about this.

> The constrained version of it is `llvm.experimental.constrained.fadd.f32`, but if I use the constrained version then the test becomes identical to the next test.

If rewriting this test to be correct as I currently understand is equivalent to deleting the test, I would probably err on the side of leaving it as is, but if @arsenm is confident it's incorrect, I think it makes sense to drop it.

https://github.com/llvm/llvm-project/pull/210665


More information about the llvm-commits mailing list