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]

Re: [PATCH] Builtin strcpy/strncpy/memcpy/strcmp/fputs fixes and optimizations


On Wed, Nov 29, 2000 at 06:29:31PM -0500, Michael Meissner wrote:
> Assuming you change:
> 	strcmp ("constant-string", pointer)
> into
> 	memcmp ("constant-string", pointer, sizeof ("constant-string")-1),
> what happens if memcmp on the machine is aggresive and reads multiple
> words at a time to hide the memory latency.

Well, we don't do this transformation in general, only when
we can inline the memcmp.  There are currently only three
targets that implement cmpstrsi, and none of them do this
multiple read optimization.

So perhaps we just need to add commentary somewhere...


r~

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