+2006-04-26 Jakub Jelinek <jakub@redhat.com>
+
+ PR middle-end/25989
+ * tree-flow.h (struct omp_region): Add sched_kind.
+ * omp-low.c (expand_parallel_call): Use region->inner->sched_kind
+ instead of extracting omp for data.
+ (expand_omp_for): Save extracted sched_kind.
+
2006-04-25 Roger Sayle <roger@eyesopen.com>
* expmed.c (store_bit_field): Also check whether the bitsize is
switch (region->inner->type)
{
case OMP_FOR:
- {
- tree stmt = last_stmt (region->inner->entry);
- struct omp_for_data fd;
- extract_omp_for_data (stmt, &fd);
- start_ix = BUILT_IN_GOMP_PARALLEL_LOOP_STATIC_START
- + fd.sched_kind;
- }
+ start_ix = BUILT_IN_GOMP_PARALLEL_LOOP_STATIC_START
+ + region->inner->sched_kind;
break;
case OMP_SECTIONS:
start_ix = BUILT_IN_GOMP_PARALLEL_SECTIONS_START;
push_gimplify_context ();
extract_omp_for_data (last_stmt (region->entry), &fd);
+ region->sched_kind = fd.sched_kind;
if (fd.sched_kind == OMP_CLAUSE_SCHEDULE_STATIC && !fd.have_ordered)
{
/* The code for the omp directive of this region. */
enum tree_code type;
+ /* Schedule kind, only used for OMP_FOR type regions. */
+ enum omp_clause_schedule_kind sched_kind;
+
/* True if this is a combined parallel+workshare region. */
bool is_combined_parallel;
};