[PATCH] D38988: [PowerPC] Use helper functions to check sign-/zero-extended value

Hiroshi Inoue via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 17 22:53:40 PDT 2017


inouehrs added a comment.

In https://reviews.llvm.org/D38988#899532, @nemanjai wrote:

> And FWIW, I still don't like the names of these helper functions. There isn't really much indication in the name what it is sign/zero extending from/to. Presume I want to do add/remove an instruction depending on whether the input is known to be sign-extended from a halfword to a doubleword, but not if it is only known to be sign-extended from a word to a doubleword, it isn't clear how I would use these functions to determine that.


Is `isSignExtendedFromWord` better? Other candidates I have are `isSignExtendedWord` or `isSignExtended_32_64`. Any suggestions?


https://reviews.llvm.org/D38988





More information about the llvm-commits mailing list