[NFC][RISCV] Remove CFIIndex argument from allocateStack (#117871)
[llvm-project.git] / clang / test / Driver / Ofast.c
blobb5189e951cc68f0fba27ed6f0e9f4335e92e296a
1 // RUN: %clang -c -Ofast -### %s 2>&1 | FileCheck -check-prefix=CHECK-OFAST %s
2 // RUN: %clang -c -O2 -Ofast -### %s 2>&1 | FileCheck -check-prefix=CHECK-OFAST %s
3 // RUN: %clang -c -fno-fast-math -Ofast -### %s 2>&1 | FileCheck -check-prefix=CHECK-OFAST %s
4 // RUN: %clang -c -fno-strict-aliasing -Ofast -### %s 2>&1 | FileCheck -check-prefix=CHECK-OFAST %s
5 // RUN: %clang -c -fno-vectorize -Ofast -### %s 2>&1 | FileCheck -check-prefix=CHECK-OFAST %s
6 // RUN: %clang -c -Ofast -O2 -### -Werror %s 2>&1 | FileCheck -check-prefix=CHECK-OFAST-O2 \
7 // RUN: %if target={{.*-windows-msvc.*}} %{ --check-prefix=CHECK-OFAST-O2-ALIASING-MSVC %} \
8 // RUN: %else %{ --check-prefix=CHECK-OFAST-O2-ALIASING %} %s
9 // RUN: %clang -c -Ofast -fno-fast-math -### %s 2>&1 | FileCheck -check-prefix=CHECK-OFAST-NO-FAST-MATH %s
10 // RUN: %clang -c -Ofast -fno-strict-aliasing -### %s 2>&1 | FileCheck -check-prefix=CHECK-OFAST-NO-STRICT-ALIASING %s
11 // RUN: %clang -c -Ofast -fno-vectorize -### %s 2>&1 | FileCheck -check-prefix=CHECK-OFAST-NO-VECTORIZE %s
13 // CHECK-OFAST: use '-O3 -ffast-math' for the same behavior, or '-O3' to enable only conforming optimizations
14 // CHECK-OFAST: -cc1
15 // CHECK-OFAST-NOT: -relaxed-aliasing
16 // CHECK-OFAST: -ffast-math
17 // CHECK-OFAST: -Ofast
18 // CHECK-OFAST: -vectorize-loops
20 // Lack of warning about '-Ofast' deprecation is checked via -Werror
21 // CHECK-OFAST-O2: -cc1
22 // CHECK-OFAST-O2-ALIASING-NOT: -relaxed-aliasing
23 // CHECK-OFAST-O2-ALIASING-MSVC: -relaxed-aliasing
24 // CHECK-OFAST-O2-NOT: -ffast-math
25 // CHECK-OFAST-O2-NOT: -Ofast
26 // CHECK-OFAST-O2: -vectorize-loops
28 // CHECK-OFAST-NO-FAST-MATH: use '-O3 -ffast-math' for the same behavior, or '-O3' to enable only conforming optimizations
29 // CHECK-OFAST-NO-FAST-MATH: -cc1
30 // CHECK-OFAST-NO-FAST-MATH-NOT: -relaxed-aliasing
31 // CHECK-OFAST-NO-FAST-MATH-NOT: -ffast-math
32 // CHECK-OFAST-NO-FAST-MATH: -Ofast
33 // CHECK-OFAST-NO-FAST-MATH: -vectorize-loops
35 // CHECK-OFAST-NO-STRICT-ALIASING: use '-O3 -ffast-math' for the same behavior, or '-O3' to enable only conforming optimizations
36 // CHECK-OFAST-NO-STRICT-ALIASING: -cc1
37 // CHECK-OFAST-NO-STRICT-ALIASING: -relaxed-aliasing
38 // CHECK-OFAST-NO-STRICT-ALIASING: -ffast-math
39 // CHECK-OFAST-NO-STRICT-ALIASING: -Ofast
40 // CHECK-OFAST-NO-STRICT-ALIASING: -vectorize-loops
42 // CHECK-OFAST-NO-VECTORIZE: use '-O3 -ffast-math' for the same behavior, or '-O3' to enable only conforming optimizations
43 // CHECK-OFAST-NO-VECTORIZE: -cc1
44 // CHECK-OFAST-NO-VECTORIZE-NOT: -relaxed-aliasing
45 // CHECK-OFAST-NO-VECTORIZE: -ffast-math
46 // CHECK-OFAST-NO-VECTORIZE: -Ofast
47 // CHECK-OFAST-NO-VECTORIZE-NOT: -vectorize-loops