Consider building without Wno-ignored-pragma-optimize. |
|
Issue descriptionclang-cl ignores #pragma optimize and emits Wignored-pragma-optimize. We currently suppress that. https://bugs.chromium.org/p/chromium/issues/detail?id=505314#c5 https://bugs.chromium.org/p/chromium/issues/detail?id=505314#c7 https://bugs.chromium.org/p/chromium/issues/detail?id=505314#c24 characterize what we use the pragma for currently. Depending on how much work we want to put into this, we could add a "dont_icf" attribute and plumb that through to lld, or we could just use MSVC_ENABLE_OPTIMIZE() everywhere we use that pragma, and then make that a no-op in clang builds. brucedawson's asked about this every now and then, so here's a dedicated bug for it :-0
,
Jan 10
crbug.com/891075 explains why this isn't practical at the moment and may never be worthwhile. midl generated files, tcmalloc, sqlite, and a few others (including third_party\llvm\lib\ExecutionEngine\IntelJITEvents\jitprofiling.c) all use the VC++ pragma - about twenty or so from a search for pragma.*optimize.*"", off. None of the remaining uses look worrisome. |
|
►
Sign in to add a comment |
|
Comment 1 by brucedaw...@chromium.org
, Dec 7Status: Assigned (was: Untriaged)