params.def (PARAM_MIN_SIZE_FOR_STACK_SHARING): New param...
2013-10-09 Easwaran Raman <eraman@google.com> * params.def (PARAM_MIN_SIZE_FOR_STACK_SHARING): New param... * cfgexpand.c (defer_stack_allocation): ...use here * doc/invoke.texi: Add documentation for min-size-for-stack-sharing. From-SVN: r203330
This commit is contained in:
parent
c9ef86a171
commit
4d5b5e9f2c
4 changed files with 19 additions and 1 deletions
|
@ -1,3 +1,9 @@
|
|||
2013-10-09 Easwaran Raman <eraman@google.com>
|
||||
|
||||
* params.def (PARAM_MIN_SIZE_FOR_STACK_SHARING): New param...
|
||||
* cfgexpand.c (defer_stack_allocation): ...use here
|
||||
* doc/invoke.texi: Add documentation for min-size-for-stack-sharing.
|
||||
|
||||
2013-10-09 Zhenqiang Chen <zhenqiang.chen@arm.com>
|
||||
|
||||
* tree-ssa-phiopts.c (rhs_is_fed_for_value_replacement): New function.
|
||||
|
|
|
@ -1131,7 +1131,9 @@ defer_stack_allocation (tree var, bool toplevel)
|
|||
other hand, we don't want the function's stack frame size to
|
||||
get completely out of hand. So we avoid adding scalars and
|
||||
"small" aggregates to the list at all. */
|
||||
if (optimize == 0 && tree_low_cst (DECL_SIZE_UNIT (var), 1) < 32)
|
||||
if (optimize == 0
|
||||
&& (tree_low_cst (DECL_SIZE_UNIT (var), 1)
|
||||
< PARAM_VALUE (PARAM_MIN_SIZE_FOR_STACK_SHARING)))
|
||||
return false;
|
||||
|
||||
return true;
|
||||
|
|
|
@ -9686,6 +9686,10 @@ value of a shared integer constant. The default value is 256.
|
|||
The minimum size of buffers (i.e.@: arrays) that receive stack smashing
|
||||
protection when @option{-fstack-protection} is used.
|
||||
|
||||
@item min-size-for-stack-sharing
|
||||
The minimum size of variables taking part in stack slot sharing when not
|
||||
optimizing. The default value is 32.
|
||||
|
||||
@item max-jump-thread-duplication-stmts
|
||||
Maximum number of statements allowed in a block that needs to be
|
||||
duplicated when threading jumps.
|
||||
|
|
|
@ -682,6 +682,12 @@ DEFPARAM (PARAM_SSP_BUFFER_SIZE,
|
|||
"The lower bound for a buffer to be considered for stack smashing protection",
|
||||
8, 1, 0)
|
||||
|
||||
DEFPARAM (PARAM_MIN_SIZE_FOR_STACK_SHARING,
|
||||
"min-size-for-stack-sharing",
|
||||
"The minimum size of variables taking part in stack slot sharing "
|
||||
"when not optimizing",
|
||||
32, 0, 0)
|
||||
|
||||
/* When we thread through a block we have to make copies of the
|
||||
statements within the block. Clearly for large blocks the code
|
||||
duplication is bad.
|
||||
|
|
Loading…
Add table
Reference in a new issue