Hi,

DEF_GOMP_BUILTIN tests for 'flag_parallelize_loops'. But if flag_parallelize_loops is one (which is also the default), then pass_parloops doesn't do anything, and won't generate any OMP constructs.

This patch makes DEF_GOMP_BUILTIN tests 'flag_parallelize_loops > 1', just like all the other tests of flag_parallelize_loops in the compiler.

Build on x86_64 and reg-tested libgomp's c.exp.

OK for trunk if bootstrap and reg-test succeeds?

Thanks,
- Tom
Test for flag_parallelize_loops > 1

2015-06-19  Tom de Vries  <t...@codesourcery.com>

	* builtins.def (DEF_GOMP_BUILTIN): Test
	'flag_tree_parallelize_loops > 1' instead of
	'flag_tree_parallelize_loops'.
---
 gcc/builtins.def | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/gcc/builtins.def b/gcc/builtins.def
index 55ce9f6..5506b75 100644
--- a/gcc/builtins.def
+++ b/gcc/builtins.def
@@ -182,7 +182,8 @@ along with GCC; see the file COPYING3.  If not see
 #define DEF_GOMP_BUILTIN(ENUM, NAME, TYPE, ATTRS) \
   DEF_BUILTIN (ENUM, "__builtin_" NAME, BUILT_IN_NORMAL, TYPE, TYPE,    \
                false, true, true, ATTRS, false, \
-	       (flag_openmp || flag_tree_parallelize_loops \
+	       (flag_openmp \
+		|| flag_tree_parallelize_loops > 1 \
 		|| flag_offload_abi != OFFLOAD_ABI_UNSET))
 
 /* Builtin used by implementation of Cilk Plus.  Most of these are decomposed
-- 
1.9.1

Reply via email to