1 // Splitting some tests into POS and NEG parts so the latter can validate
2 // output fragments as large as possible for absence of some text.
4 // Test for include paths and other cc1 flags
6 // RUN: %clang -### %s --target=msp430 -E \
7 // RUN: --sysroot="%S/Inputs/basic_msp430_tree" 2>&1 \
8 // RUN: | FileCheck -check-prefix=INCLUDE-DIRS %s
9 // INCLUDE-DIRS: "-cc1" "-triple" "msp430"
10 // INCLUDE-DIRS: "-internal-isystem" "{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}include"
12 // Tests for passing flags to msp430-elf-ld (not file-related)
14 // RUN: %clang -### %s --target=msp430 --sysroot="" > %t 2>&1
15 // RUN: FileCheck -check-prefix=DEFAULT-POS %s < %t
16 // RUN: FileCheck -check-prefix=DEFAULT-NEG %s < %t
17 // DEFAULT-POS: "{{.*}}msp430-elf-ld"
18 // DEFAULT-POS: "--gc-sections"
19 // DEFAULT-NEG-NOT: "--relax"
21 // RUN: %clang -### %s --target=msp430 --sysroot="" \
22 // RUN: -r 2>&1 | FileCheck --check-prefixes=NO-GC-SECTIONS,RELOCATABLE-OBJECT %s
23 // RUN: %clang -### %s --target=msp430 --sysroot="" \
24 // RUN: -g 2>&1 | FileCheck -check-prefix=NO-GC-SECTIONS %s
25 // NO-GC-SECTIONS: "{{.*}}msp430-elf-ld"
26 // NO-GC-SECTIONS-NOT: "--gc-sections"
27 // RELOCATABLE-OBJECT-NOT: crt0.o
28 // RELOCATABLE-OBJECT-NOT: crtbegin
29 // RELOCATABLE-OBJECT-NOT: crtend
30 // RELOCATABLE-OBJECT-NOT: "-l{{.*}}"
32 // RUN: %clang -### %s --target=msp430 --sysroot="" \
33 // RUN: -Wl,--some-linker-arg 2>&1 | FileCheck -check-prefix=WL-ARG %s
34 // WL-ARG: "{{.*}}msp430-elf-ld"
35 // WL-ARG: "--some-linker-arg"
37 // Trivially mapped options: arbitrarily split into two disjoint groups
38 // to check both "on"/present and "off"/absent state (when appropriate).
40 // RUN: %clang -### %s --target=msp430 --sysroot="" \
41 // RUN: -o /tmp/test.elf -r -t -z muldefs -mrelax > %t 2>&1
42 // RUN: FileCheck -check-prefix=MISC-FLAGS-1-POS %s < %t
43 // RUN: FileCheck -check-prefix=MISC-FLAGS-1-NEG %s < %t
44 // MISC-FLAGS-1-POS: "{{.*}}msp430-elf-ld"
45 // MISC-FLAGS-1-POS-DAG: "--relax"
46 // MISC-FLAGS-1-POS-DAG: "-o" "/tmp/test.elf"
47 // MISC-FLAGS-1-POS-DAG: "-r"
48 // MISC-FLAGS-1-POS-DAG: "-t"
49 // MISC-FLAGS-1-POS-DAG: "-z" "muldefs"
50 // MISC-FLAGS-1-NEG: "{{.*}}msp430-elf-ld"
51 // MISC-FLAGS-1-NEG-NOT: "-e{{.*}}"
52 // MISC-FLAGS-1-NEG-NOT: "-s"
53 // MISC-FLAGS-1-NEG-NOT: "-u"
55 // RUN: %clang -### %s --target=msp430 --sysroot="" \
56 // RUN: -e EntryPoint -s -u __undef > %t 2>&1
57 // RUN: FileCheck -check-prefix=MISC-FLAGS-2-POS %s < %t
58 // RUN: FileCheck -check-prefix=MISC-FLAGS-2-NEG %s < %t
59 // MISC-FLAGS-2-POS: "{{.*}}msp430-elf-ld"
60 // MISC-FLAGS-2-POS: "-e" "EntryPoint" "-s" "-u" "__undef"
61 // MISC-FLAGS-2-NEG: "{{.*}}msp430-elf-ld"
62 // MISC-FLAGS-2-NEG-NOT: "-r"
63 // MISC-FLAGS-2-NEG-NOT: "-t"
64 // MISC-FLAGS-2-NEG-NOT: "-z"
65 // MISC-FLAGS-2-NEG-NOT: "--relax"
67 // Tests for -nostdlib, -nostartfiles, -nodefaultfiles and -f(no-)exceptions
69 // RUN: %clang -### %s --target=msp430 -rtlib=libgcc \
70 // RUN: --sysroot="%S/Inputs/basic_msp430_tree" > %t 2>&1
71 // RUN: FileCheck -check-prefix=LIBS-DEFAULT-POS %s < %t
72 // RUN: FileCheck -check-prefix=LIBS-DEFAULT-NEG %s < %t
73 // RUN: %clang -### %s --target=msp430 -rtlib=libgcc \
74 // RUN: --gcc-toolchain="%S/Inputs/basic_msp430_tree" --sysroot="" 2>&1 \
75 // RUN: | FileCheck -check-prefix=LIBS-DEFAULT-GCC-TOOLCHAIN %s
76 // LIBS-DEFAULT-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/../../..{{/|\\\\}}..{{/|\\\\}}bin{{/|\\\\}}msp430-elf-ld"
77 // LIBS-DEFAULT-POS: "{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430{{/|\\\\}}crt0.o"
78 // LIBS-DEFAULT-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430{{/|\\\\}}crtbegin_no_eh.o"
79 // LIBS-DEFAULT-POS: "-L{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430"
80 // LIBS-DEFAULT-POS: "-L{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430"
81 // LIBS-DEFAULT-POS: "-lgcc" "--start-group" "-lmul_none" "-lc" "-lgcc" "-lcrt" "-lnosys" "--end-group" "-lgcc"
82 // LIBS-DEFAULT-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430{{/|\\\\}}crtend_no_eh.o" "-lgcc"
83 // LIBS-DEFAULT-GCC-TOOLCHAIN: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/../../..{{/|\\\\}}..{{/|\\\\}}bin{{/|\\\\}}msp430-elf-ld"
84 // LIBS-DEFAULT-GCC-TOOLCHAIN: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/../../..{{/|\\\\}}..{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430{{/|\\\\}}crt0.o"
85 // LIBS-DEFAULT-GCC-TOOLCHAIN: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430{{/|\\\\}}crtbegin_no_eh.o"
86 // LIBS-DEFAULT-GCC-TOOLCHAIN: "-L{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430"
87 // LIBS-DEFAULT-GCC-TOOLCHAIN: "-L{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/../../..{{/|\\\\}}..{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430"
88 // LIBS-DEFAULT-GCC-TOOLCHAIN: "-lgcc" "--start-group" "-lmul_none" "-lc" "-lgcc" "-lcrt" "-lnosys" "--end-group" "-lgcc"
89 // LIBS-DEFAULT-GCC-TOOLCHAIN: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430{{/|\\\\}}crtend_no_eh.o" "-lgcc"
90 // LIBS-DEFAULT-NEG-NOT: crtbegin.o
91 // LIBS-DEFAULT-NEG-NOT: -lssp_nonshared
92 // LIBS-DEFAULT-NEG-NOT: -lssp
93 // LIBS-DEFAULT-NEG-NOT: clang_rt
94 // LIBS-DEFAULT-NEG-NOT: crtend.o
95 // LIBS-DEFAULT-NEG-NOT: /exceptions
97 // RUN: %clang -### %s --target=msp430 -rtlib=compiler-rt \
98 // RUN: --sysroot="%S/Inputs/basic_msp430_tree" > %t 2>&1
99 // RUN: FileCheck -check-prefix=LIBS-COMPILER-RT-POS %s < %t
100 // RUN: FileCheck -check-prefix=LIBS-COMPILER-RT-NEG %s < %t
101 // LIBS-COMPILER-RT-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/../../..{{/|\\\\}}..{{/|\\\\}}bin{{/|\\\\}}msp430-elf-ld"
102 // LIBS-COMPILER-RT-POS: "{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430{{/|\\\\}}crt0.o"
103 // LIBS-COMPILER-RT-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430{{/|\\\\}}crtbegin_no_eh.o"
104 // LIBS-COMPILER-RT-POS: "-L{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430"
105 // LIBS-COMPILER-RT-POS: "-L{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430"
106 // LIBS-COMPILER-RT-POS: "{{[^"]*}}libclang_rt.builtins-msp430.a" "--start-group" "-lmul_none" "-lc" "{{[^"]*}}libclang_rt.builtins-msp430.a" "-lcrt" "-lnosys" "--end-group" "{{[^"]*}}libclang_rt.builtins-msp430.a"
107 // LIBS-COMPILER-RT-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430{{/|\\\\}}crtend_no_eh.o" "{{[^"]*}}libclang_rt.builtins-msp430.a"
108 // LIBS-COMPILER-RT-NEG-NOT: crtbegin.o
109 // LIBS-COMPILER-RT-NEG-NOT: -lssp_nonshared
110 // LIBS-COMPILER-RT-NEG-NOT: -lssp
111 // LIBS-COMPILER-RT-NEG-NOT: -lgcc
112 // LIBS-COMPILER-RT-NEG-NOT: crtend.o
113 // LIBS-COMPILER-RT-NEG-NOT: /exceptions
115 // RUN: %clang -### %s --target=msp430 -rtlib=libgcc -fexceptions \
116 // RUN: --sysroot="%S/Inputs/basic_msp430_tree" > %t 2>&1
117 // RUN: FileCheck -check-prefix=LIBS-EXC-POS %s < %t
118 // RUN: FileCheck -check-prefix=LIBS-EXC-NEG %s < %t
119 // LIBS-EXC-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/../../..{{/|\\\\}}..{{/|\\\\}}bin{{/|\\\\}}msp430-elf-ld"
120 // LIBS-EXC-POS: "{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430/exceptions{{/|\\\\}}crt0.o"
121 // LIBS-EXC-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430/exceptions{{/|\\\\}}crtbegin.o"
122 // LIBS-EXC-POS: "-L{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430/exceptions"
123 // LIBS-EXC-POS: "-L{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430/exceptions"
124 // LIBS-EXC-POS: "-lgcc" "--start-group" "-lmul_none" "-lc" "-lgcc" "-lcrt" "-lnosys" "--end-group"
125 // LIBS-EXC-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430/exceptions{{/|\\\\}}crtend.o" "-lgcc"
126 // LIBS-EXC-NEG-NOT: "{{.*}}/430"
127 // LIBS-EXC-NEG-NOT: "{{.*}}430/crt{{.*}}"
129 // RUN: %clang -### %s --target=msp430 -rtlib=libgcc \
130 // RUN: -fstack-protector --sysroot="%S/Inputs/basic_msp430_tree" 2>&1 \
131 // RUN: | FileCheck -check-prefix=LIBS-SSP %s
132 // LIBS-SSP: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/../../..{{/|\\\\}}..{{/|\\\\}}bin{{/|\\\\}}msp430-elf-ld"
133 // LIBS-SSP: "{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430{{/|\\\\}}crt0.o"
134 // LIBS-SSP: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430{{/|\\\\}}crtbegin_no_eh.o"
135 // LIBS-SSP: "-L{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430"
136 // LIBS-SSP: "-L{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430"
137 // LIBS-SSP: "-lssp_nonshared" "-lssp"
138 // LIBS-SSP: "-lgcc" "--start-group" "-lmul_none" "-lc" "-lgcc" "-lcrt" "-lnosys" "--end-group"
139 // LIBS-SSP: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430{{/|\\\\}}crtend_no_eh.o" "-lgcc"
141 // RUN: %clang -### %s --target=msp430 -rtlib=libgcc -nodefaultlibs \
142 // RUN: --sysroot="%S/Inputs/basic_msp430_tree" > %t 2>&1
143 // RUN: FileCheck -check-prefix=LIBS-NO-DFT-POS %s < %t
144 // RUN: FileCheck -check-prefix=LIBS-NO-DFT-NEG %s < %t
145 // LIBS-NO-DFT-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/../../..{{/|\\\\}}..{{/|\\\\}}bin{{/|\\\\}}msp430-elf-ld"
146 // LIBS-NO-DFT-POS: "{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430{{/|\\\\}}crt0.o"
147 // LIBS-NO-DFT-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430{{/|\\\\}}crtbegin_no_eh.o"
148 // LIBS-NO-DFT-POS: "-L{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430"
149 // LIBS-NO-DFT-POS: "-L{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430"
150 // LIBS-NO-DFT-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430{{/|\\\\}}crtend_no_eh.o" "-lgcc"
151 // LIBS-NO-DFT-NEG-NOT: "-lc"
152 // LIBS-NO-DFT-NEG-NOT: "-lcrt"
153 // LIBS-NO-DFT-NEG-NOT: "-lsim"
154 // LIBS-NO-DFT-NEG-NOT: "-lnosys"
155 // LIBS-NO-DFT-NEG-NOT: "--start-group"
156 // LIBS-NO-DFT-NEG-NOT: "--end-group"
158 // RUN: %clang -### %s --target=msp430 -rtlib=libgcc -nolibc \
159 // RUN: -fstack-protector --sysroot="%S/Inputs/basic_msp430_tree" > %t 2>&1
160 // RUN: FileCheck -check-prefix=LIBS-NO-LIBC-POS %s < %t
161 // RUN: FileCheck -check-prefix=LIBS-NO-LIBC-NEG %s < %t
162 // LIBS-NO-LIBC-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/../../..{{/|\\\\}}..{{/|\\\\}}bin{{/|\\\\}}msp430-elf-ld"
163 // LIBS-NO-LIBC-POS: "{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430{{/|\\\\}}crt0.o"
164 // LIBS-NO-LIBC-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430{{/|\\\\}}crtbegin_no_eh.o"
165 // LIBS-NO-LIBC-POS: "-L{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430"
166 // LIBS-NO-LIBC-POS: "-L{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430"
167 // LIBS-NO-LIBC-POS: "-lssp_nonshared" "-lssp" "-lgcc"
168 // LIBS-NO-LIBC-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430{{/|\\\\}}crtend_no_eh.o" "-lgcc"
169 // LIBS-NO-LIBC-NEG-NOT: "-lc"
170 // LIBS-NO-LIBC-NEG-NOT: "-lcrt"
171 // LIBS-NO-LIBC-NEG-NOT: "-lsim"
172 // LIBS-NO-LIBC-NEG-NOT: "-lnosys"
173 // LIBS-NO-LIBC-NEG-NOT: "--start-group"
174 // LIBS-NO-LIBC-NEG-NOT: "--end-group"
176 // RUN: %clang -### %s --target=msp430 -rtlib=libgcc -nostartfiles \
177 // RUN: --sysroot="%S/Inputs/basic_msp430_tree" > %t 2>&1
178 // RUN: FileCheck -check-prefix=LIBS-NO-START-POS %s < %t
179 // RUN: FileCheck -check-prefix=LIBS-NO-START-NEG %s < %t
180 // LIBS-NO-START-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/../../..{{/|\\\\}}..{{/|\\\\}}bin{{/|\\\\}}msp430-elf-ld"
181 // LIBS-NO-START-POS: "-L{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430"
182 // LIBS-NO-START-POS: "-L{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430"
183 // LIBS-NO-START-POS: "-lgcc" "--start-group" "-lmul_none" "-lc" "-lgcc" "-lcrt" "-lnosys" "--end-group"
184 // LIBS-NO-START-NEG-NOT: crt0.o
185 // LIBS-NO-START-NEG-NOT: crtbegin
186 // LIBS-NO-START-NEG-NOT: crtend
188 // RUN: %clang -### %s --target=msp430 -nostdlib \
189 // RUN: --sysroot="%S/Inputs/basic_msp430_tree" > %t 2>&1
190 // RUN: FileCheck -check-prefix=LIBS-NO-STD-POS %s < %t
191 // RUN: FileCheck -check-prefix=LIBS-NO-STD-NEG %s < %t
192 // LIBS-NO-STD-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/../../..{{/|\\\\}}..{{/|\\\\}}bin{{/|\\\\}}msp430-elf-ld"
193 // LIBS-NO-STD-POS: "-L{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430"
194 // LIBS-NO-STD-POS: "-L{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430"
195 // LIBS-NO-STD-NEG-NOT: crt0.o
196 // LIBS-NO-STD-NEG-NOT: crtbegin
197 // LIBS-NO-STD-NEG-NOT: crtend
198 // LIBS-NO-STD-NEG-NOT: "-lc"
199 // LIBS-NO-STD-NEG-NOT: "-lcrt"
200 // LIBS-NO-STD-NEG-NOT: "-lnosys"
201 // LIBS-NO-STD-NEG-NOT: "--start-group"
202 // LIBS-NO-STD-NEG-NOT: "--end-group"
204 // Test for linker script autodiscovery
206 // RUN: %clang -### %s --target=msp430 -mmcu=msp430g2553 \
207 // RUN: --sysroot=%S/Inputs/basic_msp430_tree 2>&1 \
208 // RUN: | FileCheck -check-prefix=LD-SCRIPT %s
209 // LD-SCRIPT: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/../../..{{/|\\\\}}..{{/|\\\\}}bin{{/|\\\\}}msp430-elf-ld"
210 // LD-SCRIPT: "-L{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}include"
211 // LD-SCRIPT: "-Tmsp430g2553.ld"
213 // RUN: %clang -### %s --target=msp430 -mmcu=msp430g2553 \
214 // RUN: --sysroot=%S/Inputs/basic_msp430_tree \
215 // RUN: -T custom_script.ld 2>&1 \
216 // RUN: | FileCheck -check-prefix=CUSTOM-LD-SCRIPT %s
217 // CUSTOM-LD-SCRIPT: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/../../..{{/|\\\\}}..{{/|\\\\}}bin{{/|\\\\}}msp430-elf-ld"
218 // CUSTOM-LD_SCRIPT-NOT: "-Tmsp430g2553.ld"
219 // CUSTOM-LD-SCRIPT: "-T" "custom_script.ld"
220 // CUSTOM-LD_SCRIPT-NOT: "-Tmsp430g2553.ld"
222 // Test for compiling for simulator
224 // RUN: %clang -### %s --target=msp430 -mmcu=msp430g2553 \
225 // RUN: -msim -rtlib=libgcc --sysroot=%S/Inputs/basic_msp430_tree > %t 2>&1
226 // RUN: FileCheck -check-prefix=SIMULATOR-POS %s < %t
227 // RUN: FileCheck -check-prefix=SIMULATOR-NEG %s < %t
228 // SIMULATOR-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/../../..{{/|\\\\}}..{{/|\\\\}}bin{{/|\\\\}}msp430-elf-ld"
229 // SIMULATOR-POS: "{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430{{/|\\\\}}crt0.o"
230 // SIMULATOR-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430{{/|\\\\}}crtbegin_no_eh.o"
231 // SIMULATOR-POS: "-L{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430"
232 // SIMULATOR-POS: "-L{{.*}}/Inputs/basic_msp430_tree{{/|\\\\}}msp430-elf{{/|\\\\}}lib/430"
233 // SIMULATOR-POS: "-lgcc" "--start-group" "-lmul_none" "-lc" "-lgcc" "-lcrt" "-lsim" "--undefined=__crt0_call_exit" "--end-group"
234 // SIMULATOR-POS: "-Tmsp430-sim.ld"
235 // SIMULATOR-POS: "{{.*}}/Inputs/basic_msp430_tree/lib/gcc/msp430-elf/8.3.1/430{{/|\\\\}}crtend_no_eh.o" "-lgcc"
236 // SIMULATOR-NEG-NOT: "-lnosys"
240 // RUN: %clang -### %s --target=msp430 -mmcu=msp430f147 --sysroot="" 2>&1 \
241 // RUN: | FileCheck -check-prefix=HWMult-16BIT %s
242 // RUN: %clang -### %s --target=msp430 -mmcu=msp430f147 -mhwmult=auto --sysroot="" 2>&1 \
243 // RUN: | FileCheck -check-prefix=HWMult-16BIT %s
244 // RUN: %clang -### %s --target=msp430 -mhwmult=16bit --sysroot="" 2>&1 \
245 // RUN: | FileCheck -check-prefix=HWMult-16BIT %s
246 // HWMult-16BIT: "--start-group" "-lmul_16"
248 // RUN: %clang -### %s --target=msp430 -mmcu=msp430f4783 --sysroot="" 2>&1 \
249 // RUN: | FileCheck -check-prefix=HWMult-32BIT %s
250 // RUN: %clang -### %s --target=msp430 -mmcu=msp430f4783 -mhwmult=auto --sysroot="" 2>&1 \
251 // RUN: | FileCheck -check-prefix=HWMult-32BIT %s
252 // RUN: %clang -### %s --target=msp430 -mhwmult=32bit --sysroot="" 2>&1 \
253 // RUN: | FileCheck -check-prefix=HWMult-32BIT %s
254 // HWMult-32BIT: "--start-group" "-lmul_32"
256 // RUN: %clang -### %s --target=msp430 -mhwmult=f5series --sysroot="" 2>&1 \
257 // RUN: | FileCheck -check-prefix=HWMult-F5 %s
258 // HWMult-F5: "--start-group" "-lmul_f5"
260 // RUN: %clang -### %s --target=msp430 -mhwmult=none --sysroot="" 2>&1 \
261 // RUN: | FileCheck -check-prefix=HWMult-NONE %s
262 // RUN: %clang -### %s --target=msp430 -mhwmult=none -mmcu=msp430f4783 --sysroot="" 2>&1 \
263 // RUN: | FileCheck -check-prefix=HWMult-NONE %s
264 // HWMult-NONE: "--start-group" "-lmul_none"