Craig Topper | 9a724aa | 2017-12-11 21:09:19 +0000 | [diff] [blame] | 1 | // RUN: %clang_cc1 -mprefer-vector-width=128 -emit-llvm %s -o - | FileCheck %s --check-prefix=CHECK128 |
| 2 | // RUN: %clang_cc1 -mprefer-vector-width=256 -emit-llvm %s -o - | FileCheck %s --check-prefix=CHECK256 |
| 3 | // RUN: %clang_cc1 -mprefer-vector-width=none -emit-llvm %s -o - | FileCheck %s --check-prefix=CHECKNONE |
| 4 | |
| 5 | int baz(int a) { return 4; } |
| 6 | |
| 7 | // CHECK128: baz{{.*}} #0 |
| 8 | // CHECK128: #0 = {{.*}}"prefer-vector-width"="128" |
| 9 | |
| 10 | // CHECK256: baz{{.*}} #0 |
| 11 | // CHECK256: #0 = {{.*}}"prefer-vector-width"="256" |
| 12 | |
| 13 | // CHECKNONE: baz{{.*}} #0 |
| 14 | // CHECKNONE-NOT: #0 = {{.*}}"prefer-vector-width"="none" |