[llvm-branch-commits] [llvm] ValueTracking: Improve handling for fma/fmuladd (PR #175614)

via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Mon Jan 12 11:46:52 PST 2026


github-actions[bot] wrote:

<!--PREMERGE ADVISOR COMMENT: Windows-->
# :window: Windows x64 Test Results

* 129352 tests passed
* 2860 tests skipped
* 2 tests failed

## Failed Tests
(click on a test name to see its output)

### LLVM
<details>
<summary>LLVM.CodeGen/PowerPC/peephole-mma-phi-liveness.ll</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 2
c:\_work\llvm-project\llvm-project\build\bin\llc.exe -verify-machineinstrs -mcpu=ppc -mtriple=powerpc64-ibm-aix < C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\PowerPC\peephole-mma-phi-liveness.ll | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\PowerPC\peephole-mma-phi-liveness.ll
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\llc.exe' -verify-machineinstrs -mcpu=ppc -mtriple=powerpc64-ibm-aix
# note: command had no output on stdout or stderr
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' 'C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\PowerPC\peephole-mma-phi-liveness.ll'
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\PowerPC\peephole-mma-phi-liveness.ll:36:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: xxlxor 2, 2, 2
# |               ^
# | <stdin>:39:16: note: scanning from here
# |  xxlxor 0, 0, 0
# |                ^
# | <stdin>:40:2: note: possible intended match here
# |  xvsubdp 1, 0, 1
# |  ^
# | 
# | Input file: <stdin>
# | Check file: C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\PowerPC\peephole-mma-phi-liveness.ll
# | 
# | -dump-input=help explains the following input dump.
# | 
# | Input was:
# | <<<<<<
# |            .
# |            .
# |            .
# |           34: L..BB0_3: # %bb13 
# |           35:  # =>This Inner Loop Header: Depth=1 
# |           36:  bc 4, 2, L..BB0_3 
# |           37: # %bb.4: # %bb14 
# |           38:  xxmfacc 0 
# |           39:  xxlxor 0, 0, 0 
# | next:36'0                    X error: no match found
# |           40:  xvsubdp 1, 0, 1 
# | next:36'0     ~~~~~~~~~~~~~~~~~
# | next:36'1      ?                possible intended match
# |           41:  xvmaddadp 0, 1, 0 
# | next:36'0     ~~~~~~~~~~~~~~~~~~~
# |           42:  xxswapd 0, 0 
# | next:36'0     ~~~~~~~~~~~~~~
# |           43:  stxv 0, 0(3) 
# | next:36'0     ~~~~~~~~~~~~~~
# |           44:  blr 
# | next:36'0     ~~~~~
# |           45: L..baz0: 
# | next:36'0     ~~~~~~~~~
# |            .
# |            .
# |            .
# | >>>>>>
# `-----------------------------
# error: command failed with exit status: 1

--

```
</details>
<details>
<summary>LLVM.Transforms/InstCombine/fabs.ll</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 2
c:\_work\llvm-project\llvm-project\build\bin\opt.exe -mtriple=x86_64-unknown-linux-gnu < C:\_work\llvm-project\llvm-project\llvm\test\Transforms\InstCombine\fabs.ll -passes=instcombine -S | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\llvm\test\Transforms\InstCombine\fabs.ll
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\opt.exe' -mtriple=x86_64-unknown-linux-gnu -passes=instcombine -S
# note: command had no output on stdout or stderr
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' 'C:\_work\llvm-project\llvm-project\llvm\test\Transforms\InstCombine\fabs.ll'
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\InstCombine\fabs.ll:210:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: ret float [[FMA]]
# |               ^
# | <stdin>:125:78: note: scanning from here
# |  %fma = call nnan float @llvm.fma.f32(float %x, float %x, float 1.000000e+00)
# |                                                                              ^
# | <stdin>:125:78: note: with "FMA" equal to "%fma"
# |  %fma = call nnan float @llvm.fma.f32(float %x, float %x, float 1.000000e+00)
# |                                                                              ^
# | <stdin>:127:2: note: possible intended match here
# |  ret float %fabsf
# |  ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\InstCombine\fabs.ll:231:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: ret float [[FMULADD]]
# |               ^
# | <stdin>:137:86: note: scanning from here
# |  %fmuladd = call nnan float @llvm.fmuladd.f32(float %x, float %x, float 1.000000e+00)
# |                                                                                      ^
# | <stdin>:137:86: note: with "FMULADD" equal to "%fmuladd"
# |  %fmuladd = call nnan float @llvm.fmuladd.f32(float %x, float %x, float 1.000000e+00)
# |                                                                                      ^
# | <stdin>:139:2: note: possible intended match here
# |  ret float %fabsf
# |  ^
# | 
# | Input file: <stdin>
# | Check file: C:\_work\llvm-project\llvm-project\llvm\test\Transforms\InstCombine\fabs.ll
# | 
# | -dump-input=help explains the following input dump.
# | 
# | Input was:
# | <<<<<<
# |             .
# |             .
# |             .
# |           120:  %fabsf = call float @llvm.fabs.f32(float %fma) 
# |           121:  ret float %fabsf 
# |           122: } 
# |           123:  
# |           124: define float @square_nnan_fma_fabs_intrinsic_f32(float noundef %x) { 
# |           125:  %fma = call nnan float @llvm.fma.f32(float %x, float %x, float 1.000000e+00) 
# | next:210'0                                                                                  X error: no match found
# | next:210'1                                                                                    with "FMA" equal to "%fma"
# |           126:  %fabsf = call float @llvm.fabs.f32(float %fma) 
# | next:210'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |           127:  ret float %fabsf 
# | next:210'0     ~~~~~~~~~~~~~~~~~~
# | next:210'2      ?                 possible intended match
# |           128: } 
# | next:210'0     ~~
# |           129:  
# | next:210'0     ~
# |           130: define float @square_fmuladd_fabs_intrinsic_f32(float noundef %x) { 
# | next:210'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |           131:  %fmuladd = call float @llvm.fmuladd.f32(float %x, float %x, float 1.000000e+00) 
# |           132:  %fabsf = call float @llvm.fabs.f32(float %fmuladd) 
# |           133:  ret float %fabsf 
# |           134: } 
# |           135:  
# |           136: define float @square_nnan_fmuladd_fabs_intrinsic_f32(float noundef %x) { 
# |           137:  %fmuladd = call nnan float @llvm.fmuladd.f32(float %x, float %x, float 1.000000e+00) 
# | next:231'0                                                                                          X error: no match found
# | next:231'1                                                                                            with "FMULADD" equal to "%fmuladd"
# |           138:  %fabsf = call float @llvm.fabs.f32(float %fmuladd) 
# | next:231'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |           139:  ret float %fabsf 
# | next:231'0     ~~~~~~~~~~~~~~~~~~
# | next:231'2      ?                 possible intended match
# |           140: } 
# | next:231'0     ~~
# |           141:  
# | next:231'0     ~
# |           142: define double @multi_use_fabs_fpext(float %x) { 
# | next:231'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |           143:  %fpext = fpext float %x to double 
# |           144:  %fabs = call double @llvm.fabs.f64(double %fpext) 
# |             .
# |             .
# |             .
# | >>>>>>
# `-----------------------------
# error: command failed with exit status: 1

--

```
</details>

If these failures are unrelated to your changes (for example tests are broken or flaky at HEAD), please open an issue at https://github.com/llvm/llvm-project/issues and add the `infrastructure` label.

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


More information about the llvm-branch-commits mailing list