Commit cbe26ab8 by Dorit Naishlos Committed by Dorit Nuzman

rs6000.h: (rs6000_sched_insert_nops): support new flag -minsert-sched-nops.


        * config/rs6000/rs6000.h: (rs6000_sched_insert_nops):
        support new flag -minsert-sched-nops.
        (DEFAULT_SCHED_FINISH_NOP_INSERTION_SCHEME): Define.
        * config/rs6000/rs6000.c: (rs6000_sched_insert_nops):
        support new flag -minsert-sched-nops.
        (is_cracked_insn, is_microcoded_insn): New functions.
        (rs6000_sched_finish): New function.
        (rs6000_issue_rate): Return 5 for power4.
        (get_next_active_insn, insn_terminates_group_p): New
        functions.
        (is_costly_group, force_new_group): New functions.
        (redefine_groups, pad_groups): New functions.
        (rs6000_variable_issue): Use new functions.
        * doc/invoke.texi (-minsert-sched-nops): Document new
        option.

From-SVN: r72707
parent 8d36c499
2003-10-20 Dorit Naishlos <dorit@il.ibm.com>
* config/rs6000/rs6000.h: (rs6000_sched_insert_nops):
support new flag -minsert-sched-nops.
(DEFAULT_SCHED_FINISH_NOP_INSERTION_SCHEME): Define.
* config/rs6000/rs6000.c: (rs6000_sched_insert_nops):
support new flag -minsert-sched-nops.
(is_cracked_insn, is_microcoded_insn): New functions.
(rs6000_sched_finish): New function.
(rs6000_issue_rate): Return 5 for power4.
(get_next_active_insn, insn_terminates_group_p): New
functions.
(is_costly_group, force_new_group): New functions.
(redefine_groups, pad_groups): New functions.
(rs6000_variable_issue): Use new functions.
* doc/invoke.texi (-minsert-sched-nops): Document new
option.
2003-10-20 David S. Miller <davem@redhat.com>
* config/sparc/sparc.md (type attribute): Add new insn types
......
......@@ -386,6 +386,21 @@ enum rs6000_dependence_cost
store_to_load_dep_costly
};
/* Types of nop insertion schemes in sched target hook sched_finish. */
enum rs6000_nop_insertion
{
sched_finish_regroup_exact = 1000,
sched_finish_pad_groups,
sched_finish_none
};
/* Dispatch group termination caused by an insn. */
enum group_termination
{
current_group,
previous_group
};
/* This is meant to be overridden in target specific files. */
#define SUBTARGET_OPTIONS
......@@ -413,7 +428,9 @@ enum rs6000_dependence_cost
N_("Avoid all range limits on call instructions"), 0}, \
{"no-longcall", &rs6000_longcall_switch, "", 0}, \
{"sched-costly-dep=", &rs6000_sched_costly_dep_str, \
N_("determine which dependences between insns are considered costly"), 0}, \
N_("Determine which dependences between insns are considered costly"), 0}, \
{"insert-sched-nops=", &rs6000_sched_insert_nops_str, \
N_("Specify which post scheduling nop insertion scheme to apply"), 0}, \
{"align-", &rs6000_alignment_string, \
N_("Specify alignment of structure fields default/natural"), 0}, \
{"prioritize-restricted-insns=", &rs6000_sched_restricted_insns_priority_str, \
......@@ -475,6 +492,8 @@ extern const char *rs6000_sched_restricted_insns_priority_str;
extern int rs6000_sched_restricted_insns_priority;
extern const char *rs6000_sched_costly_dep_str;
extern enum rs6000_dependence_cost rs6000_sched_costly_dep;
extern const char *rs6000_sched_insert_nops_str;
extern enum rs6000_nop_insertion rs6000_sched_insert_nops;
/* Alignment options for fields in structures for sub-targets following
AIX-like ABI.
......@@ -501,6 +520,11 @@ extern enum rs6000_dependence_cost rs6000_sched_costly_dep;
/* Define if the target has restricted dispatch slot instructions. */
#define DEFAULT_RESTRICTED_INSNS_PRIORITY (rs6000_cpu == PROCESSOR_POWER4 ? 1 : 0)
/* Set a default value for post scheduling nop insertion scheme
(used by taget hook sched_finish). */
#define DEFAULT_SCHED_FINISH_NOP_INSERTION_SCHEME \
(rs6000_cpu == PROCESSOR_POWER4 ? sched_finish_regroup_exact : sched_finish_none)
/* Define TARGET_MFCRF if the target assembler supports the optional
field operand for mfcr and the target processor supports the
instruction. */
......
......@@ -435,6 +435,7 @@ in the following sections.
-mdynamic-no-pic @gol
-mprioritize-restricted-insns=@var{priority} @gol
-msched-costly-dep=@var{dependence_type} @gol
-minsert-sched-nops=@var{scheme} @gol
-mcall-sysv -mcall-netbsd @gol
-maix-struct-return -msvr4-struct-return @gol
-mabi=altivec -mabi=no-altivec @gol
......@@ -7590,6 +7591,20 @@ by the target during instruction scheduling. The argument
@var{store_to_load}: any dependence from store to load is costly,
@var{number}: any dependence which latency >= @var{number} is costly.
@item -minsert-sched-nops=@var{scheme}
@opindex minsert-sched-nops
This option controls which nop insertion scheme will be used during
the second scheduling pass. The argument @var{scheme} takes one of the
following values:
@var{no}: Don't insert nops.
@var{pad}: Pad with nops any dispatch group which has vacant issue slots,
according to the scheduler's grouping.
@var{regroup_exact}: Insert nops to force costly dependent insns into
separate groups. Insert exactly as many nops as needed to force an insn
to a new group, according to the estimatied processor grouping.
@var{number}: Insert nops to force costly dependent insns into
separate groups. Insert @var{number} nops to force an insn to a new group.
@item -mcall-sysv
@opindex mcall-sysv
On System V.4 and embedded PowerPC systems compile code using calling
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment