This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Bad MEM_SIZE for cmpmem causes wrong scheduling


On Sat, Sep 25, 2004 at 02:44:48AM +0200, Ulrich Weigand wrote:
>   if (TREE_CODE (exp) == ADDR_EXPR)
>     exp = TREE_OPERAND (exp, 0);
>   else
>     exp = build1 (INDIRECT_REF, TREE_TYPE (TREE_TYPE (exp)), exp);
>   else
>     exp = NULL;
> 
>   /* Honor attributes derived from exp, except for the alias set
>      (as builtin stringops may alias with anything) and the size
>      (as stringops may access multiple array elements).  */
>   if (exp)
>     {
>       set_mem_attributes (mem, exp, 0);
>       set_mem_alias_set (mem, 0);
>       set_mem_size (mem, NULL_RTX);
>     }

Too many else's, and exp is never null, but that seems ok.  We do
still get MEM_ALIGN set for the INDIRECT_REF side, which is good.


r~


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]