1 ; RUN: opt < %s -mtriple=x86_64-unknown-unknown -S -inline | FileCheck %s
3 define i32 @func_target_cpu_base() #0 {
7 ; CHECK-LABEL: @target_cpu_k8_call_target_cpu_base(
8 ; CHECK-NEXT: ret i32 0
9 define i32 @target_cpu_k8_call_target_cpu_base() #1 {
10 %call = call i32 @func_target_cpu_base()
14 ; CHECK-LABEL: @target_cpu_target_nehalem_call_target_cpu_base(
15 ; CHECK-NEXT: ret i32 0
16 define i32 @target_cpu_target_nehalem_call_target_cpu_base() #2 {
17 %call = call i32 @func_target_cpu_base()
21 ; CHECK-LABEL: @target_cpu_target_goldmont_call_target_cpu_base(
22 ; CHECK-NEXT: ret i32 0
23 define i32 @target_cpu_target_goldmont_call_target_cpu_base() #3 {
24 %call = call i32 @func_target_cpu_base()
28 define i32 @func_target_cpu_nocona() #4 {
32 ; CHECK-LABEL: @target_cpu_target_base_call_target_cpu_nocona(
33 ; CHECK-NEXT: ret i32 0
34 define i32 @target_cpu_target_base_call_target_cpu_nocona() #0 {
35 %call = call i32 @func_target_cpu_nocona()
39 attributes #0 = { nounwind "target-cpu"="x86-64" }
40 attributes #1 = { nounwind "target-cpu"="k8" }
41 attributes #2 = { nounwind "target-cpu"="nehalem" }
42 attributes #3 = { nounwind "target-cpu"="goldmont" }
43 attributes #4 = { nounwind "target-cpu"="nocona" "target-features"="-sse3" }