This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/49963] [4.7 Regression] ICE: in abs_hwi, at hwint.c:108
- From: "gjl at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 8 Aug 2011 08:29:58 +0000
- Subject: [Bug tree-optimization/49963] [4.7 Regression] ICE: in abs_hwi, at hwint.c:108
- Auto-submitted: auto-generated
- References: <bug-49963-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49963
--- Comment #6 from Georg-Johann Lay <gjl at gcc dot gnu.org> 2011-08-08 08:28:46 UTC ---
(In reply to comment #5)
> Created attachment 24909 [details]
> Draft patch
>
> I'm attaching a patch which tries to implement what Joseph suggests (thanks!).
> Essentially, I'm replacing all uses of abs_hwi outside hwint.c itself, besides
> three in tree-ssa-math-opts.c which seem correct anyway: the argument is an
> HOST_WIDE_INT / 2 or / 3 and the result is passed to a function taking a plain
> HOST_WIDE_INT. Type-wise the patch makes a lot of sense to me.
>
> Maybe submitter could test it? I'm sanity checking it on x86_64.
That works for me, i.e. gcc.c-torture/execute/divconst-2.c passes with your
patch.