Debian Codegraph @

llvm/test/tools/dsymutil/X86/mismatch.m

raw
1 /* Compile with:
2 cat >modules.modulemap <<EOF
3 module mismatch {
4 header "mismatch.h"
5 }
6 EOF
7 echo "struct s;"> mismatch.h
8 clang -cc1 -emit-obj -fmodules -fmodule-map-file=modules.modulemap \
9 -fmodule-format=obj -g -dwarf-ext-refs -fmodules-cache-path=. \
10 -fdisable-module-hash mismatch.m -o 1.o
11 echo > mismatch.h
12 clang -cc1 -emit-obj -fmodules -fmodule-map-file=modules.modulemap \
13 -fmodule-format=obj -g -dwarf-ext-refs -fmodules-cache-path=. \
14 -fdisable-module-hash mismatch.m -o /dev/null
15 */
16
17 // RUN: rm -rf %t.dir && mkdir %t.dir
18 // RUN: cp %p/../Inputs/mismatch/1.o %p/../Inputs/mismatch/mismatch.pcm %t.dir
19 // RUN: cp %p/../Inputs/mismatch/1.o %t.dir/2.o
20 // RUN: dsymutil --verbose -f -oso-prepend-path=%t.dir \
21 // RUN: -y %p/dummy-debug-map.map -o %t.bin 2>&1 | FileCheck %s
22 // RUN: dsymutil --linker parallel --verbose -f -oso-prepend-path=%t.dir \
23 // RUN: -y %p/dummy-debug-map.map -o %t.bin 2>&1 | FileCheck %s
24
25 @import mismatch;
26
27 void f() {}
28 // Mismatch after importing the module.
29 // CHECK: warning: hash mismatch
30 // Mismatch in the cache.
31 // CHECK: warning: hash mismatch
32 // CHECK: cached