summaryrefslogtreecommitdiff
path: root/gcc/omp-low.c
diff options
context:
space:
mode:
authorjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2012-02-14 23:32:39 +0000
committerjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2012-02-14 23:32:39 +0000
commit91659b0a75758f71c7238e26a0113c2ff5c7a64f (patch)
tree562f0362dc09390f603e23ec72904f06531307a7 /gcc/omp-low.c
parent35e5dc9fa7f94c0cab5897abfd677034b584539c (diff)
downloadgcc-91659b0a75758f71c7238e26a0113c2ff5c7a64f.tar.gz
Backported from mainline
2012-02-13 Jakub Jelinek <jakub@redhat.com> PR middle-end/52230 * omp-low.c (expand_omp_for): If a static schedule without chunk size has NULL region->cont, force fd.chunk_size to be integer_zero_node. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/gcc-4_6-branch@184240 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/omp-low.c')
-rw-r--r--gcc/omp-low.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/omp-low.c b/gcc/omp-low.c
index 364f51e3bfd..bb0017a7671 100644
--- a/gcc/omp-low.c
+++ b/gcc/omp-low.c
@@ -4618,6 +4618,9 @@ expand_omp_for (struct omp_region *region)
{
int fn_index, start_ix, next_ix;
+ if (fd.chunk_size == NULL
+ && fd.sched_kind == OMP_CLAUSE_SCHEDULE_STATIC)
+ fd.chunk_size = integer_zero_node;
gcc_assert (fd.sched_kind != OMP_CLAUSE_SCHEDULE_AUTO);
fn_index = (fd.sched_kind == OMP_CLAUSE_SCHEDULE_RUNTIME)
? 3 : fd.sched_kind;