This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/20493] [4.0/4.1 Regression] Bootstrap failure because of aliased symbols
- From: "roger at eyesopen dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 17 Mar 2005 05:07:05 -0000
- Subject: [Bug middle-end/20493] [4.0/4.1 Regression] Bootstrap failure because of aliased symbols
- References: <20050316054704.20493.danglin@gcc.gnu.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- 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