diff options
| author | Ahmed Bougacha <ahmed.bougacha@gmail.com> | 2015-01-07 18:39:00 +0000 |
|---|---|---|
| committer | Ahmed Bougacha <ahmed.bougacha@gmail.com> | 2015-01-07 18:39:00 +0000 |
| commit | a776a932cc3ceaeab2c8c8e4482b830cc89f30fc (patch) | |
| tree | d736a0fba34ed66a6b598a47b4c643f33ee91b20 | |
| parent | eac50037fb01dff75fda73c32ceebc7b34afd11d (diff) | |
| download | bcm5719-llvm-a776a932cc3ceaeab2c8c8e4482b830cc89f30fc.tar.gz bcm5719-llvm-a776a932cc3ceaeab2c8c8e4482b830cc89f30fc.zip | |
[CodeGen] Add MVT::FIRST_VALUETYPE to avoid explicit 0. NFC.
Many places reference MVT::LAST_VALUETYPE when iterating over all
valid MVTs, but they usually start with 0.
With FIRST_VALUETYPE, we can avoid explicit constants when we really
should be using MVT::SimpleValueType.
llvm-svn: 225362
| -rw-r--r-- | llvm/include/llvm/CodeGen/MachineValueType.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/llvm/include/llvm/CodeGen/MachineValueType.h b/llvm/include/llvm/CodeGen/MachineValueType.h index affacb095b5..dfb40150755 100644 --- a/llvm/include/llvm/CodeGen/MachineValueType.h +++ b/llvm/include/llvm/CodeGen/MachineValueType.h @@ -118,6 +118,7 @@ namespace llvm { // unspecified type. The register class // will be determined by the opcode. + FIRST_VALUETYPE = 0, // This is always the beginning of the list. LAST_VALUETYPE = 58, // This always remains at the end of the list. // This is the current maximum for LAST_VALUETYPE. |

