diff options
author | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2015-01-09 21:38:00 +0000 |
---|---|---|
committer | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2015-01-09 21:38:00 +0000 |
commit | ba000093030681d638994482d8eafc8b41c4822b (patch) | |
tree | 0fa5fbb2a370d97a2ae01365d2990eccfaad9616 /gcc/tree-streamer-out.c | |
parent | 6a261eec319e0fc445f198da58976343b300613b (diff) | |
download | gcc-ba000093030681d638994482d8eafc8b41c4822b.tar.gz |
PR middle-end/64412
* lto-streamer.h (lto_stream_offload_p): New declaration.
* lto-streamer.c (lto_stream_offload_p): New variable.
* cgraphunit.c (ipa_passes): Set lto_stream_offload_p
at the same time as section_name_prefix.
* lto-streamer-out.c (hash_tree): Don't hash TREE_TARGET_OPTION
if lto_stream_offload_p.
* tree-streamer-out.c (streamer_pack_tree_bitfields): Don't
stream TREE_TARGET_OPTION if lto_stream_offload_p.
(write_ts_function_decl_tree_pointers): Don't
stream DECL_FUNCTION_SPECIFIC_TARGET if lto_stream_offload_p.
* tree-streamer-in.c (unpack_value_fields): Don't stream
TREE_TARGET_OPTION in if ACCEL_COMPILER.
(lto_input_ts_function_decl_tree_pointers): Don't stream
DECL_FUNCTION_SPECIFIC_TARGET in if ACCEL_COMPILER.
* lto-opts.c (lto_write_options): Use lto_stream_offload_p
instead of section_name_prefix string comparisons.
lto/
* lto.c (read_cgraph_and_symbols): Set lto_stream_offload_p
if ACCEL_COMPILER.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@219410 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-streamer-out.c')
-rw-r--r-- | gcc/tree-streamer-out.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/gcc/tree-streamer-out.c b/gcc/tree-streamer-out.c index 84ea21ef25d..480fb1e272c 100644 --- a/gcc/tree-streamer-out.c +++ b/gcc/tree-streamer-out.c @@ -480,7 +480,9 @@ streamer_pack_tree_bitfields (struct output_block *ob, if (CODE_CONTAINS_STRUCT (code, TS_CONSTRUCTOR)) bp_pack_var_len_unsigned (bp, CONSTRUCTOR_NELTS (expr)); - if (CODE_CONTAINS_STRUCT (code, TS_TARGET_OPTION)) + if (CODE_CONTAINS_STRUCT (code, TS_TARGET_OPTION) + /* Don't stream these when passing things to a different target. */ + && !lto_stream_offload_p) cl_target_option_stream_out (ob, bp, TREE_TARGET_OPTION (expr)); if (code == OMP_CLAUSE) @@ -695,7 +697,9 @@ write_ts_function_decl_tree_pointers (struct output_block *ob, tree expr, stream_write_tree (ob, DECL_VINDEX (expr), ref_p); /* DECL_STRUCT_FUNCTION is handled by lto_output_function. */ stream_write_tree (ob, DECL_FUNCTION_PERSONALITY (expr), ref_p); - stream_write_tree (ob, DECL_FUNCTION_SPECIFIC_TARGET (expr), ref_p); + /* Don't stream these when passing things to a different target. */ + if (!lto_stream_offload_p) + stream_write_tree (ob, DECL_FUNCTION_SPECIFIC_TARGET (expr), ref_p); stream_write_tree (ob, DECL_FUNCTION_SPECIFIC_OPTIMIZATION (expr), ref_p); } |