[Bug middle-end/20493] [4.0/4.1 Regression] Bootstrap failure because of aliased symbols
roger at eyesopen dot com
gcc-bugzilla@gcc.gnu.org
Thu Mar 17 05:08:00 GMT 2005
------- Additional Comments From roger at eyesopen dot com 2005-03-17 05:06 -------
Hmm, yep, probably caused by my change.
It looks like with my change fold_widened_comparison is now converting
(int)t == -1 into the equivalent t == (typeof(t))-1. Normally, this
would be reasonable but the "special" semantics of
HAVE_canonical_funcptr_for_compare clearly screw this up.
My suggestion would be to add the following to the top of the subroutine
fold_widened_comparison:
#ifdef HAVE_canonicalize_funcptr_for_compare
/* Disable this optimization if we're casting to a function pointer
type on targets that require function pointer canonicalization. */
if (HAVE_canonicalize_funcptr_for_compare
&& TREE_CODE (shorter_type) == POINTER_TYPE
&& TREE_CODE (TREE_TYPE (shorter_type)) == FUNCTION_TYPE)
return NULL_TREE;
#endif
Dave, could you give this a try and see if it restores bootstrap for you?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20493
More information about the Gcc-bugs
mailing list