[PATCH] D130493: Disable stack-sizes section by default for PS4.

Ying Yi via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jul 25 08:47:14 PDT 2022


MaggieYi created this revision.
MaggieYi added reviewers: probinson, wristow.
Herald added a project: All.
MaggieYi requested review of this revision.
Herald added subscribers: cfe-commits, MaskRay.
Herald added a project: clang.

Change Clang's default so that -fstack-size-section is no longer enabled by default for PS4.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D130493

Files:
  clang/lib/Driver/ToolChains/Clang.cpp
  clang/test/Driver/stack-size-section.c


Index: clang/test/Driver/stack-size-section.c
===================================================================
--- clang/test/Driver/stack-size-section.c
+++ clang/test/Driver/stack-size-section.c
@@ -4,7 +4,7 @@
 // CHECK-ABSENT-NOT: -fstack-size-section
 
 // RUN: %clang -target x86_64-unknown -fstack-size-section -### 2>&1 | FileCheck %s --check-prefix=CHECK-PRESENT
-// RUN: %clang -target x86_64-scei-ps4 %s -### 2>&1 | FileCheck %s --check-prefix=CHECK-PRESENT
+// RUN: %clang -target x86_64-scei-ps4 %s -### 2>&1 | FileCheck %s --check-prefix=CHECK-ABSENT
 // CHECK-PRESENT: -fstack-size-section
 
 // RUN: %clang -target x86_64-unknown -fstack-size-section -fno-stack-size-section %s -### 2>&1 \
Index: clang/lib/Driver/ToolChains/Clang.cpp
===================================================================
--- clang/lib/Driver/ToolChains/Clang.cpp
+++ clang/lib/Driver/ToolChains/Clang.cpp
@@ -5880,7 +5880,7 @@
   }
 
   if (Args.hasFlag(options::OPT_fstack_size_section,
-                   options::OPT_fno_stack_size_section, RawTriple.isPS4()))
+                   options::OPT_fno_stack_size_section, false))
     CmdArgs.push_back("-fstack-size-section");
 
   if (Args.hasArg(options::OPT_fstack_usage)) {


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D130493.447356.patch
Type: text/x-patch
Size: 1230 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20220725/8113b3db/attachment.bin>


More information about the cfe-commits mailing list