This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
encoding all aliases options in .opt files
- From: Manuel López-Ibáñez <lopezibanez at gmail dot com>
- To: Joseph Myers <jsm at polyomino dot org dot uk>
- Cc: gcc at gnu dot org
- Date: Fri, 12 Oct 2012 08:57:32 +0200
- Subject: encoding all aliases options in .opt files
Hi Joseph,
I am trying to encode the relationship between Wstrict-aliasing and
Wstrict-aliasing= in the .opt files, and the same for Wstrict-overflow
and Wstrict-overflow=. However, the parameters of Alias() are taken as
strings, so we get "3" and "WARN_STRICT_OVERFLOW_CONDITIONAL". Do you
have a suggestion how to handle this?
My next step would be to handle aliases also when internally
generating options, so I can add EnabledBy(Wall) to Wstrict-aliasing.
Does this sound ok to you?
Cheers,
Manuel.
Wstrict-aliasing
-Common Warning
+Common Alias(Wstrict-aliasing=, 3, 0)
Warn about code which might break strict aliasing rules
Wstrict-aliasing=
Common Joined RejectNegative UInteger Var(warn_strict_aliasing)
Init(-1) Warning
Warn about code which might break strict aliasing rules
Wstrict-overflow
-Common Warning
+Common Alias(Wstrict-overflow=, WARN_STRICT_OVERFLOW_CONDITIONAL, 0)
Warn about optimizations that assume that signed overflow is undefined