This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Question of the DFA scheduler


"Ling-hua Tseng" <uranus@it.muds.net> writes:
> The destination operand of the `sub' instruction, d0, will be written
> back in the 4th cycle, and the instruction `max' will use it as source
> operand (i.e., there is a true data dependency).
>
> I figured out that the state_transition() returns -1 when I issuing
> the `max' instruction, and I figured out it only returns > 0 when
> "hardware structural hazard" occured.

Right.  state_transition just checks for unit hazards, not data hazards.

Instruction dependencies are detected by sched-deps.c and stored in the
instructions' LOG_LINKS.  insn_latency (in insn-attrtab.c) gives the
latency for two dependent instructions.

Richard


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]