https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95556
Jakub Jelinek changed:
What|Removed |Added
Resolution|--- |INVALID
Status|UNCONFIRMED
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95556
--- Comment #9 from Jeff Davis ---
I still feel like the documentation is misleading on this point.
Regardless, it doesn't seem like you think there is any bug here, so go ahead
and close.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95556
--- Comment #8 from Jakub Jelinek ---
(In reply to Jeff Davis from comment #7)
> "...built-in functions are optimized into the normal string functions like
> memcpy if the last argument is (size_t) -1..."
>
> My reading of the document lead me t
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95556
--- Comment #7 from Jeff Davis ---
"...built-in functions are optimized into the normal string functions like
memcpy if the last argument is (size_t) -1..."
My reading of the document lead me to believe that a last argument of -1
*would* be a no
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95556
--- Comment #6 from Jakub Jelinek ---
See -mno-align-stringops, -minline-all-stringops,
-minline-stringops-dynamically, -mstringop-strategy= , -mmemcpy-strategy=
options and their documentation in the GCC manual.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95556
--- Comment #5 from Jakub Jelinek ---
And note that
- if (lt->pos >= (8192-sizeof(S)))
+ if (lt->pos >= (8192-16))
is not an insignificant change, the first one is unsigned comparison, the
second one signed.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95556
Jakub Jelinek changed:
What|Removed |Added
CC||jakub at gcc dot gnu.org
--- Comment #4
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95556
--- Comment #2 from Jeff Davis ---
Created attachment 48688
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=48688&action=edit
Example 3
Another example that works (i.e. builtin is properly replaced by memcpy as
described in the document).