-
- Downloads
asan.c (handle_builtin_alloca): Deal with all alloca variants.
* asan.c (handle_builtin_alloca): Deal with all alloca variants. (get_mem_refs_of_builtin_call): Likewise. * builtins.c (expand_builtin_apply): Adjust call to allocate_dynamic_stack_space. (expand_builtin_alloca): For __builtin_alloca_with_align_and_max, pass the third argument to allocate_dynamic_stack_space, otherwise -1. (expand_builtin): Deal with all alloca variants. (is_inexpensive_builtin): Likewise. * builtins.def (BUILT_IN_ALLOCA_WITH_ALIGN_AND_MAX): New. * calls.c (special_function_p): Deal with all alloca variants. (initialize_argument_information): Adjust call to allocate_dynamic_stack_space. (expand_call): Likewise. * cfgexpand.c (expand_call_stmt): Deal with all alloca variants. * doc/extend.texi (Built-ins): Add __builtin_alloca_with_align_and_max * explow.c (allocate_dynamic_stack_space): Add MAX_SIZE parameter and use it for the stack usage computation. * explow.h (allocate_dynamic_stack_space): Adjust prototype. * function.c (gimplify_parameters): Turn BUILT_IN_ALLOCA_WITH_ALIGN into BUILT_IN_ALLOCA_WITH_ALIGN_AND_MAX and pass maximum size. * gimple-ssa-warn-alloca.c (alloca_call_type): Simplify control flow. Take into account 3rd argument of __builtin_alloca_with_align_and_max. (in_loop_p): Remove first argument and useless check. (pass_walloca::execute): Remove useless test and adjust call to above. * gimple.c (gimple_build_call_from_tree): Deal with all alloc variants * gimplify.c (gimplify_vla_decl): Turn BUILT_IN_ALLOCA_WITH_ALIGN into BUILT_IN_ALLOCA_WITH_ALIGN_AND_MAX and pass maximum size. (gimplify_call_expr): Deal with all alloca variants. * hsa-gen.c (gen_hsa_alloca): Likewise. (gen_hsa_insns_for_call): Likewise. * ipa-pure-const.c (special_builtin_state): Likewise. * tree-chkp.c (chkp_build_returned_bound): Likewise. * tree-object-size.c (alloc_object_size): Likewise. * tree-ssa-alias.c (ref_maybe_used_by_call_p_1): Likewise. (call_may_clobber_ref_p_1): Likewise. * tree-ssa-ccp.c (evaluate_stmt): Likewise. (ccp_fold_stmt): Likewise. (optimize_stack_restore): Likewise. * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise. (mark_all_reaching_defs_necessary_1): Likewise. (propagate_necessity): Likewise. (eliminate_unnecessary_stmts): Likewise. * tree.c (build_common_builtin_nodes): Build BUILT_IN_ALLOCA_WITH_ALIGN_AND_MAX. * tree.h (ALLOCA_FUNCTION_CODE_P): New macro. (CASE_BUILT_IN_ALLOCA): Likewise. * varasm.c (incorporeal_function_p): Deal with all alloca variants. c-family/ * c-common.c (check_builtin_function_arguments): Also check arguments of __builtin_alloca_with_align_and_max. From-SVN: r253901
Showing
- gcc/ChangeLog 50 additions, 0 deletionsgcc/ChangeLog
- gcc/asan.c 3 additions, 5 deletionsgcc/asan.c
- gcc/builtins.c 24 additions, 18 deletionsgcc/builtins.c
- gcc/builtins.def 1 addition, 0 deletionsgcc/builtins.def
- gcc/c-family/ChangeLog 5 additions, 0 deletionsgcc/c-family/ChangeLog
- gcc/c-family/c-common.c 10 additions, 0 deletionsgcc/c-family/c-common.c
- gcc/calls.c 9 additions, 16 deletionsgcc/calls.c
- gcc/cfgexpand.c 1 addition, 2 deletionsgcc/cfgexpand.c
- gcc/doc/extend.texi 11 additions, 0 deletionsgcc/doc/extend.texi
- gcc/explow.c 12 additions, 3 deletionsgcc/explow.c
- gcc/explow.h 2 additions, 1 deletiongcc/explow.h
- gcc/function.c 3 additions, 4 deletionsgcc/function.c
- gcc/gimple-ssa-warn-alloca.c 39 additions, 46 deletionsgcc/gimple-ssa-warn-alloca.c
- gcc/gimple.c 1 addition, 2 deletionsgcc/gimple.c
- gcc/gimplify.c 3 additions, 5 deletionsgcc/gimplify.c
- gcc/hsa-gen.c 3 additions, 5 deletionsgcc/hsa-gen.c
- gcc/ipa-pure-const.c 1 addition, 2 deletionsgcc/ipa-pure-const.c
- gcc/testsuite/ChangeLog 6 additions, 0 deletionsgcc/testsuite/ChangeLog
- gcc/testsuite/gcc.dg/Walloca-15.c 17 additions, 0 deletionsgcc/testsuite/gcc.dg/Walloca-15.c
- gcc/testsuite/gnat.dg/stack_usage4.adb 11 additions, 0 deletionsgcc/testsuite/gnat.dg/stack_usage4.adb
Loading
Please register or sign in to comment