Bug 212244

Summary: Various compile-time boolean flags could/should be marked constexpr
Product: WebKit Reporter: Robin Morisset <rmorisset>
Component: JavaScriptCoreAssignee: Robin Morisset <rmorisset>
Status: RESOLVED FIXED    
Severity: Normal CC: benjamin, cdumez, cmarcelo, ews-watchlist, keith_miller, mark.lam, msaboff, saam, tzagallo, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch none

Robin Morisset
Reported 2020-05-21 17:54:18 PDT
Lots of files in JSC have a bool verbose = false; at the top, that we can flip to true when we want to debug things. These should all be constexpr, to help the compiler eliminate all of the code that branches on these flags. I checked, and this patch reduces binary size by roughly 16kB.
Attachments
Patch (7.62 KB, patch)
2020-05-21 17:56 PDT, Robin Morisset
no flags
Robin Morisset
Comment 1 2020-05-21 17:56:54 PDT
Mark Lam
Comment 2 2020-05-21 19:02:54 PDT
Comment on attachment 400007 [details] Patch r=me
EWS
Comment 3 2020-05-21 19:17:58 PDT
Committed r262040: <https://trac.webkit.org/changeset/262040> All reviewed patches have been landed. Closing bug and clearing flags on attachment 400007 [details].
Radar WebKit Bug Importer
Comment 4 2020-05-21 19:18:12 PDT
Note You need to log in before you can comment on or make changes to this bug.