builtin_str{,n}cmp bug on s390{,x}

Ulrich Weigand weigand@i1.informatik.uni-erlangen.de
Fri Jul 11 20:53:00 GMT 2003


Jakub Jelinek wrote:

> And s390* could also provide cmpstrsi pattern, which would check if length
> is ~(size_t)0, bail otherwise.
> ATM expand_builtin_strcmp only uses cmpstrM patterns if one argument
> is a string literal, but I don't see why it couldn't use it even if
> there is no string literal and the length is unknown (ie. worst ~(size_t)0).

Does that mean that cmpstr now really assumes C-string syntax?
I.e. "ab\0cd" and "ab\0ef" compared with length 5 (or ~0) compare equal?
This is different from what even the updated doc text says ...

Bye,
Ulrich

-- 
  Dr. Ulrich Weigand
  weigand@informatik.uni-erlangen.de



More information about the Gcc mailing list