Another missing feature here is recursion -- what if the join's first child is not an index scan but is another join that happens to have a valid sort direction?