OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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 #include "src/compiler/code-generator.h" | 5 #include "src/compiler/code-generator.h" |
6 | 6 |
7 #include "src/compilation-info.h" | 7 #include "src/compilation-info.h" |
8 #include "src/compiler/code-generator-impl.h" | 8 #include "src/compiler/code-generator-impl.h" |
9 #include "src/compiler/gap-resolver.h" | 9 #include "src/compiler/gap-resolver.h" |
10 #include "src/compiler/node-matchers.h" | 10 #include "src/compiler/node-matchers.h" |
(...skipping 2522 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2533 __ Ret(static_cast<int>(pop_size), ecx); | 2533 __ Ret(static_cast<int>(pop_size), ecx); |
2534 } else { | 2534 } else { |
2535 Register pop_reg = g.ToRegister(pop); | 2535 Register pop_reg = g.ToRegister(pop); |
2536 Register scratch_reg = pop_reg.is(ecx) ? edx : ecx; | 2536 Register scratch_reg = pop_reg.is(ecx) ? edx : ecx; |
2537 __ pop(scratch_reg); | 2537 __ pop(scratch_reg); |
2538 __ lea(esp, Operand(esp, pop_reg, times_4, static_cast<int>(pop_size))); | 2538 __ lea(esp, Operand(esp, pop_reg, times_4, static_cast<int>(pop_size))); |
2539 __ jmp(scratch_reg); | 2539 __ jmp(scratch_reg); |
2540 } | 2540 } |
2541 } | 2541 } |
2542 | 2542 |
| 2543 void CodeGenerator::FinishCode() {} |
2543 | 2544 |
2544 void CodeGenerator::AssembleMove(InstructionOperand* source, | 2545 void CodeGenerator::AssembleMove(InstructionOperand* source, |
2545 InstructionOperand* destination) { | 2546 InstructionOperand* destination) { |
2546 X87OperandConverter g(this, nullptr); | 2547 X87OperandConverter g(this, nullptr); |
2547 // Dispatch on the source and destination operand kinds. Not all | 2548 // Dispatch on the source and destination operand kinds. Not all |
2548 // combinations are possible. | 2549 // combinations are possible. |
2549 if (source->IsRegister()) { | 2550 if (source->IsRegister()) { |
2550 DCHECK(destination->IsRegister() || destination->IsStackSlot()); | 2551 DCHECK(destination->IsRegister() || destination->IsStackSlot()); |
2551 Register src = g.ToRegister(source); | 2552 Register src = g.ToRegister(source); |
2552 Operand dst = g.ToOperand(destination); | 2553 Operand dst = g.ToOperand(destination); |
(...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2762 int padding_size = last_lazy_deopt_pc_ + space_needed - current_pc; | 2763 int padding_size = last_lazy_deopt_pc_ + space_needed - current_pc; |
2763 __ Nop(padding_size); | 2764 __ Nop(padding_size); |
2764 } | 2765 } |
2765 } | 2766 } |
2766 | 2767 |
2767 #undef __ | 2768 #undef __ |
2768 | 2769 |
2769 } // namespace compiler | 2770 } // namespace compiler |
2770 } // namespace internal | 2771 } // namespace internal |
2771 } // namespace v8 | 2772 } // namespace v8 |
OLD | NEW |