[CUDA][HIP] Fix typo in BestViableFunction
- Should consider viable ones only when checking SameSide candidates.
- Replace erasing with clearing viable flag to reduce data moving/copying.
- Add one and revise another one as the diagnostic message are more relevant compared to previous one.
Subscribers: cfe-commits, yaxunl
Differential Revision: https://reviews.llvm.org/D67730