This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/52445] [4.6/4.7 Regression] conditional store replacement causes segfault in generated code
- From: "jakub at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 01 Mar 2012 10:50:50 +0000
- Subject: [Bug tree-optimization/52445] [4.6/4.7 Regression] conditional store replacement causes segfault in generated code
- Auto-submitted: auto-generated
- References: <bug-52445-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52445
--- Comment #8 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-03-01 10:50:50 UTC ---
(In reply to comment #7)
> Ok with
>
> + && TREE_CODE (TREE_OPERAND (exp, 0)) == SSA_NAME
> + && host_integerp (TREE_OPERAND (exp, 1), 0))
>
> also checking that int_size_in_bytes does not return -1.
I'm doing that check later. The reason I wanted to avoid doing it in the first
if, is that either it will mean int_size_in_bytes needs to be called twice, or
we'd need
(size = int_size_in_bytes (TREE_TYPE (exp))) > 0
(i.e. setting variables in the if condition). But if you prefer one of these,
I'll adjust.