2018-04-26 02:58:06 +08:00
|
|
|
# RUN: llc -mtriple=x86_64-apple-unknown -run-pass none %s -o /dev/null
|
|
|
|
# Check that we parse the 'debug-info-*' fields for `fixedStack:` entries.
|
|
|
|
|
|
|
|
--- |
|
|
|
|
|
|
|
|
target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128"
|
|
|
|
target triple = "x86_64-apple-unknown"
|
|
|
|
|
|
|
|
declare void @llvm.dbg.declare(metadata, metadata, metadata) #0
|
|
|
|
|
2020-11-20 23:52:27 +08:00
|
|
|
define hidden void @foo(i32* byval(i32) %dstRect) {
|
2018-04-26 02:58:06 +08:00
|
|
|
entry:
|
|
|
|
call void @llvm.dbg.declare(metadata i32* %dstRect, metadata !3, metadata !DIExpression()), !dbg !5
|
|
|
|
unreachable
|
|
|
|
}
|
|
|
|
|
|
|
|
attributes #0 = { nounwind readnone speculatable }
|
|
|
|
|
|
|
|
!llvm.dbg.cu = !{!0}
|
|
|
|
!llvm.module.flags = !{!2}
|
|
|
|
|
|
|
|
!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !1)
|
|
|
|
!1 = !DIFile(filename: "file.cpp", directory: "/dir")
|
|
|
|
!2 = !{i32 2, !"Debug Info Version", i32 3}
|
|
|
|
!3 = !DILocalVariable(name: "dstRect", scope: !4)
|
|
|
|
!4 = distinct !DISubprogram(name: "foo", linkageName: "foo", scope: !0, file: !1, line: 42, unit: !0)
|
|
|
|
!5 = !DILocation(line: 42, column: 85, scope: !4)
|
|
|
|
|
|
|
|
...
|
|
|
|
---
|
|
|
|
name: foo
|
[Alignment] Use llvm::Align in MachineFunction and TargetLowering - fixes mir parsing
Summary:
This catches malformed mir files which specify alignment as log2 instead of pow2.
See https://reviews.llvm.org/D65945 for reference,
This is patch is part of a series to introduce an Alignment type.
See this thread for context: http://lists.llvm.org/pipermail/llvm-dev/2019-July/133851.html
See this patch for the introduction of the type: https://reviews.llvm.org/D64790
Reviewers: courbet
Subscribers: MatzeB, qcolombet, dschuff, arsenm, sdardis, nemanjai, jvesely, nhaehnle, hiraditya, kbarton, asb, rbar, johnrusso, simoncook, apazos, sabuasal, niosHD, jrtc27, MaskRay, zzheng, edward-jones, atanasyan, rogfer01, MartinMosbeck, brucehoult, the_o, PkmX, jocewei, jsji, Petar.Avramovic, asbirlea, s.egerton, pzheng, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D67433
llvm-svn: 371608
2019-09-11 19:16:48 +08:00
|
|
|
alignment: 16
|
2018-04-26 02:58:06 +08:00
|
|
|
tracksRegLiveness: true
|
|
|
|
frameInfo:
|
|
|
|
maxAlignment: 8
|
|
|
|
fixedStack:
|
2019-06-17 17:13:29 +08:00
|
|
|
- { id: 0, size: 4, alignment: 16, stack-id: default, debug-info-variable: '!3', debug-info-expression: '!DIExpression()',
|
2018-04-26 02:58:06 +08:00
|
|
|
debug-info-location: '!5' }
|
|
|
|
body: |
|
|
|
|
bb.0.entry:
|
|
|
|
|
|
|
|
...
|