|
1 | 1 | ! REQUIRES: amdgpu-registered-target
|
2 |
| -! RUN: %flang_fc1 -emit-fir %s -o - | FileCheck %s --check-prefixes=ALL,NONE |
3 |
| -! RUN: %flang_fc1 -emit-fir -triple amdgcn-amd-amdhsa %s -o - | FileCheck %s --check-prefixes=ALL,TRIPLE |
4 |
| -! RUN: %flang_fc1 -emit-fir -target-cpu gfx90a %s -o - | FileCheck %s --check-prefixes=ALL,CPU |
5 |
| -! RUN: %flang_fc1 -emit-fir -triple amdgcn-amd-amdhsa -target-cpu gfx90a %s -o - | FileCheck %s --check-prefixes=ALL,BOTH |
| 2 | +! RUN: %flang_fc1 -emit-fir -triple amdgcn-amd-amdhsa -target-cpu gfx90a %s -o - | FileCheck %s --check-prefixes=ALL,CPU |
| 3 | +! RUN: %flang_fc1 -emit-fir -triple amdgcn-amd-amdhsa -target-feature +sse %s -o - | FileCheck %s --check-prefixes=ALL,FEATURE |
| 4 | +! RUN: %flang_fc1 -emit-fir -triple amdgcn-amd-amdhsa -target-cpu gfx90a -target-feature +sse %s -o - | FileCheck %s --check-prefixes=ALL,BOTH |
6 | 5 |
|
7 | 6 | ! ALL: module attributes {
|
8 | 7 |
|
9 |
| -! NONE-NOT: fir.target_cpu |
10 |
| -! NONE-NOT: fir.target_features |
11 |
| - |
12 |
| -! TRIPLE-SAME: fir.target_cpu = "generic-hsa" |
13 |
| -! TRIPLE-NOT: fir.target_features |
14 |
| - |
15 | 8 | ! CPU-SAME: fir.target_cpu = "gfx90a"
|
16 |
| -! CPU-NOT: fir.target_features |
| 9 | +! CPU-SAME: fir.target_features = #llvm.target_features<[ |
| 10 | +! CPU-SAME: "+gfx90a-insts" |
| 11 | +! CPU-SAME: ]> |
| 12 | + |
| 13 | +! FEATURE-SAME: fir.target_features = #llvm.target_features<[ |
| 14 | +! FEATURE-NOT: "+gfx90a-insts" |
| 15 | +! FEATURE-SAME: "+sse" |
| 16 | +! FEATURE-SAME: ]> |
17 | 17 |
|
18 | 18 | ! BOTH-SAME: fir.target_cpu = "gfx90a"
|
19 | 19 | ! BOTH-SAME: fir.target_features = #llvm.target_features<[
|
20 | 20 | ! BOTH-SAME: "+gfx90a-insts"
|
| 21 | +! BOTH-SAME: "+sse" |
21 | 22 | ! BOTH-SAME: ]>
|
0 commit comments