This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/20493] [4.0 Regression] Bootstrap failure
- From: "dave at hiauly1 dot hia dot nrc dot ca" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 16 Mar 2005 14:34:44 -0000
- Subject: [Bug middle-end/20493] [4.0 Regression] Bootstrap failure
- References: <20050316054704.20493.danglin@gcc.gnu.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From dave at hiauly1 dot hia dot nrc dot ca 2005-03-16 14:34 -------
Subject: Re: [4.0 Regression] Bootstrap failure
> ------- Additional Comments From pinskia at gcc dot gnu dot org 2005-03-16 06:26 -------
> The following code is another example:
> typedef int (*fptr_t) (void);
>
> int __canonicalize_funcptr_for_compare (fptr_t t)
> {
> return (int)(t) == -1;
> }
>
> Hmm, I have not traced it yet but maybe we should not call __canonicalize_funcptr_for_compare when
> we are comparing against constants.
Well certainly when the function pointer has been cast to an int.
In PR middle-end/17564, we changed do_compare_and_jump to only
canonicalize function pointers in a comparison if both sides are
function pointers.
Dave
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20493