diff options
| author | Quentin Colombet <qcolombet@apple.com> | 2016-04-05 20:21:53 +0000 |
|---|---|---|
| committer | Quentin Colombet <qcolombet@apple.com> | 2016-04-05 20:21:53 +0000 |
| commit | 47de6c7ff48480ebc7953681175acbc5aae9c0e9 (patch) | |
| tree | 12a394e006a07c0a167505800d8b43fa69bc5a20 | |
| parent | 1760dc2a232bde2175606ba737938d3032f1e49d (diff) | |
| download | bcm5719-llvm-47de6c7ff48480ebc7953681175acbc5aae9c0e9.tar.gz bcm5719-llvm-47de6c7ff48480ebc7953681175acbc5aae9c0e9.zip | |
[TargetRegisterClass] Improve the comment for how to use getSubClassMask.
llvm-svn: 265455
| -rw-r--r-- | llvm/include/llvm/Target/TargetRegisterInfo.h | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/llvm/include/llvm/Target/TargetRegisterInfo.h b/llvm/include/llvm/Target/TargetRegisterInfo.h index ff5147e6f1b..4a5db1288d8 100644 --- a/llvm/include/llvm/Target/TargetRegisterInfo.h +++ b/llvm/include/llvm/Target/TargetRegisterInfo.h @@ -161,8 +161,21 @@ public: } /// Returns a bit vector of subclasses, including this one. - /// The vector is indexed by class IDs, see hasSubClassEq() above for how to - /// use it. + /// The vector is indexed by class IDs. + /// + /// To use it, consider the returned array as a chunk of memory that + /// contains an array of bits of size NumRegClasses. Each 32-bit chunk + /// contains a bitset of the ID of the subclasses in big-endian style. + + /// I.e., the representation of the memory from left to right at the + /// bit level looks like: + /// [31 30 ... 1 0] [ 63 62 ... 33 32] ... + /// [ XXX NumRegClasses NumRegClasses - 1 ... ] + /// Where the number represents the class ID and XXX bits that + /// should be ignored. + /// + /// See the implementation of hasSubClassEq for an example of how it + /// can be used. const uint32_t *getSubClassMask() const { return SubClassMask; } |

