Page MenuHomePhabricator

Disable the strict-aliasing warnings produced by gcc
ClosedPublic

Authored by tberghammer on Oct 22 2015, 5:28 AM.

Details

Summary

Disable the strict-aliasing warnings produced by gcc

GCC produce a lot of strict-aliasing warning for the LLDB codebase
what makes reading the compile output very difficult. This change
disable these warnings to reduce the noise as we already ignore them.

We should consider re-enabling the warning if we fix all (or most)
strict-aliasing violation first.

Event Timeline

tberghammer retitled this revision from to Disable the strict-aliasing warnings produced by gcc.
tberghammer updated this object.
tberghammer added reviewers: clayborg, brucem.
tberghammer added a subscriber: lldb-commits.
labath added a subscriber: labath.Oct 22 2015, 5:47 AM

Could you also file a bug about that? most of these are real problems I think, and we should not forget them...

brucem edited edge metadata.Oct 22 2015, 5:50 AM

It might be worthwhile to have a "janitor" where we can not enable things like this so that it is more clear that this is something we'd like to clean up over time.

It would be pretty easy to just have a if (NOT LLDB_JANITOR_MODE AND CXX_SUPPORTS_NO_STRICT_ALIASING) check probably, but then we'd need docs to discuss LLDB_JANITOR_MODE.

Don't know.

clayborg accepted this revision.Oct 22 2015, 9:31 AM
clayborg edited edge metadata.
This revision is now accepted and ready to land.Oct 22 2015, 9:31 AM

I created a bug for it as https://llvm.org/bugs/show_bug.cgi?id=25296

I don't see too much value in creating a "janitor" mode because I think when people want to do some cleanup, they will focus on one specific area where they enable the necessary warnings manually. Enabling the "janitor" mode will most likely create too much noise at once to handle it especially if we hide more and more "feature" behind it over the time

This revision was automatically updated to reflect the committed changes.