[llvm] [Metadata][profcheck] Handle identical MDNodes in getMergedProfMetadata (PR #175701)

via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 12 19:15:13 PST 2026


github-actions[bot] wrote:

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

* 129365 tests passed
* 2862 tests skipped
* 1 test failed

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

### LLVM
<details>
<summary>LLVM.Transforms/GVN/calls-readonly.ll</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 2
c:\_work\llvm-project\llvm-project\build\bin\opt.exe < C:\_work\llvm-project\llvm-project\llvm\test\Transforms\GVN\calls-readonly.ll -passes=gvn -S | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\llvm\test\Transforms\GVN\calls-readonly.ll
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\opt.exe' -passes=gvn -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\GVN\calls-readonly.ll'
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\GVN\calls-readonly.ll:53:10: error: CHECK: expected string not found in input
# | ; CHECK: [[PROF0]] = !{!"branch_weights", i64 190}
# |          ^
# | <stdin>:22:12: note: scanning from here
# |  ret ptr %5
# |            ^
# | <stdin>:22:12: note: with "PROF0" equal to "!0"
# |  ret ptr %5
# |            ^
# | <stdin>:33:2: note: possible intended match here
# | !0 = !{!"branch_weights", i32 95}
# |  ^
# | 
# | Input file: <stdin>
# | Check file: C:\_work\llvm-project\llvm-project\llvm\test\Transforms\GVN\calls-readonly.ll
# | 
# | -dump-input=help explains the following input dump.
# | 
# | Input was:
# | <<<<<<
# |             .
# |             .
# |             .
# |            17: bb1: ; preds = %bb, %entry 
# |            18:  %x_addr.0 = phi i32 [ %2, %bb ], [ %x, %entry ] 
# |            19:  %3 = tail call ptr @strchr(ptr %Q, i32 97) 
# |            20:  %4 = add i32 %x_addr.0, %0 
# |            21:  %5 = getelementptr i8, ptr %3, i32 %x_addr.0 
# |            22:  ret ptr %5 
# | check:53'0                X error: no match found
# | check:53'1                  with "PROF0" equal to "!0"
# |            23: } 
# | check:53'0     ~~
# |            24:  
# | check:53'0     ~
# |            25: ; Function Attrs: nounwind memory(read) 
# | check:53'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |            26: declare i32 @strlen(ptr) #0 
# | check:53'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |            27:  
# | check:53'0     ~
# |            28: ; Function Attrs: nounwind memory(read) 
# | check:53'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |            29: declare ptr @strchr(ptr, i32) #0 
# | check:53'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |            30:  
# | check:53'0     ~
# |            31: attributes #0 = { nounwind memory(read) } 
# | check:53'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |            32:  
# | check:53'0     ~
# |            33: !0 = !{!"branch_weights", i32 95} 
# | check:53'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | check:53'2      ?                                 possible intended match
# | >>>>>>
# `-----------------------------
# 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/175701


More information about the llvm-commits mailing list