This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Use MEM tracking information for alias analysis
- To: rth at redhat dot com
- Subject: Re: Use MEM tracking information for alias analysis
- From: kenner at vlsi1 dot ultra dot nyu dot edu (Richard Kenner)
- Date: Fri, 9 Nov 01 20:44:05 EST
- Cc: gcc-patches at gcc dot gnu dot org
Perhaps better as
if (! rtx_equal_p (basex, basey))
return CONSTANT_P (basex) && CONSTANT_P (basey);
Clever and more efficient, but less clear. However, I do like it so, I'll
change it and the comment.
And I just realized that they also don't conflict if one base is a
constant and the other is a pointer into the frame, so I'll change
that on the next round.
> + sizey = (REG_P (rtly) ? GET_MODE_SIZE (GET_MODE (rtly))
> + : MEM_SIZE (rtly) ? INTVAL (MEM_SIZE (rtly)) :
> + -1);
[...]
> + if (MEM_SIZE (y))
> + sizey = INTVAL (MEM_SIZE (y));
Redundant checks of MEM_SIZE.
No. One is the size of the MEM in the DECL (which should actually always
be set, but who knows) and the other the size of the passed memref.