Do the homework
As Cordelli did for you with Singapore, you should research the max dimensions and weight for each carrier/class and then buy a bag no larger than the most restrictive.
When you purchase, make sure you include the handles and other protrusions. They count, but many manufacturers don't include those items and that may lead to your carryon being rejected by some carriers at some stations.