Skip to content

Commit

Permalink
[SWDEV-487764] Revert "[Clang] [Driver] Ensure -fms-volatile is set…
Browse files Browse the repository at this point in the history
… for x86 for `*-windows-msvc` triple on non cl driver modes (llvm#107509)"

This reverts commit 64aaf05.

Change-Id: I57c96e778c8929e36b451d2742b0914e7dcfda94
  • Loading branch information
jofrn authored and kzhuravl committed Oct 9, 2024
1 parent 39e50d1 commit 921e0df
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 5 deletions.
2 changes: 1 addition & 1 deletion clang/lib/Driver/ToolChains/Clang.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6100,7 +6100,7 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA,
}

if (Args.hasFlag(options::OPT_fms_volatile, options::OPT_fno_ms_volatile,
Triple.isX86() && IsWindowsMSVC))
Triple.isX86() && D.IsCLMode()))
CmdArgs.push_back("-fms-volatile");

// Non-PIC code defaults to -fdirect-access-external-data while PIC code
Expand Down
4 changes: 0 additions & 4 deletions clang/test/Driver/clang_f_opts.c
Original file line number Diff line number Diff line change
Expand Up @@ -623,10 +623,6 @@
// RUN: %clang -### --target=aarch64-windows-msvc %s 2>&1 | FileCheck -check-prefix=CHECK-NO-MS-VOLATILE %s
// RUN: %clang -### --target=aarch64-windows-msvc -fms-volatile %s 2>&1 | FileCheck -check-prefix=CHECK-MS-VOLATILE %s
// RUN: %clang -### --target=aarch64-windows-msvc -fno-ms-volatile %s 2>&1 | FileCheck -check-prefix=CHECK-NO-MS-VOLATILE %s
// RUN: %clang -### --target=x86_64-windows-msvc %s 2>&1 | FileCheck -check-prefix=CHECK-MS-VOLATILE %s
// RUN: %clang -### --target=x86_64-windows-msvc -fno-ms-volatile %s 2>&1 | FileCheck -check-prefix=CHECK-NO-MS-VOLATILE %s
// RUN: %clang -### --target=i686-windows-msvc %s 2>&1 | FileCheck -check-prefix=CHECK-MS-VOLATILE %s
// RUN: %clang -### --target=i686-windows-msvc -fno-ms-volatile %s 2>&1 | FileCheck -check-prefix=CHECK-NO-MS-VOLATILE %s
// CHECK-MS-VOLATILE: -fms-volatile
// CHECK-NO-MS-VOLATILE-NOT: -fms-volatile

Expand Down

0 comments on commit 921e0df

Please sign in to comment.