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

Side by Side Diff: src/mips64/disasm-mips64.cc

Issue 2374013004: MIPS32: Remove EXTRA, NORMAL instruction type check. (Closed)
Patch Set: Fix indentation. Created 4 years, 2 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 | « src/mips64/constants-mips64.h ('k') | src/mips64/simulator-mips64.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // A Disassembler object is used to disassemble a block of code instruction by 5 // A Disassembler object is used to disassemble a block of code instruction by
6 // instruction. The default implementation of the NameConverter object can be 6 // instruction. The default implementation of the NameConverter object can be
7 // overriden to modify register names or to do symbol lookup on addresses. 7 // overriden to modify register names or to do symbol lookup on addresses.
8 // 8 //
9 // The example below will disassemble a block of code and print it to stdout. 9 // The example below will disassemble a block of code and print it to stdout.
10 // 10 //
(...skipping 1928 matching lines...) Expand 10 before | Expand all | Expand 10 after
1939 // Disassemble the instruction at *instr_ptr into the output buffer. 1939 // Disassemble the instruction at *instr_ptr into the output buffer.
1940 // All instructions are one word long, except for the simulator 1940 // All instructions are one word long, except for the simulator
1941 // psuedo-instruction stop(msg). For that one special case, we return 1941 // psuedo-instruction stop(msg). For that one special case, we return
1942 // size larger than one kInstrSize. 1942 // size larger than one kInstrSize.
1943 int Decoder::InstructionDecode(byte* instr_ptr) { 1943 int Decoder::InstructionDecode(byte* instr_ptr) {
1944 Instruction* instr = Instruction::At(instr_ptr); 1944 Instruction* instr = Instruction::At(instr_ptr);
1945 // Print raw instruction bytes. 1945 // Print raw instruction bytes.
1946 out_buffer_pos_ += SNPrintF(out_buffer_ + out_buffer_pos_, 1946 out_buffer_pos_ += SNPrintF(out_buffer_ + out_buffer_pos_,
1947 "%08x ", 1947 "%08x ",
1948 instr->InstructionBits()); 1948 instr->InstructionBits());
1949 switch (instr->InstructionType(Instruction::TypeChecks::EXTRA)) { 1949 switch (instr->InstructionType()) {
1950 case Instruction::kRegisterType: { 1950 case Instruction::kRegisterType: {
1951 return DecodeTypeRegister(instr); 1951 return DecodeTypeRegister(instr);
1952 } 1952 }
1953 case Instruction::kImmediateType: { 1953 case Instruction::kImmediateType: {
1954 DecodeTypeImmediate(instr); 1954 DecodeTypeImmediate(instr);
1955 break; 1955 break;
1956 } 1956 }
1957 case Instruction::kJumpType: { 1957 case Instruction::kJumpType: {
1958 DecodeTypeJump(instr); 1958 DecodeTypeJump(instr);
1959 break; 1959 break;
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
2043 *reinterpret_cast<int32_t*>(prev_pc), buffer.start()); 2043 *reinterpret_cast<int32_t*>(prev_pc), buffer.start());
2044 } 2044 }
2045 } 2045 }
2046 2046
2047 2047
2048 #undef UNSUPPORTED 2048 #undef UNSUPPORTED
2049 2049
2050 } // namespace disasm 2050 } // namespace disasm
2051 2051
2052 #endif // V8_TARGET_ARCH_MIPS64 2052 #endif // V8_TARGET_ARCH_MIPS64
OLDNEW
« no previous file with comments | « src/mips64/constants-mips64.h ('k') | src/mips64/simulator-mips64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698