This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug rtl-optimization/49330] Integer arithmetic on addresses optimised with pointer arithmetic rules
- 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, 9 Jun 2011 10:39:26 +0000
- Subject: [Bug rtl-optimization/49330] Integer arithmetic on addresses optimised with pointer arithmetic rules
- Auto-submitted: auto-generated
- References: <bug-49330-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49330
--- Comment #6 from Jakub Jelinek <jakub at gcc dot gnu.org> 2011-06-09 10:38:37 UTC ---
find_base_value/find_base_term seem to be overly optimistic, prefer to return
something over being conservative. E.g. if both operands of PLUS or MINUS
return non-NULL find_base_term, we just return the first one, etc.
It doesn't differentiate between "certainly not based on something" - e.g.
CONST_INT, regs only initialized by them and only incremented by constant etc.
would be such and unknown. While the overly optimistic implementation might be
useful in some cases, at least for base_alias_check it is inappropriate.