| OLD | NEW |
| 1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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/linkage.h" | 5 #include "src/compiler/linkage.h" |
| 6 | 6 |
| 7 #include "src/code-stubs.h" | 7 #include "src/code-stubs.h" |
| 8 #include "src/compiler.h" | 8 #include "src/compiler.h" |
| 9 #include "src/compiler/node.h" | 9 #include "src/compiler/node.h" |
| 10 #include "src/compiler/pipeline.h" | 10 #include "src/compiler/pipeline.h" |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 45 // plus the receiver. | 45 // plus the receiver. |
| 46 incoming_ = GetJSCallDescriptor(1 + info->function()->parameter_count()); | 46 incoming_ = GetJSCallDescriptor(1 + info->function()->parameter_count()); |
| 47 } else if (!info->closure().is_null()) { | 47 } else if (!info->closure().is_null()) { |
| 48 // If we are compiling a JS function, use a JS call descriptor, | 48 // If we are compiling a JS function, use a JS call descriptor, |
| 49 // plus the receiver. | 49 // plus the receiver. |
| 50 SharedFunctionInfo* shared = info->closure()->shared(); | 50 SharedFunctionInfo* shared = info->closure()->shared(); |
| 51 incoming_ = GetJSCallDescriptor(1 + shared->formal_parameter_count()); | 51 incoming_ = GetJSCallDescriptor(1 + shared->formal_parameter_count()); |
| 52 } else if (info->code_stub() != NULL) { | 52 } else if (info->code_stub() != NULL) { |
| 53 // Use the code stub interface descriptor. | 53 // Use the code stub interface descriptor. |
| 54 HydrogenCodeStub* stub = info->code_stub(); | 54 HydrogenCodeStub* stub = info->code_stub(); |
| 55 CodeStubInterfaceDescriptor* descriptor = | 55 CodeStubInterfaceDescriptor descriptor; |
| 56 info_->isolate()->code_stub_interface_descriptor(stub->MajorKey()); | 56 stub->InitializeInterfaceDescriptor(&descriptor); |
| 57 incoming_ = GetStubCallDescriptor(descriptor); | 57 incoming_ = GetStubCallDescriptor(&descriptor); |
| 58 } else { | 58 } else { |
| 59 incoming_ = NULL; // TODO(titzer): ? | 59 incoming_ = NULL; // TODO(titzer): ? |
| 60 } | 60 } |
| 61 } | 61 } |
| 62 | 62 |
| 63 | 63 |
| 64 FrameOffset Linkage::GetFrameOffset(int spill_slot, Frame* frame, int extra) { | 64 FrameOffset Linkage::GetFrameOffset(int spill_slot, Frame* frame, int extra) { |
| 65 if (frame->GetSpillSlotCount() > 0 || incoming_->IsJSFunctionCall() || | 65 if (frame->GetSpillSlotCount() > 0 || incoming_->IsJSFunctionCall() || |
| 66 incoming_->kind() == CallDescriptor::kCallAddress) { | 66 incoming_->kind() == CallDescriptor::kCallAddress) { |
| 67 int offset; | 67 int offset; |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 157 | 157 |
| 158 CallDescriptor* Linkage::GetSimplifiedCDescriptor(Zone* zone, | 158 CallDescriptor* Linkage::GetSimplifiedCDescriptor(Zone* zone, |
| 159 MachineSignature* sig) { | 159 MachineSignature* sig) { |
| 160 UNIMPLEMENTED(); | 160 UNIMPLEMENTED(); |
| 161 return NULL; | 161 return NULL; |
| 162 } | 162 } |
| 163 #endif // !V8_TURBOFAN_BACKEND | 163 #endif // !V8_TURBOFAN_BACKEND |
| 164 } | 164 } |
| 165 } | 165 } |
| 166 } // namespace v8::internal::compiler | 166 } // namespace v8::internal::compiler |
| OLD | NEW |