[llvm-commits] Speeding up instruction selection

Evan Cheng evan.cheng at apple.com
Wed Apr 2 10:48:44 PDT 2008


On Apr 2, 2008, at 1:57 AM, Roman Levenstein wrote:

> 2008/4/2, Evan Cheng <evan.cheng at apple.com>:
>>
>> On Apr 2, 2008, at 12:55 AM, Roman Levenstein wrote:
>>
>>> Hi Evan,
>>>
>>> 2008/4/1, Evan Cheng <evan.cheng at apple.com>:
>>>> Please hold off checking it in for a bit. llvm tot is having some
>>>> problems and I'd like to get to the bottom of it first.
>>>
>>> OK.
>>>
>>>> Also, the tie breaker is less than ideal. I think we need a tie-
>>>> breaker that is "the SUnit that's added to the queue is preferred".
>>>> That means it prefers nodes which are closer to the end of block.
>>>> What
>>>> do you think?
>>>
>>> Do you actually mean "the SUnit that's added to the queue LAST (or
>>> FIRST) is preferred"? I'll think about it.
>>
>>
>> Yep "first".  Basically, if all else being equal, let the node that's
>> ready first be scheduled first. We can add a order id to SUnit which
>> gets set when it's pushed into the ready queue. What do you think?
>
> Makes sense. The queue should have a global "current id" counter. Its
> current value is assigned to each node being inserted into the ready
> queue and then incremented. When the node is removed from the queue
> for any reason, its queue order id is reset. It should be rather easy
> to implement.

Yep.

>
>
> BTW, do you really want this queue order id in the SUnit or in a
> separate array indexed by SUnit unique ids?

It should be in SUnit since the sort functions don't have access to  
ScheduleDAG members.

Evan

>
>
> -Roman
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits




More information about the llvm-commits mailing list