[llvm] [DebugInfo] Enforce DISubprogram type as required in LLParser (PR #196299)

via llvm-commits llvm-commits at lists.llvm.org
Thu May 7 05:57:44 PDT 2026


github-actions[bot] wrote:

<!--PREMERGE ADVISOR COMMENT: Linux-->
# :penguin: Linux x64 Test Results

* 173897 tests passed
* 3307 tests skipped
* 1 test failed

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

### MLIR
<details>
<summary>MLIR.Target/LLVMIR/Import/global-variables.ll</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 1
/home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/mlir-translate -import-llvm -split-input-file /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/Target/LLVMIR/Import/global-variables.ll | /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/Target/LLVMIR/Import/global-variables.ll
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/mlir-translate -import-llvm -split-input-file /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/Target/LLVMIR/Import/global-variables.ll
# .---command stderr------------
# | <unknown>:0: error: within split at /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/Target/LLVMIR/Import/global-variables.ll:280 offset :19:70: error: missing required field 'type'
# | !3 = distinct !DISubprogram(name: "foo", scope: !2, file: !1, line: 5)
# |                                                                      ^
# | 
# `-----------------------------
# error: command failed with exit status: 1
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/Target/LLVMIR/Import/global-variables.ll
# .---command stderr------------
# | /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/Target/LLVMIR/Import/global-variables.ll:282:14: error: CHECK-DAG: expected string not found in input
# | ; CHECK-DAG: #[[TYPE:.*]] = #llvm.di_basic_type<tag = DW_TAG_base_type, name = "int", sizeInBits = 32, encoding = DW_ATE_signed>
# |              ^
# | <stdin>:123:67: note: scanning from here
# |  llvm.mlir.global external protected constant @protected(42 : i64) {addr_space = 0 : i32, dso_local} : i64
# |                                                                   ^
# | <stdin>:127:9: note: possible intended match here
# | #di_basic_type = #llvm.di_basic_type<tag = DW_TAG_base_type, name = "char", sizeInBits = 8, encoding = DW_ATE_signed_char>
# |         ^
# | 
# | Input file: <stdin>
# | Check file: /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/Target/LLVMIR/Import/global-variables.ll
# | 
# | -dump-input=help explains the following input dump.
# | 
# | Input was:
# | <<<<<<
# |            .
# |            .
# |            .
# |          118:  } 
# |          119: } 
# |          120:  
# |          121: module attributes {dlti.dl_spec = #dlti.dl_spec<!llvm.ptr = dense<64> : vector<4xi64>, i1 = dense<8> : vector<2xi64>, i8 = dense<8> : vector<2xi64>, i16 = dense<16> : vector<2xi64>, i32 = dense<32> : vector<2xi64>, i64 = dense<[32, 64]> : vector<2xi64>, f16 = dense<16> : vector<2xi64>, f64 = dense<64> : vector<2xi64>, f128 = dense<128> : vector<2xi64>, "dlti.endianness" = "little">, llvm.module_asm = [], llvm.target_triple = ""} { 
# |          122:  llvm.mlir.global external hidden constant @hidden("string") {addr_space = 0 : i32, dso_local} 
# |          123:  llvm.mlir.global external protected constant @protected(42 : i64) {addr_space = 0 : i32, dso_local} : i64 
# | dag:282'0                                                                       X~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ error: no match found
# |          124: } 
# | dag:282'0     ~~
# |          125:  
# | dag:282'0     ~
# |          126:  
# | dag:282'0     ~
# |          127: #di_basic_type = #llvm.di_basic_type<tag = DW_TAG_base_type, name = "char", sizeInBits = 8, encoding = DW_ATE_signed_char> 
# | dag:282'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | dag:282'1             ?                                                                                                                   possible intended match
# |          128: #di_file = #llvm.di_file<"source.c" in "/path/to/file"> 
# | dag:282'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |          129: #di_derived_type = #llvm.di_derived_type<tag = DW_TAG_const_type, baseType = #di_basic_type> 
# | dag:282'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |          130: #di_composite_type = #llvm.di_composite_type<tag = DW_TAG_array_type, baseType = #di_derived_type, sizeInBits = 80> 
# | dag:282'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |          131: #di_global_variable = #llvm.di_global_variable<file = #di_file, line = 268, type = #di_composite_type, isLocalToUnit = true, isDefined = true> 
# | dag:282'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |          132: #di_global_variable_expression = #llvm.di_global_variable_expression<var = #di_global_variable, expr = <>> 
# | dag:282'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# |            .
# |            .
# |            .
# | >>>>>>
# `-----------------------------
# 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/196299


More information about the llvm-commits mailing list