From a6258f5ab52de7d53fb9c91537e61ea6398d3675 Mon Sep 17 00:00:00 2001 From: jakub Date: Wed, 20 Jan 2016 23:55:38 +0000 Subject: [PATCH] * omp-low.c (expand_omp_target): Avoid -Wmaybe-uninitialized warning. Fix up formatting. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@232641 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ChangeLog | 3 +++ gcc/omp-low.c | 11 +++++------ 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 06aae56..f20b9b6 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,8 @@ 2016-01-21 Jakub Jelinek + * omp-low.c (expand_omp_target): Avoid -Wmaybe-uninitialized + warning. Fix up formatting. + PR middle-end/67653 * gimplify.c (gimplify_asm_expr): Warn if it is too late to attempt to mark memory input operand addressable and diff --git a/gcc/omp-low.c b/gcc/omp-low.c index 673dee3..2977082 100644 --- a/gcc/omp-low.c +++ b/gcc/omp-low.c @@ -13328,21 +13328,20 @@ expand_omp_target (struct omp_region *region) GOMP_ASYNC_SYNC)); if (tagging && t_async) { - unsigned HOST_WIDE_INT i_async; + unsigned HOST_WIDE_INT i_async = GOMP_LAUNCH_OP_MAX; if (TREE_CODE (t_async) == INTEGER_CST) { /* See if we can pack the async arg in to the tag's operand. */ i_async = TREE_INT_CST_LOW (t_async); - if (i_async < GOMP_LAUNCH_OP_MAX) t_async = NULL_TREE; + else + i_async = GOMP_LAUNCH_OP_MAX; } - if (t_async) - i_async = GOMP_LAUNCH_OP_MAX; - args.safe_push (oacc_launch_pack - (GOMP_LAUNCH_ASYNC, NULL_TREE, i_async)); + args.safe_push (oacc_launch_pack (GOMP_LAUNCH_ASYNC, NULL_TREE, + i_async)); } if (t_async) args.safe_push (t_async); -- 2.7.4