[PATCH] D59509: Make static constructors + destructors minsize + cold (except for in -O0)

2019-04-22 Thread Jessica Paquette via Phabricator via cfe-commits
paquette updated this revision to Diff 196085. paquette added a comment. Made the test less fragile by splitting the WITHOUT-NOT into three lines. (Thanks for the suggestion!) CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59509/new/ https://reviews.llvm.org/D59509 Files:

[PATCH] D59509: Make static constructors + destructors minsize + cold (except for in -O0)

2019-04-08 Thread James Y Knight via Phabricator via cfe-commits
jyknight added a comment. Looks reasonable to me. Comment at: clang/test/CodeGen/static-attr.cpp:4 + +// WITHOUT-NOT: cold minsize noinline +// WITH: define internal void @__cxx_global_var_init() [[ATTR:#[0-9]]] lebedev.ri wrote: > This is fragile, it may have

[PATCH] D59509: Make static constructors + destructors minsize + cold (except for in -O0)

2019-03-18 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang/test/CodeGen/static-attr.cpp:4 + +// WITHOUT-NOT: cold minsize noinline +// WITH: define internal void @__cxx_global_var_init() [[ATTR:#[0-9]]] This is fragile, it may have false-negative if they appear in

[PATCH] D59509: Make static constructors + destructors minsize + cold (except for in -O0)

2019-03-18 Thread Jessica Paquette via Phabricator via cfe-commits
paquette created this revision. paquette added reviewers: rsmith, jyknight. Herald added a project: clang. Since these are only ever run once, they can be marked as cold. On top of that, since they're only ever run once, they might as well be minsize. I observed a 0.21% code size improvement in