Skip to content

Commit 8854d12

Browse files
committed
[PS5] Disable exceptions by default
1 parent f9f2276 commit 8854d12

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

clang/lib/Driver/ToolChains/Clang.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -459,9 +459,9 @@ static bool addExceptionArgs(const ArgList &Args, types::ID InputType,
459459
}
460460

461461
if (types::isCXX(InputType)) {
462-
// Disable C++ EH by default on XCore and PS4.
462+
// Disable C++ EH by default on XCore and PS4/PS5.
463463
bool CXXExceptionsEnabled =
464-
Triple.getArch() != llvm::Triple::xcore && !Triple.isPS4();
464+
Triple.getArch() != llvm::Triple::xcore && !Triple.isPS();
465465
Arg *ExceptionArg = Args.getLastArg(
466466
options::OPT_fcxx_exceptions, options::OPT_fno_cxx_exceptions,
467467
options::OPT_fexceptions, options::OPT_fno_exceptions);

clang/test/Driver/clang-exception-flags.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,5 +24,6 @@
2424
// RUN: %clang -### -fexceptions -fno-cxx-exceptions %s 2>&1 | FileCheck %s -check-prefix=OFF4
2525
// OFF4-NOT: "-cc1" {{.*}} "-fcxx-exceptions"
2626
//
27-
// RUN: %clang -### -target x86_64-scei-ps4 %s 2>&1 | FileCheck %s -check-prefix=PS4-OFF
28-
// PS4-OFF-NOT: "-cc1" {{.*}} "-f{{(cxx-)?}}exceptions"
27+
// RUN: %clang -### -target x86_64-scei-ps4 %s 2>&1 | FileCheck %s -check-prefix=PS-OFF
28+
// RUN: %clang -### -target x86_64-sie-ps5 %s 2>&1 | FileCheck %s -check-prefix=PS-OFF
29+
// PS-OFF-NOT: "-cc1" {{.*}} "-f{{(cxx-)?}}exceptions"

0 commit comments

Comments
 (0)