<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/72630>72630</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
Assertion `!(IsVariadic && IsIndirect)' fail on debug info during DAG selection
</td>
</tr>
<tr>
<th>Labels</th>
<td>
backend:X86,
debuginfo,
llvm:SelectionDAG
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
KanRobert
</td>
</tr>
</table>
<pre>
```
target datalayout = "e-m:w-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-windows-msvc"
%struct.foo = type <{ double, %struct.zot }>
%struct.zot = type { ptr, i64, i64, i64, i64, i64, [1 x { i64, i64, i64 }] }
; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare void @llvm.dbg.declare(metadata, metadata, metadata) #0
define void @barney(ptr %arg, i64 %arg1) {
bb:
br label %bb3
bb2: ; preds = %bb3
ret void
bb3: ; preds = %bb3, %bb
%getelementptr = getelementptr %struct.foo, ptr %arg, i64 %arg1
call void @llvm.dbg.declare(metadata ptr %getelementptr, metadata !64, metadata !DIExpression()), !dbg !68
%load = load double, ptr %getelementptr, align 8
%fcmp = fcmp ugt double %load, 0.000000e+00
br i1 %fcmp, label %bb3, label %bb2
}
attributes #0 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
!llvm.module.flags = !{!0}
!llvm.dbg.cu = !{!1}
!0 = !{i32 2, !"Debug Info Version", i32 3}
!1 = distinct !DICompileUnit(language: DW_LANG_Fortran95, file: !2, producer: "Fortran", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, globals: !3, splitDebugInlining: false, nameTableKind: None)
!2 = !DIFile(filename: "modules_fld_in_spec_exp_4.f90", directory: "C")
!3 = !{!4, !12, !14, !17, !19, !23, !26, !29, !33, !36, !39, !42, !45, !48, !54, !58, !61}
!4 = !DIGlobalVariableExpression(var: !5, expr: !DIExpression())
!5 = distinct !DIGlobalVariable(name: "FMAX", linkageName: "VH01_DOUBLE_mp_VH01AD_MAIN_ITERATION$FMAX", scope: !6, file: !2, line: 317, type: !11, isLocal: true, isDefinition: true)
!6 = distinct !DISubprogram(name: "VH01AD_MAIN_ITERATION", linkageName: "VH01_DOUBLE_mp_VH01AD_MAIN_ITERATION", scope: !7, file: !2, line: 276, type: !8, scopeLine: 276, spFlags: DISPFlagDefinition, unit: !1, retainedNodes: !10)
!7 = !DIModule(scope: null, name: "VH01_DOUBLE", file: !2, line: 272)
!8 = !DISubroutineType(types: !9)
!9 = !{null}
!10 = !{}
!11 = !DIBasicType(name: "REAL*8", size: 64, encoding: DW_ATE_float)
!12 = !DIGlobalVariableExpression(var: !13, expr: !DIExpression())
!13 = distinct !DIGlobalVariable(name: "FMIN", linkageName: "VH01_DOUBLE_mp_VH01AD_MAIN_ITERATION$FMIN", scope: !6, file: !2, line: 317, type: !11, isLocal: true, isDefinition: true)
!14 = !DIGlobalVariableExpression(var: !15, expr: !DIExpression())
!15 = distinct !DIGlobalVariable(name: "IMIN", linkageName: "VH01_DOUBLE_mp_VH01AD_MAIN_ITERATION$IMIN", scope: !6, file: !2, line: 316, type: !16, isLocal: true, isDefinition: true)
!16 = !DIBasicType(name: "INTEGER*4", size: 32, encoding: DW_ATE_signed)
!17 = !DIGlobalVariableExpression(var: !18, expr: !DIExpression())
!18 = distinct !DIGlobalVariable(name: "TWOM", linkageName: "VH01_DOUBLE_mp_VH01AD_MAIN_ITERATION$TWOM", scope: !6, file: !2, line: 316, type: !16, isLocal: true, isDefinition: true)
!19 = !DIGlobalVariableExpression(var: !20, expr: !DIExpression())
!20 = distinct !DIGlobalVariable(name: "Y", linkageName: "VH01_DOUBLE_mp_VH01AD_MAIN_ITERATION$Y", scope: !6, file: !2, line: 320, type: !21, isLocal: true, isDefinition: true)
!21 = !DICompositeType(tag: DW_TAG_array_type, baseType: !22, elements: !10, dataLocation: !DIExpression(DW_OP_push_object_address, DW_OP_deref), allocated: !DIExpression(DW_OP_push_object_address, DW_OP_plus_uconst, 24, DW_OP_deref, DW_OP_constu, 1, DW_OP_and))
!22 = !DIBasicType(name: "LOGICAL*1", size: 8, encoding: DW_ATE_boolean)
!23 = !DIGlobalVariableExpression(var: !24, expr: !DIExpression())
!24 = distinct !DIGlobalVariable(name: "PICK", linkageName: "VH01_DOUBLE_mp_VH01AD_MAIN_ITERATION$PICK", scope: !6, file: !2, line: 319, type: !25, isLocal: true, isDefinition: true)
!25 = distinct !DICompositeType(tag: DW_TAG_array_type, baseType: !22, elements: !10, dataLocation: !DIExpression(DW_OP_push_object_address, DW_OP_deref), allocated: !DIExpression(DW_OP_push_object_address, DW_OP_plus_uconst, 24, DW_OP_deref, DW_OP_constu, 1, DW_OP_and))
!26 = !DIGlobalVariableExpression(var: !27, expr: !DIExpression())
!27 = distinct !DIGlobalVariable(name: "PROB", linkageName: "VH01_DOUBLE_mp_VH01AD_MAIN_ITERATION$PROB", scope: !6, file: !2, line: 318, type: !28, isLocal: true, isDefinition: true)
!28 = !DICompositeType(tag: DW_TAG_array_type, baseType: !11, elements: !10, dataLocation: !DIExpression(DW_OP_push_object_address, DW_OP_deref), allocated: !DIExpression(DW_OP_push_object_address, DW_OP_plus_uconst, 24, DW_OP_deref, DW_OP_constu, 1, DW_OP_and))
!29 = !DIGlobalVariableExpression(var: !30, expr: !DIExpression(DW_OP_constu, 1, DW_OP_stack_value))
!30 = distinct !DIGlobalVariable(name: "N", linkageName: "VH01_DOUBLE_mp_VH01ED_RANDOM_REAL$N", scope: !31, file: !2, line: 732, type: !16, isLocal: true, isDefinition: true)
!31 = distinct !DISubprogram(name: "VH01ED_RANDOM_REAL", linkageName: "VH01_DOUBLE_mp_VH01ED_RANDOM_REAL", scope: !7, file: !2, line: 714, type: !32, scopeLine: 714, spFlags: DISPFlagDefinition, unit: !1, retainedNodes: !10)
!32 = !DISubroutineType(types: !10)
!33 = !DIGlobalVariableExpression(var: !34, expr: !DIExpression())
!34 = distinct !DIGlobalVariable(name: "IX", linkageName: "FA04FD_mp_IX", scope: !35, file: !2, line: 762, type: !16, isLocal: false, isDefinition: true)
!35 = !DIModule(scope: null, name: "FA04FD", file: !2, line: 753)
!36 = !DIGlobalVariableExpression(var: !37, expr: !DIExpression())
!37 = distinct !DIGlobalVariable(name: "IX", linkageName: "FA04FD_mp_IX", scope: !38, file: !2, line: 772, type: !16, isLocal: false, isDefinition: true)
!38 = distinct !DISubprogram(name: "FA04AD", linkageName: "FA04AD", scope: !2, file: !2, line: 772, type: !32, scopeLine: 772, spFlags: DISPFlagDefinition, unit: !1, retainedNodes: !10)
!39 = !DIGlobalVariableExpression(var: !40, expr: !DIExpression())
!40 = distinct !DIGlobalVariable(name: "IX", linkageName: "FA04FD_mp_IX", scope: !41, file: !2, line: 842, type: !16, isLocal: false, isDefinition: true)
!41 = distinct !DISubprogram(name: "FA04BD", linkageName: "FA04BD", scope: !2, file: !2, line: 842, type: !8, scopeLine: 842, spFlags: DISPFlagDefinition, unit: !1, retainedNodes: !10)
!42 = !DIGlobalVariableExpression(var: !43, expr: !DIExpression())
!43 = distinct !DIGlobalVariable(name: "IX", linkageName: "FA04FD_mp_IX", scope: !44, file: !2, line: 963, type: !16, isLocal: false, isDefinition: true)
!44 = distinct !DISubprogram(name: "FA04CD", linkageName: "FA04CD", scope: !2, file: !2, line: 963, type: !8, scopeLine: 963, spFlags: DISPFlagDefinition, unit: !1, retainedNodes: !10)
!45 = !DIGlobalVariableExpression(var: !46, expr: !DIExpression())
!46 = distinct !DIGlobalVariable(name: "IX", linkageName: "FA04FD_mp_IX", scope: !47, file: !2, line: 981, type: !16, isLocal: false, isDefinition: true)
!47 = distinct !DISubprogram(name: "FA04DD", linkageName: "FA04DD", scope: !2, file: !2, line: 981, type: !8, scopeLine: 981, spFlags: DISPFlagDefinition, unit: !1, retainedNodes: !10)
!48 = !DIGlobalVariableExpression(var: !49, expr: !DIExpression())
!49 = distinct !DIGlobalVariable(name: "EVAL", linkageName: "GENETI$EVAL", scope: !50, file: !2, line: 1036, type: !51, isLocal: true, isDefinition: true)
!50 = distinct !DISubprogram(name: "GENETI", linkageName: "MAIN__", scope: !2, file: !2, line: 999, type: !8, scopeLine: 999, spFlags: DISPFlagDefinition | DISPFlagMainSubprogram, unit: !1, retainedNodes: !10)
!51 = distinct !DICompositeType(tag: DW_TAG_structure_type, name: "EVALUATE", scope: !53, file: !52, size: 640, elements: !10, identifier: "EVALUATE4")
!52 = !DIFile(filename: "", directory: "C:\\iusers\\skan\\CMPLRLLVM-53548")
!53 = !DIModule(scope: null, name: "GENETI", isDecl: true)
!54 = !DIGlobalVariableExpression(var: !55, expr: !DIExpression())
!55 = distinct !DIGlobalVariable(name: "POP", linkageName: "GENETI$POP", scope: !50, file: !2, line: 1035, type: !56, isLocal: true, isDefinition: true)
!56 = !DICompositeType(tag: DW_TAG_array_type, baseType: !57, elements: !10)
!57 = distinct !DICompositeType(tag: DW_TAG_structure_type, name: "STRING_CHARACTERISTICS", scope: !53, file: !52, size: 640, elements: !10, identifier: "STRING_CHARACTERISTICS5")
!58 = !DIGlobalVariableExpression(var: !59, expr: !DIExpression())
!59 = distinct !DIGlobalVariable(name: "PARAM", linkageName: "GENETI$PARAM", scope: !50, file: !2, line: 1034, type: !60, isLocal: true, isDefinition: true)
!60 = distinct !DICompositeType(tag: DW_TAG_structure_type, name: "TUNING_PARAMETERS", scope: !53, file: !52, size: 256, elements: !10, identifier: "TUNING_PARAMETERS6")
!61 = !DIGlobalVariableExpression(var: !62, expr: !DIExpression())
!62 = distinct !DIGlobalVariable(name: "INFO", linkageName: "GENETI$INFO", scope: !50, file: !2, line: 1033, type: !63, isLocal: true, isDefinition: true)
!63 = distinct !DICompositeType(tag: DW_TAG_structure_type, name: "INFORMATION", scope: !53, file: !52, size: 96, elements: !10, identifier: "INFORMATION7")
!64 = !DILocalVariable(name: "FBEST", arg: 1, scope: !65, file: !2, line: 242, type: !11)
!65 = distinct !DISubprogram(name: "TERMINATE", linkageName: "DOUBLE_TEST_EAXMPLE_mp_TERMINATE", scope: !66, file: !2, line: 242, type: !67, scopeLine: 242, spFlags: DISPFlagDefinition, unit: !1, retainedNodes: !10)
!66 = !DIModule(scope: null, name: "DOUBLE_TEST_EAXMPLE", file: !2, line: 204)
!67 = distinct !DISubroutineType(types: !10)
!68 = !DILocation(line: 242, scope: !65, inlinedAt: !69)
!69 = distinct !DILocation(line: 1135, scope: !50)
```
$ llc reduced.ll
llc: /export/users/skan/llvm-project/llvm/lib/CodeGen/SelectionDAG/SDNodeDbgValue.h:166: llvm::SDDbgValue::SDDbgValue(llvm::BumpPtrAllocator&, llvm::DIVariable*, llvm::DIExpression*, llvm::ArrayRef<llvm::SDDbgOperand>, llvm::ArrayRef<llvm::SDNode*>, bool, llvm::DebugLoc, unsigned int, bool): Assertion `!(IsVariadic && IsIndirect)' failed.
Failed from https://github.com/llvm/llvm-project/pull/68981/
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJzsW11zm7jX_zTkhkkGJN58kQts7CyziZNx3Hb3ihEgu9rKwIBom_30z0gCGzB2IieZvXj-nY4D0tF5_Z0jcYxRVZFthvGtZk81O7hCNfuel7d_omyVx7hkV3GevtxqjtH8NwLN8Bkqt5jpKWKIope8ZroGA10DAF_vNOj_ui6Aa2jQh0B88Fuzf8uvHEt8XJP9hQk8Dfom8K43ntFcZWLIaZc71vUzJwOgpworSUFxq8Zvz4kc67pIrn-RLM1_Vde76meyX9N8ArtiZZ2wm02ei5XspeAsZpo71dO8jinWwEw_0P2bM11zAw3OhxzEzJ6DO9ULVvK13LRX_mj21NR_i0VH80KaHYg_Xc3hVF_UWcJInuk-Y2WlQV_P8gRRGqPkh57lmxJjPcurlyzRs7zOuB_0qsBJTRFDMcX6L0JpiVldZvoO7_LyRQNelmdYAxMpJcUJRSXWf-Yk1TXLoPTn7iaNtzfNhAa8HWaIg4CrO3490TUAja7yKd6Q7MA1RmWGueyCldzVqN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