diff options
author | Ali Ijaz Sheikh <ofrobots@google.com> | 2015-11-30 21:22:40 -0800 |
---|---|---|
committer | Ali Ijaz Sheikh <ofrobots@google.com> | 2015-12-04 00:06:01 -0800 |
commit | 8a43a3d7619fde59f0d1f2fad05d8ae7d1732b02 (patch) | |
tree | 8698af91526d0eac90840dcba1e5b565160105c4 /deps/v8/src/compiler/x87 | |
parent | 8a2acd4cc9807510786b4b6f7ad3a947aeb3a14c (diff) | |
download | node-new-8a43a3d7619fde59f0d1f2fad05d8ae7d1732b02.tar.gz |
deps: upgrade V8 to 4.7.80.24
Pick up the latest branch head for V8 4.7:
https://github.com/v8/v8/commit/be169f8df059040e6a53ec1dd4579d8bca2167b5
Full change history for the 4.7 branch:
https://chromium.googlesource.com/v8/v8.git/+log/branch-heads/4.7
V8 blog post about what is new on V8 4.7:
http://v8project.blogspot.de/2015/10/v8-release-47.html
PR-URL: https://github.com/nodejs/node/pull/4106
Reviewed-By: bnoordhuis - Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: targos - Michaƫl Zasso <mic.besace@gmail.com>
Reviewed-By: rvagg - Rod Vagg <rod@vagg.org>
Diffstat (limited to 'deps/v8/src/compiler/x87')
-rw-r--r-- | deps/v8/src/compiler/x87/code-generator-x87.cc | 50 | ||||
-rw-r--r-- | deps/v8/src/compiler/x87/instruction-codes-x87.h | 2 | ||||
-rw-r--r-- | deps/v8/src/compiler/x87/instruction-selector-x87.cc | 19 |
3 files changed, 60 insertions, 11 deletions
diff --git a/deps/v8/src/compiler/x87/code-generator-x87.cc b/deps/v8/src/compiler/x87/code-generator-x87.cc index d39fda6761..9ca9a3076f 100644 --- a/deps/v8/src/compiler/x87/code-generator-x87.cc +++ b/deps/v8/src/compiler/x87/code-generator-x87.cc @@ -1069,6 +1069,28 @@ void CodeGenerator::AssembleArchInstruction(Instruction* instr) { } break; } + case kX87BitcastFI: { + __ fstp(0); + __ mov(i.OutputRegister(), MemOperand(esp, 0)); + __ lea(esp, Operand(esp, kFloatSize)); + break; + } + case kX87BitcastIF: { + if (instr->InputAt(0)->IsRegister()) { + __ lea(esp, Operand(esp, -kFloatSize)); + __ mov(MemOperand(esp, 0), i.InputRegister(0)); + __ fstp(0); + __ fld_s(MemOperand(esp, 0)); + __ lea(esp, Operand(esp, kFloatSize)); + } else { + __ lea(esp, Operand(esp, -kDoubleSize)); + __ mov(MemOperand(esp, 0), i.InputRegister(0)); + __ fstp(0); + __ fld_d(MemOperand(esp, 0)); + __ lea(esp, Operand(esp, kDoubleSize)); + } + break; + } case kX87Lea: { AddressingMode mode = AddressingModeField::decode(instr->opcode()); // Shorten "leal" to "addl", "subl" or "shll" if the register allocation @@ -1224,6 +1246,10 @@ void CodeGenerator::AssembleArchInstruction(Instruction* instr) { __ cmp(esp, Operand::StaticVariable(stack_limit)); break; } + case kCheckedLoadWord64: + case kCheckedStoreWord64: + UNREACHABLE(); // currently unsupported checked int64 load/store. + break; } } // NOLINT(readability/fn_size) @@ -1278,6 +1304,9 @@ void CodeGenerator::AssembleArchBranch(Instruction* instr, BranchInfo* branch) { case kNotOverflow: __ j(no_overflow, tlabel); break; + default: + UNREACHABLE(); + break; } // Add a jump if not falling through to the next block. if (!branch->fallthru) __ jmp(flabel); @@ -1348,6 +1377,9 @@ void CodeGenerator::AssembleArchBoolean(Instruction* instr, case kNotOverflow: cc = no_overflow; break; + default: + UNREACHABLE(); + break; } __ bind(&check); if (reg.is_byte_register()) { @@ -1838,15 +1870,17 @@ void CodeGenerator::AddNopForSmiCodeInlining() { __ nop(); } void CodeGenerator::EnsureSpaceForLazyDeopt() { + if (!info()->ShouldEnsureSpaceForLazyDeopt()) { + return; + } + int space_needed = Deoptimizer::patch_size(); - if (!info()->IsStub()) { - // Ensure that we have enough space after the previous lazy-bailout - // instruction for patching the code here. - int current_pc = masm()->pc_offset(); - if (current_pc < last_lazy_deopt_pc_ + space_needed) { - int padding_size = last_lazy_deopt_pc_ + space_needed - current_pc; - __ Nop(padding_size); - } + // Ensure that we have enough space after the previous lazy-bailout + // instruction for patching the code here. + int current_pc = masm()->pc_offset(); + if (current_pc < last_lazy_deopt_pc_ + space_needed) { + int padding_size = last_lazy_deopt_pc_ + space_needed - current_pc; + __ Nop(padding_size); } } diff --git a/deps/v8/src/compiler/x87/instruction-codes-x87.h b/deps/v8/src/compiler/x87/instruction-codes-x87.h index d1b759be34..9408e41724 100644 --- a/deps/v8/src/compiler/x87/instruction-codes-x87.h +++ b/deps/v8/src/compiler/x87/instruction-codes-x87.h @@ -74,6 +74,8 @@ namespace compiler { V(X87Movss) \ V(X87Movsd) \ V(X87Lea) \ + V(X87BitcastFI) \ + V(X87BitcastIF) \ V(X87Push) \ V(X87PushFloat64) \ V(X87PushFloat32) \ diff --git a/deps/v8/src/compiler/x87/instruction-selector-x87.cc b/deps/v8/src/compiler/x87/instruction-selector-x87.cc index 95aa70ac92..ac868fb932 100644 --- a/deps/v8/src/compiler/x87/instruction-selector-x87.cc +++ b/deps/v8/src/compiler/x87/instruction-selector-x87.cc @@ -40,9 +40,9 @@ class X87OperandGenerator final : public OperandGenerator { case IrOpcode::kHeapConstant: { // Constants in new space cannot be used as immediates in V8 because // the GC does not scan code objects when collecting the new generation. - Unique<HeapObject> value = OpParameter<Unique<HeapObject> >(node); - Isolate* isolate = value.handle()->GetIsolate(); - return !isolate->heap()->InNewSpace(*value.handle()); + Handle<HeapObject> value = OpParameter<Handle<HeapObject>>(node); + Isolate* isolate = value->GetIsolate(); + return !isolate->heap()->InNewSpace(*value); } default: return false; @@ -664,6 +664,19 @@ void InstructionSelector::VisitTruncateFloat64ToInt32(Node* node) { } +void InstructionSelector::VisitBitcastFloat32ToInt32(Node* node) { + X87OperandGenerator g(this); + Emit(kX87PushFloat32, g.NoOutput(), g.Use(node->InputAt(0))); + Emit(kX87BitcastFI, g.DefineAsRegister(node), 0, NULL); +} + + +void InstructionSelector::VisitBitcastInt32ToFloat32(Node* node) { + X87OperandGenerator g(this); + Emit(kX87BitcastIF, g.DefineAsFixed(node, stX_0), g.Use(node->InputAt(0))); +} + + void InstructionSelector::VisitFloat32Add(Node* node) { X87OperandGenerator g(this); Emit(kX87PushFloat32, g.NoOutput(), g.Use(node->InputAt(0))); |