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

Side by Side Diff: src/compiler/arm64/linkage-arm64.cc

Issue 426233002: Land the Fan (disabled) (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Review feedback, rebase and "git cl format" Created 6 years, 4 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 | Annotate | Revision Log
« no previous file with comments | « src/compiler/arm64/instruction-selector-arm64.cc ('k') | src/compiler/ast-graph-builder.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "src/v8.h"
6
7 #include "src/assembler.h"
8 #include "src/code-stubs.h"
9 #include "src/compiler/linkage.h"
10 #include "src/compiler/linkage-impl.h"
11 #include "src/zone.h"
12
13 namespace v8 {
14 namespace internal {
15 namespace compiler {
16
17 struct LinkageHelperTraits {
18 static Register ReturnValueReg() { return x0; }
19 static Register ReturnValue2Reg() { return x1; }
20 static Register JSCallFunctionReg() { return x1; }
21 static Register ContextReg() { return cp; }
22 static Register RuntimeCallFunctionReg() { return x1; }
23 static Register RuntimeCallArgCountReg() { return x0; }
24 static RegList CCalleeSaveRegisters() {
25 // TODO(dcarney): correct callee saved registers.
26 return 0;
27 }
28 static Register CRegisterParameter(int i) {
29 static Register register_parameters[] = {x0, x1, x2, x3, x4, x5, x6, x7};
30 return register_parameters[i];
31 }
32 static int CRegisterParametersLength() { return 8; }
33 };
34
35
36 CallDescriptor* Linkage::GetJSCallDescriptor(int parameter_count, Zone* zone) {
37 return LinkageHelper::GetJSCallDescriptor<LinkageHelperTraits>(
38 zone, parameter_count);
39 }
40
41
42 CallDescriptor* Linkage::GetRuntimeCallDescriptor(
43 Runtime::FunctionId function, int parameter_count,
44 Operator::Property properties,
45 CallDescriptor::DeoptimizationSupport can_deoptimize, Zone* zone) {
46 return LinkageHelper::GetRuntimeCallDescriptor<LinkageHelperTraits>(
47 zone, function, parameter_count, properties, can_deoptimize);
48 }
49
50
51 CallDescriptor* Linkage::GetStubCallDescriptor(
52 CodeStubInterfaceDescriptor* descriptor, int stack_parameter_count) {
53 return LinkageHelper::GetStubCallDescriptor<LinkageHelperTraits>(
54 this->info_->zone(), descriptor, stack_parameter_count);
55 }
56
57
58 CallDescriptor* Linkage::GetSimplifiedCDescriptor(
59 Zone* zone, int num_params, MachineRepresentation return_type,
60 const MachineRepresentation* param_types) {
61 return LinkageHelper::GetSimplifiedCDescriptor<LinkageHelperTraits>(
62 zone, num_params, return_type, param_types);
63 }
64 }
65 }
66 } // namespace v8::internal::compiler
OLDNEW
« no previous file with comments | « src/compiler/arm64/instruction-selector-arm64.cc ('k') | src/compiler/ast-graph-builder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698