Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(462)

Issue 2029633002: mac: Use -fstack-protector-strong instead of -fstack-protector-all. (Closed)

Created:
4 years, 6 months ago by Nico
Modified:
4 years, 6 months ago
CC:
chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

mac: Use -fstack-protector-strong instead of -fstack-protector-all. This should reduce binary size quite a bit, without less security. We currently use different -fstack-protector flags on different platforms, and I think -fstack-protector-strong is where we eventually want all platforms to be. Chrome OS has been using that flag for a long time already. Linux will use it eventually (see bug linked to in the comment I'm adding here.) clang-cl is very likely going to hook up /GS to -fstack-protector-strong. BUG=none Committed: https://crrev.com/53b9133ec5956418541ae10e40547558ae70b387 Cr-Commit-Position: refs/heads/master@{#397174}

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+4 lines, -3 lines) Patch
M build/common.gypi View 2 chunks +2 lines, -2 lines 0 comments Download
M build/config/compiler/BUILD.gn View 1 chunk +2 lines, -1 line 0 comments Download

Messages

Total messages: 11 (4 generated)
Nico
4 years, 6 months ago (2016-06-01 16:11:12 UTC) #2
Mark Mentovai
LGTM
4 years, 6 months ago (2016-06-01 16:40:39 UTC) #3
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2029633002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/2029633002/1
4 years, 6 months ago (2016-06-01 16:44:44 UTC) #5
commit-bot: I haz the power
Committed patchset #1 (id:1)
4 years, 6 months ago (2016-06-01 17:53:09 UTC) #6
commit-bot: I haz the power
Patchset 1 (id:??) landed as https://crrev.com/53b9133ec5956418541ae10e40547558ae70b387 Cr-Commit-Position: refs/heads/master@{#397174}
4 years, 6 months ago (2016-06-01 17:56:06 UTC) #8
Nico
I was wondering why this didn't change the size of the final binary (https://build.chromium.org/p/chromium.chrome/builders/Google%20Chrome%20Mac/builds/10806) – ...
4 years, 6 months ago (2016-06-01 19:15:23 UTC) #10
Robert Sesek
4 years, 6 months ago (2016-06-10 20:41:15 UTC) #11
Message was sent while issue was closed.
On 2016/06/01 19:15:23, Nico (traveling...slow) wrote:
> I was wondering why this didn't change the size of the final binary
>
(https://build.chromium.org/p/chromium.chrome/builders/Google%20Chrome%20Mac/b...)
> – looks like we only pass this for debug builds on os x, but we do pass it for
> release builds too in the gn build. So this should reduce the size of the
final
> binary in the gn build, but this also means the gn binary will be larger
(since
> it builds with stack protector on but gyp doesn't – and the default is
> -fstack-protector, which is smaller than -fstack-protector-strong).

Switching from -fstack-protector-strong to just -fstack-protector in the GN
official build gets the size compared to GYP just about the same (100 kb delta,
gn being larger).

Powered by Google App Engine
This is Rietveld 408576698