rtl.h (SCHED_GROUP_P): Disallow CODE_LABEL, BARRIER and NOTE.

2002-06-14  Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>

	* rtl.h (SCHED_GROUP_P): Disallow CODE_LABEL, BARRIER and NOTE.
	* sched-deps.c (add_dependence): Likewise.
	(group_leader): Likewise.
	* sched-rgn.c (init_ready_list): Likewise.
	* doc/rtl.texi: Adjust accordingly.

From-SVN: r54622
This commit is contained in:
Franz Sirl 2002-06-14 18:58:10 +00:00 committed by Franz Sirl
parent 6203ef88a6
commit be202ec201
5 changed files with 25 additions and 23 deletions

View file

@ -1,3 +1,11 @@
2002-06-14 Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
* rtl.h (SCHED_GROUP_P): Disallow CODE_LABEL, BARRIER and NOTE.
* sched-deps.c (add_dependence): Likewise.
(group_leader): Likewise.
* sched-rgn.c (init_ready_list): Likewise.
* doc/rtl.texi: Adjust accordingly.
2002-06-13 Jeffrey Law <law@redhat.com> 2002-06-13 Jeffrey Law <law@redhat.com>
* gcse.c (delete_null_pointer_checks_1): Inform caller if any * gcse.c (delete_null_pointer_checks_1): Inform caller if any

View file

@ -614,17 +614,13 @@ anywhere. This does not mean that it is function invariant.
Stored in the @code{unchanging} field and printed as @samp{/u}. Stored in the @code{unchanging} field and printed as @samp{/u}.
@findex SCHED_GROUP_P @findex SCHED_GROUP_P
@cindex @code{insn} and @samp{/i} @cindex @code{insn} and @samp{/s}
@cindex @code{call_insn} and @samp{/i} @cindex @code{call_insn} and @samp{/s}
@cindex @code{jump_insn} and @samp{/i} @cindex @code{jump_insn} and @samp{/s}
@cindex @code{code_label} and @samp{/i} @cindex @code{in_struct}, in @code{insn}, @code{jump_insn} and @code{call_insn}
@cindex @code{barrier} and @samp{/i}
@cindex @code{note} and @samp{/i}
@cindex @code{in_struct}, in @code{insn}, @code{jump_insn}, @code{call_insn}, @code{code_label}, @code{barrier}, and @code{note}
@item SCHED_GROUP_P (@var{x}) @item SCHED_GROUP_P (@var{x})
During instruction scheduling, in an @code{insn}, @code{call_insn}, During instruction scheduling, in an @code{insn}, @code{call_insn} or
@code{jump_insn}, @code{code_label}, @code{barrier}, or @code{jump_insn}, indicates that the
@code{note}, indicates that the
previous insn must be scheduled together with this insn. This is used to previous insn must be scheduled together with this insn. This is used to
ensure that certain groups of instructions will not be split up by the ensure that certain groups of instructions will not be split up by the
instruction scheduling pass, for example, @code{use} insns before instruction scheduling pass, for example, @code{use} insns before

View file

@ -161,9 +161,8 @@ struct rtx_def
and must not be deleted even if its count is zero. and must not be deleted even if its count is zero.
1 in a LABEL_REF if this is a reference to a label outside the 1 in a LABEL_REF if this is a reference to a label outside the
current loop. current loop.
1 in an INSN, JUMP_INSN, CALL_INSN, CODE_LABEL, BARRIER, or NOTE if 1 in an INSN, JUMP_INSN or CALL_INSN if this insn must be scheduled
this insn must be scheduled together with the preceding insn. Valid together with the preceding insn. Valid only within sched.
only within sched.
1 in an INSN, JUMP_INSN, or CALL_INSN if insn is in a delay slot and 1 in an INSN, JUMP_INSN, or CALL_INSN if insn is in a delay slot and
from the target of a branch. Valid from reorg until end of compilation; from the target of a branch. Valid from reorg until end of compilation;
cleared before used. cleared before used.
@ -1118,8 +1117,8 @@ do { \
/* During sched, 1 if RTX is an insn that must be scheduled together /* During sched, 1 if RTX is an insn that must be scheduled together
with the preceding insn. */ with the preceding insn. */
#define SCHED_GROUP_P(RTX) \ #define SCHED_GROUP_P(RTX) \
(RTL_FLAG_CHECK6("SCHED_GROUP_P", (RTX), INSN, JUMP_INSN, CALL_INSN, \ (RTL_FLAG_CHECK3("SCHED_GROUP_P", (RTX), INSN, JUMP_INSN, CALL_INSN \
CODE_LABEL, BARRIER, NOTE)->in_struct) )->in_struct)
/* For a SET rtx, SET_DEST is the place that is set /* For a SET rtx, SET_DEST is the place that is set
and SET_SRC is the value it is set to. */ and SET_SRC is the value it is set to. */

View file

@ -222,8 +222,7 @@ add_dependence (insn, elem, dep_type)
setters of the condition codes, so we must skip past notes here. setters of the condition codes, so we must skip past notes here.
Otherwise, NOTEs are impossible here. */ Otherwise, NOTEs are impossible here. */
next = next_nonnote_insn (elem); next = next_nonnote_insn (elem);
if (next && SCHED_GROUP_P (next) if (next && INSN_P (next) && SCHED_GROUP_P (next))
&& GET_CODE (next) != CODE_LABEL)
{ {
/* Notes will never intervene here though, so don't bother checking /* Notes will never intervene here though, so don't bother checking
for them. */ for them. */
@ -235,8 +234,8 @@ add_dependence (insn, elem, dep_type)
rtx nnext; rtx nnext;
while ((nnext = next_nonnote_insn (next)) != NULL while ((nnext = next_nonnote_insn (next)) != NULL
&& SCHED_GROUP_P (nnext) && INSN_P (nnext)
&& GET_CODE (nnext) != CODE_LABEL) && SCHED_GROUP_P (nnext))
next = nnext; next = nnext;
/* Again, don't depend an insn on itself. */ /* Again, don't depend an insn on itself. */
@ -448,7 +447,7 @@ group_leader (insn)
prev = insn; prev = insn;
insn = next_nonnote_insn (insn); insn = next_nonnote_insn (insn);
} }
while (insn && SCHED_GROUP_P (insn) && (GET_CODE (insn) != CODE_LABEL)); while (insn && INSN_P (insn) && SCHED_GROUP_P (insn));
return prev; return prev;
} }

View file

@ -2033,7 +2033,7 @@ init_ready_list (ready)
next = NEXT_INSN (insn); next = NEXT_INSN (insn);
if (INSN_DEP_COUNT (insn) == 0 if (INSN_DEP_COUNT (insn) == 0
&& (SCHED_GROUP_P (next) == 0 || ! INSN_P (next))) && (! INSN_P (next) || SCHED_GROUP_P (next) == 0))
ready_add (ready, insn); ready_add (ready, insn);
if (!(SCHED_GROUP_P (insn))) if (!(SCHED_GROUP_P (insn)))
target_n_insns++; target_n_insns++;
@ -2079,8 +2079,8 @@ init_ready_list (ready)
next = next_nonnote_insn (insn); next = next_nonnote_insn (insn);
if (INSN_DEP_COUNT (insn) == 0 if (INSN_DEP_COUNT (insn) == 0
&& (! next && (! next
|| SCHED_GROUP_P (next) == 0 || ! INSN_P (next)
|| ! INSN_P (next))) || SCHED_GROUP_P (next) == 0))
ready_add (ready, insn); ready_add (ready, insn);
} }
} }