1 // This test makes sure that functions get annotated with the proper
2 // "target-cpu" attribute in LLVM.
5 // ignore-tidy-linelength
6 // compile-flags: -C no-prepopulate-passes -C panic=abort -C linker-plugin-lto -Cpasses=name-anon-globals
8 #![crate_type = "staticlib"]
10 // CHECK-LABEL: define {{.*}} @exported() {{.*}} #0
12 pub extern fn exported() {
16 // CHECK-LABEL: define {{.*}} @_ZN23target_cpu_on_functions12not_exported{{.*}}() {{.*}} #0
19 // CHECK: attributes #0 = {{.*}} "target-cpu"="{{.*}}"