This is the mail archive of the gcc@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]

Re: Would alias analysis help WRT builtin memmove -> builtin memcpy ?



  In message <200003292249.RAA29751@caip.rutgers.edu>you write:
  > So I naively tried the type based stuff, using get_alias_type() on the
  > TREE_VALUE() of the parameters.  But I quickly saw that by the time I
  > got the argument trees, they were already both of type void* so the
  > types aliased to the same set.  (At least that's my uneducated guess,
  > they were both in the same set #11, while the length parameter was in
  > set #9.)
By definition, a void * can alias anything (just like a char *).

  > Then I thought the base ptr stuff might be useful, but I wasn't sure
  > how to access that code.  Any pointers?  (No pun intended...)
The code is not designed for you to be able to independently ask about
type or base pointer aliasing questions, but  instead can pointers A and
B alias each other -- if it returns yes, then they may alias, you don't
know how or why, only that they may alias.

I don't think adding separate queries of this nature would be a good idea.
jeff


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