rs6000-string.c (expand_block_clear): Change how we determine if unaligned vsx is ok.

2018-11-28  Aaron Sawdey  <acsawdey@linux.ibm.com>

	* config/rs6000/rs6000-string.c (expand_block_clear): Change how
	we determine if unaligned vsx is ok.

From-SVN: r266599
This commit is contained in:
Aaron Sawdey 2018-11-29 03:56:14 +00:00 committed by Aaron Sawdey
parent ffe2c05539
commit 645eee7431
2 changed files with 8 additions and 2 deletions

View File

@ -1,3 +1,8 @@
2018-11-28 Aaron Sawdey <acsawdey@linux.ibm.com>
* config/rs6000/rs6000-string.c (expand_block_clear): Change how
we determine if unaligned vsx is ok.
2018-11-28 Jan Hubicka <jh@suse.cz>
* predict.c (determine_unlikely_bbs): Forward declare; also determine

View File

@ -85,14 +85,15 @@ expand_block_clear (rtx operands[])
if (! optimize_size && bytes > 8 * clear_step)
return 0;
bool unaligned_vsx_ok = (bytes >= 32 && TARGET_EFFICIENT_UNALIGNED_VSX);
for (offset = 0; bytes > 0; offset += clear_bytes, bytes -= clear_bytes)
{
machine_mode mode = BLKmode;
rtx dest;
if (TARGET_ALTIVEC
&& ((bytes >= 16 && align >= 128)
|| (bytes >= 32 && TARGET_EFFICIENT_UNALIGNED_VSX)))
&& (bytes >= 16 && (align >= 128 || unaligned_vsx_ok)))
{
clear_bytes = 16;
mode = V4SImode;