| 472 | } |
| 473 | |
| 474 | S32 TSThread::operator<(const TSThread & th2) const |
| 475 | { |
| 476 | if (getSequence()->isBlend() == th2.getSequence()->isBlend()) |
| 477 | { |
| 478 | // both blend or neither blend, sort based on priority only -- higher priority first |
| 479 | S32 ret = 0; // do it this way to (hopefully) take advantage of 'conditional move' assembly instruction |
| 480 | if (priority > th2.priority) |
| 481 | ret = -1; |
| 482 | if (th2.priority > priority) |
| 483 | ret = 1; |
| 484 | return ret; |
| 485 | } |
| 486 | else |
| 487 | { |
| 488 | // one is blend, the other is not...sort based on blend -- non-blended first |
| 489 | AssertFatal(!getSequence()->isBlend() || !th2.getSequence()->isBlend(),"compareThreads: unequal 'trues'"); |
| 490 | |
| 491 | S32 ret = -1; // do it this way to (hopefully) take advantage of 'conditional move' assembly instruction |
| 492 | if (getSequence()->isBlend()) |
| 493 | ret = 1; |
| 494 | return ret; |
| 495 | } |
| 496 | } |
| 497 | |
| 498 | |
| 499 | //------------------------------------------------------------------------------------- |
nothing calls this directly
no test coverage detected