diff --git a/clang/test/Driver/clang_f_opts.c b/clang/test/Driver/clang_f_opts.c index bda026715c36..180d4713dcb4 100644 --- a/clang/test/Driver/clang_f_opts.c +++ b/clang/test/Driver/clang_f_opts.c @@ -304,7 +304,6 @@ // RUN: -fno-inline-small-functions -finline-small-functions \ // RUN: -fno-fat-lto-objects -ffat-lto-objects \ // RUN: -fno-merge-constants -fmerge-constants \ -// RUN: -fno-merge-all-constants -fmerge-all-constants \ // RUN: -fno-caller-saves -fcaller-saves \ // RUN: -fno-reorder-blocks -freorder-blocks \ // RUN: -fno-schedule-insns2 -fschedule-insns2 \ @@ -544,13 +543,6 @@ // CHECK-DISCARD-NAMES: "-discard-value-names" // CHECK-NO-DISCARD-NAMES-NOT: "-discard-value-names" -// RUN: %clang -### -S -fmerge-all-constants %s 2>&1 | FileCheck -check-prefix=CHECK-MERGE-ALL-CONSTANTS %s -// RUN: %clang -### -S -fno-merge-all-constants %s 2>&1 | FileCheck -check-prefix=CHECK-NO-MERGE-ALL-CONSTANTS %s -// RUN: %clang -### -S -fmerge-all-constants -fno-merge-all-constants %s 2>&1 | FileCheck -check-prefix=CHECK-NO-MERGE-ALL-CONSTANTS %s -// RUN: %clang -### -S -fno-merge-all-constants -fmerge-all-constants %s 2>&1 | FileCheck -check-prefix=CHECK-MERGE-ALL-CONSTANTS %s -// CHECK-NO-MERGE-ALL-CONSTANTS-NOT: "-fmerge-all-constants" -// CHECK-MERGE-ALL-CONSTANTS: "-fmerge-all-constants" - // RUN: %clang -### -S -fdelete-null-pointer-checks %s 2>&1 | FileCheck -check-prefix=CHECK-NULL-POINTER-CHECKS %s // RUN: %clang -### -S -fno-delete-null-pointer-checks %s 2>&1 | FileCheck -check-prefix=CHECK-NO-NULL-POINTER-CHECKS %s // RUN: %clang -### -S -fdelete-null-pointer-checks -fno-delete-null-pointer-checks %s 2>&1 | FileCheck -check-prefix=CHECK-NO-NULL-POINTER-CHECKS %s diff --git a/clang/test/Driver/fmerge-constants.c b/clang/test/Driver/fmerge-constants.c new file mode 100644 index 000000000000..c478a9d7b1e5 --- /dev/null +++ b/clang/test/Driver/fmerge-constants.c @@ -0,0 +1,6 @@ +// RUN: %clang -### -c %s -fno-merge-all-constants -fmerge-all-constants 2>&1 | FileCheck %s +// CHECK: "-fmerge-all-constants" + +// RUN: %clang -### -c %s 2>&1 | FileCheck --check-prefix=NO %s +// RUN: %clang -### -c %s -fmerge-all-constants -fno-merge-all-constants 2>&1 | FileCheck --check-prefix=NO %s +// NO-NOT: "-fmerge-all-constants"