diff options
author | Thomas Lively <tlively@google.com> | 2018-11-09 01:45:56 +0000 |
---|---|---|
committer | Thomas Lively <tlively@google.com> | 2018-11-09 01:45:56 +0000 |
commit | 299d214aba0dbec3bf50f7db9fa1961f400182f8 (patch) | |
tree | 4203e551c4df082749032dd64967924c2a20558c /llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCCodeEmitter.cpp | |
parent | 38c902bc2e50c000fef9aa47f1426be974383a00 (diff) | |
download | bcm5719-llvm-299d214aba0dbec3bf50f7db9fa1961f400182f8.tar.gz bcm5719-llvm-299d214aba0dbec3bf50f7db9fa1961f400182f8.zip |
[WebAssembly] Renumber and LEB128-encode SIMD opcodes
Reviewers: aheejin, dschuff, aardappel
Subscribers: sbc100, jgravelle-google, sunfish, llvm-commits
Differential Revision: https://reviews.llvm.org/D54126
llvm-svn: 346463
Diffstat (limited to 'llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCCodeEmitter.cpp')
-rw-r--r-- | llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCCodeEmitter.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCCodeEmitter.cpp b/llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCCodeEmitter.cpp index fa399371f2c..53b69eaf005 100644 --- a/llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCCodeEmitter.cpp +++ b/llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCCodeEmitter.cpp @@ -67,7 +67,8 @@ void WebAssemblyMCCodeEmitter::encodeInstruction( OS << uint8_t(Binary); } else { assert(Binary <= UINT16_MAX && "Several-byte opcodes not supported yet"); - OS << uint8_t(Binary >> 8) << uint8_t(Binary); + OS << uint8_t(Binary >> 8); + encodeULEB128(uint8_t(Binary), OS); } // For br_table instructions, encode the size of the table. In the MCInst, |