<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><div>On Dec 19, 2011, at 11:20 PM, Andrew Trick wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><br><div><div>On Dec 19, 2011, at 10:53 PM, Hal Finkel wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><span class="Apple-style-span" style="border-collapse: separate; font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; font-size: medium; ">Here's my "thought experiment" (from PR11589): I have a bunch of<br>load-fadd-store chains to schedule. A store takes two cycles to clear<br>its last pipeline stage. The fadd takes longer to compute its result<br>(say 5 cycles), but can sustain a rate of 1 independent add per cycle.<br>As the scheduling is bottom-up, it will schedule a store, then it has a<br>choice: it can schedule another store (at a 1 cycle penalty), or it can<br>schedule the fadd associated with the store it just scheduled (with a 4<br>cycle penalty due to operand latency). It seems that the current hybrid<br>scheduler will choose the fadd, I want a scheduler that will make the<br>opposite choice.<br></span></blockquote></div><br><div>That's just wrong. You may need to look at -debug-only=pre-RA-sched and debug your itinerary.</div><div><br></div><div>-Andy</div></div></blockquote></div><br><div><br></div><div>Wait… if you're using "sched=ilp" then register pressure avoidance is the primary heuristic. So, yes, it will schedule each chain individually as long as the critical path is not *too* long.</div><div><br></div><div>sched=hybrid will only behave like this when it determines that register pressure is high. You  have to make sure that the register pressure limit is implemented properly for your target. debug-only=pre-RA-sched will show you the number of locally live register out of the total available each time an instruction is scheduled.</div><div><br></div><div>-Andy</div></body></html>