Skip to content
Snippets Groups Projects
Commit 1e2ea685 authored by Alexandre Oliva's avatar Alexandre Oliva Committed by Alexandre Oliva
Browse files

-finline-stringops: check base blksize for memset [PR112778]

The recently-added logic for -finline-stringops=memset introduced an
assumption that doesn't necessarily hold, namely, that
can_store_by_pieces of a larger size implies can_store_by_pieces by
smaller sizes.  Checks for all sizes the by-multiple-pieces machinery
might use before committing to an expansion pattern.


for  gcc/ChangeLog

	PR target/112778
	* builtins.cc (can_store_by_multiple_pieces): New.
	(try_store_by_multiple_pieces): Call it.

for  gcc/testsuite/ChangeLog

	PR target/112778
	* gcc.dg/inline-mem-cmp-pr112778.c: New.
parent 76ca5ab4
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment