mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-04-13 00:21:18 +08:00
gimplify.c (gimplify_init_constructor): Do a block move for very small objects as well.
* gimplify.c (gimplify_init_constructor): Do a block move for very small objects as well. From-SVN: r187498
This commit is contained in:
parent
aa44c80c8f
commit
f301837ea3
@ -1,3 +1,8 @@
|
||||
2012-05-15 Eric Botcazou <ebotcazou@adacore.com>
|
||||
|
||||
* gimplify.c (gimplify_init_constructor): Do a block move for very
|
||||
small objects as well.
|
||||
|
||||
2012-05-15 Bernd Schmidt <bernds@codesourcery.com>
|
||||
|
||||
* ira.c (find_moveable_pseudos): Skip registers whose
|
||||
|
@ -4033,9 +4033,13 @@ gimplify_init_constructor (tree *expr_p, gimple_seq *pre_p, gimple_seq *post_p,
|
||||
else
|
||||
align = TYPE_ALIGN (type);
|
||||
|
||||
/* Do a block move either if the size is so small as to make
|
||||
each individual move a sub-unit move on average, or if it
|
||||
is so large as to make individual moves inefficient. */
|
||||
if (size > 0
|
||||
&& num_nonzero_elements > 1
|
||||
&& !can_move_by_pieces (size, align))
|
||||
&& (size < num_nonzero_elements
|
||||
|| !can_move_by_pieces (size, align)))
|
||||
{
|
||||
if (notify_temp_creation)
|
||||
return GS_ERROR;
|
||||
|
Loading…
x
Reference in New Issue
Block a user