mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-25 20:23:11 +01:00
fc9b585c42
In some cases, for example when compiling a preprocessed file, the front-end is not able to provide an MD5 checksum for all files. When that happens, omit the MD5 checksums from the final DWARF, because DWARF doesn't have a way to indicate that some but not all files have a checksum. When assembling a .s file, and some but not all .file directives provide an MD5 checksum, issue a warning and don't emit MD5 into the DWARF. Fixes PR37623. Differential Revision: https://reviews.llvm.org/D48135 llvm-svn: 334710
27 lines
1.2 KiB
ArmAsm
27 lines
1.2 KiB
ArmAsm
# RUN: not llvm-mc -triple x86_64-unknown-unknown -dwarf-version 5 -filetype=asm %s -o /dev/null 2>&1 | FileCheck %s
|
|
# RUN: not llvm-mc -triple x86_64-unknown-unknown -dwarf-version 5 -filetype=obj %s -o /dev/null 2>&1 | FileCheck %s
|
|
|
|
# This is syntactically legal, looks like no checksum provided.
|
|
# CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
|
|
.file 1 "dir1/foo" "00112233445566778899aabbccddeeff"
|
|
|
|
# Missing md5 keyword.
|
|
# CHECK: [[@LINE+1]]:{{[0-9]+}}: error: unexpected token in '.file' directive
|
|
.file 2 "dir1" "foo" 0x00112233445566778899aabbccddeeff
|
|
|
|
# Bad syntax.
|
|
# CHECK: [[@LINE+1]]:{{[0-9]+}}: error: unknown token in expression
|
|
.file 3 "dir2" "bar" md5 "ff"
|
|
|
|
# No hex prefix.
|
|
# CHECK: [[@LINE+1]]:{{[0-9]+}}: error: unknown token in expression
|
|
.file 4 "dir3" "foo" md5 ffeeddccbbaa99887766554433221100
|
|
|
|
# Non-DWARF .file syntax with checksum.
|
|
# CHECK: [[@LINE+1]]:{{[0-9]+}}: error: MD5 checksum specified, but no file number
|
|
.file "baz" md5 0xffeeddccbbaa99887766554433221100
|
|
|
|
# Inconsistent use of MD5 option. Note: .file 1 did not supply one.
|
|
# CHECK: [[@LINE+1]]:{{[0-9]+}}: warning: inconsistent use of MD5 checksums
|
|
.file 5 "bax" md5 0xffeeddccbbaa99887766554433221100
|