mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-24 19:52:54 +01:00
Fix bogus warning and simplify code
llvm-svn: 10924
This commit is contained in:
parent
7f7b7be528
commit
a509b856f9
@ -509,21 +509,15 @@ void BytecodeParser::ParseCompactionTable(const unsigned char *&Buf,
|
||||
const unsigned char *End) {
|
||||
|
||||
while (Buf != End) {
|
||||
unsigned NumEntries;
|
||||
unsigned NumEntries = read_vbr_uint(Buf, End);
|
||||
unsigned Ty;
|
||||
|
||||
NumEntries = read_vbr_uint(Buf, End);
|
||||
switch (NumEntries & 3) {
|
||||
case 0:
|
||||
case 1:
|
||||
case 2:
|
||||
Ty = NumEntries >> 2;
|
||||
NumEntries &= 3;
|
||||
break;
|
||||
case 3:
|
||||
if ((NumEntries & 3) == 3) {
|
||||
NumEntries >>= 2;
|
||||
Ty = read_vbr_uint(Buf, End);
|
||||
break;
|
||||
} else {
|
||||
Ty = NumEntries >> 2;
|
||||
NumEntries &= 3;
|
||||
}
|
||||
|
||||
if (Ty >= CompactionTable.size())
|
||||
|
Loading…
Reference in New Issue
Block a user