[llvm] [X86] Fix expand-fp on optnone functions (PR #156900)

Frederik Harwath via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 5 03:28:56 PDT 2025


================
@@ -0,0 +1,98 @@
+; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 5
+; RUN: opt -S -mtriple=x86_64-- --expand-fp < %s | FileCheck %s
----------------
frederik-h wrote:

> If the pass always execute with legacy PM (no skipFunction), then I think it would be more correct to also implement isRequired for the new PM to get same behavior.
> 
> So one would need to add a line such as
> 
> ` static bool isRequired() { return true; }`
> 
> in the class definition for passes that are mandatory to execute even with optnone.

Thank you! I have added this now as it is pretty clear that the pass must run for correctness.

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


More information about the llvm-commits mailing list