Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(335)

Side by Side Diff: lib/Bitcode/NaCl/Reader/NaClBitstreamReader.cpp

Issue 1974883002: Remove compiler warning when building. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-llvm.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 //===- NaClBitstreamReader.cpp --------------------------------------------===// 1 //===- NaClBitstreamReader.cpp --------------------------------------------===//
2 // NaClBitstreamReader implementation 2 // NaClBitstreamReader implementation
3 // 3 //
4 // The LLVM Compiler Infrastructure 4 // The LLVM Compiler Infrastructure
5 // 5 //
6 // This file is distributed under the University of Illinois Open Source 6 // This file is distributed under the University of Illinois Open Source
7 // License. See LICENSE.TXT for details. 7 // License. See LICENSE.TXT for details.
8 // 8 //
9 //===----------------------------------------------------------------------===// 9 //===----------------------------------------------------------------------===//
10 10
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 (void)ReadVBR64((unsigned)Op.getValue()); 99 (void)ReadVBR64((unsigned)Op.getValue());
100 break; 100 break;
101 case NaClBitCodeAbbrevOp::Array: 101 case NaClBitCodeAbbrevOp::Array:
102 // This can't happen because the abbreviation must be valid. 102 // This can't happen because the abbreviation must be valid.
103 llvm_unreachable("Bad array abbreviation encoding!"); 103 llvm_unreachable("Bad array abbreviation encoding!");
104 break; 104 break;
105 case NaClBitCodeAbbrevOp::Char6: 105 case NaClBitCodeAbbrevOp::Char6:
106 (void)Read(6); 106 (void)Read(6);
107 break; 107 break;
108 } 108 }
109 llvm_unreachable("Illegal abbreviation encoding for field!");
109 } 110 }
110 111
111 /// skipRecord - Read the current record and discard it. 112 /// skipRecord - Read the current record and discard it.
112 void NaClBitstreamCursor::skipRecord(unsigned AbbrevID) { 113 void NaClBitstreamCursor::skipRecord(unsigned AbbrevID) {
113 // Skip unabbreviated records by reading past their entries. 114 // Skip unabbreviated records by reading past their entries.
114 if (AbbrevID == naclbitc::UNABBREV_RECORD) { 115 if (AbbrevID == naclbitc::UNABBREV_RECORD) {
115 unsigned Code = ReadVBR(6); 116 unsigned Code = ReadVBR(6);
116 (void)Code; 117 (void)Code;
117 unsigned NumElts = ReadVBR(6); 118 unsigned NumElts = ReadVBR(6);
118 for (unsigned i = 0; i != NumElts; ++i) 119 for (unsigned i = 0; i != NumElts; ++i)
(...skipping 316 matching lines...) Expand 10 before | Expand all | Expand 10 after
435 UpdateAbbrevs = 436 UpdateAbbrevs =
436 &BitStream->getBlockInfo((unsigned)Record[0])->getAbbrevs(); 437 &BitStream->getBlockInfo((unsigned)Record[0])->getAbbrevs();
437 if (Listener) { 438 if (Listener) {
438 Listener->Values = Record; 439 Listener->Values = Record;
439 Listener->SetBID(); 440 Listener->SetBID();
440 } 441 }
441 break; 442 break;
442 } 443 }
443 } 444 }
444 } 445 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698