diff options
author | rth <rth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-11-11 17:52:11 +0000 |
---|---|---|
committer | rth <rth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-11-11 17:52:11 +0000 |
commit | 3ec11c499027aff2ba4041409c7ad18a372d767c (patch) | |
tree | 1269946d9053f55f9328174653105f6943967e41 /gcc/gimple-pretty-print.c | |
parent | 916caf364f2972db357207e621931ad8a61f651c (diff) | |
download | gcc-3ec11c499027aff2ba4041409c7ad18a372d767c.tar.gz |
Implement omp atomic load and store.
* gimple-pretty-print.c (dump_gimple_omp_atomic_load): Dump needed.
(dump_gimple_omp_atomic_store): Likewise.
* optabs.c (can_atomic_exchange_p): New.
* optabs.h (can_atomic_exchange_p): Declare.
* omp-low.c (expand_omp_atomic_load): Implement.
(expand_omp_atomic_store): Likewise.
(expand_omp_atomic): Update for new arguments to load/store.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@181296 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/gimple-pretty-print.c')
-rw-r--r-- | gcc/gimple-pretty-print.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/gcc/gimple-pretty-print.c b/gcc/gimple-pretty-print.c index df703b4ce75..f0e7c50e60e 100644 --- a/gcc/gimple-pretty-print.c +++ b/gcc/gimple-pretty-print.c @@ -1768,6 +1768,8 @@ dump_gimple_omp_atomic_load (pretty_printer *buffer, gimple gs, int spc, else { pp_string (buffer, "#pragma omp atomic_load"); + if (gimple_omp_atomic_need_value_p (gs)) + pp_string (buffer, " [needed]"); newline_and_indent (buffer, spc + 2); dump_generic_node (buffer, gimple_omp_atomic_load_lhs (gs), spc, flags, false); @@ -1795,7 +1797,10 @@ dump_gimple_omp_atomic_store (pretty_printer *buffer, gimple gs, int spc, } else { - pp_string (buffer, "#pragma omp atomic_store ("); + pp_string (buffer, "#pragma omp atomic_store "); + if (gimple_omp_atomic_need_value_p (gs)) + pp_string (buffer, "[needed] "); + pp_character (buffer, '('); dump_generic_node (buffer, gimple_omp_atomic_store_val (gs), spc, flags, false); pp_character (buffer, ')'); |