2017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
commit92bc38e7ad16abbb654ad2ef2b533e05c0e95f97
authorlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 1 May 2017 22:26:02 +0000 (1 22:26 +0000)
committerlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 1 May 2017 22:26:02 +0000 (1 22:26 +0000)
treea8a033d722da210460642c7a397ad087d9c87d1f
parentbe45049f886ed00e3a02ec46de135e02ef161cc4
2017-05-01  Xi Ruoyao  <ryxi@stu.xidian.edu.cn>

        PR c++/80038
* cilk_common.c (expand_builtin_cilk_detach): Move pedigree
operations here.
* gimplify.c (gimplify_cilk_detach): New function.
(gimplify_call_expr, gimplify_modify_expr): Call it as needed.
* tree-core.h: Document EXPR_CILK_SPAWN.
* tree.h (EXPR_CILK_SPAWN): Define.

        PR c++/80038
* c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
prototype.
(cilk_install_body_pedigree_operations): Likewise.
* cilk.c (cilk_set_spawn_marker): Mark functions that should be
detatched.
(cilk_gimplify_call_params_in_spawned_fn): Remove.
(cilk_install_body_pedigree_operations): Likewise.
(gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
unwrapping.

        PR c++/80038
* c-gimplify.c (c_gimplify_expr): Remove calls to
cilk_gimplifY_call_params_in_spawned_fn.

        PR c++/80038
* cp-cilkplus.c (cilk_install_body_with_frame_cleanup): Don't
add pedigree operation and detach call here.
* cp-gimplify.c (cp_gimplify_expr): Remove the calls to
cilk_cp_gimplify_call_params_in_spawned_fn.
(cilk_cp_gimplify_call_params_in_spawned_fn): Remove function.
* semantics.c (simplify_aggr_init_expr): Copy EXPR_CILK_SPAWN.

        PR c++/80038
* lto-lang.c (lto_init): Set in_lto_p earlier.

PR c++/80038
* g++.dg/cilk-plus/CK/pr80038.cc: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@247446 138bc75d-0d04-0410-961f-82ee72b054a4
19 files changed:
gcc/ChangeLog
gcc/c-family/ChangeLog
gcc/c-family/c-common.h
gcc/c-family/c-gimplify.c
gcc/c-family/cilk.c
gcc/c/ChangeLog
gcc/c/c-typeck.c
gcc/cilk-common.c
gcc/cp/ChangeLog
gcc/cp/cp-cilkplus.c
gcc/cp/cp-gimplify.c
gcc/cp/semantics.c
gcc/gimplify.c
gcc/lto/ChangeLog
gcc/lto/lto-lang.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/cilk-plus/CK/pr80038.cc [new file with mode: 0644]
gcc/tree-core.h
gcc/tree.h