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

Unified Diff: src/compiler/ppc/linkage-ppc.cc

Issue 901083004: Contribution of PowerPC port (continuation of 422063005) - PPC dir update (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Contribution of PowerPC port (continuation of 422063005) - PPC dir update -comments and rebase Created 5 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/compiler/ppc/instruction-selector-ppc.cc ('k') | src/ic/ppc/handler-compiler-ppc.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/ppc/linkage-ppc.cc
diff --git a/src/compiler/arm64/linkage-arm64.cc b/src/compiler/ppc/linkage-ppc.cc
similarity index 72%
copy from src/compiler/arm64/linkage-arm64.cc
copy to src/compiler/ppc/linkage-ppc.cc
index 352a4bcd969c50873235f7175c47cbbf9f6b9e22..96dcaaa5b2bc6df16b438ce94d70de1833da2a6a 100644
--- a/src/compiler/arm64/linkage-arm64.cc
+++ b/src/compiler/ppc/linkage-ppc.cc
@@ -14,26 +14,28 @@ namespace v8 {
namespace internal {
namespace compiler {
-struct Arm64LinkageHelperTraits {
- static Register ReturnValueReg() { return x0; }
- static Register ReturnValue2Reg() { return x1; }
- static Register JSCallFunctionReg() { return x1; }
+struct PPCLinkageHelperTraits {
+ static Register ReturnValueReg() { return r3; }
+ static Register ReturnValue2Reg() { return r4; }
+ static Register JSCallFunctionReg() { return r4; }
static Register ContextReg() { return cp; }
- static Register RuntimeCallFunctionReg() { return x1; }
- static Register RuntimeCallArgCountReg() { return x0; }
+ static Register RuntimeCallFunctionReg() { return r4; }
+ static Register RuntimeCallArgCountReg() { return r3; }
static RegList CCalleeSaveRegisters() {
- // TODO(dcarney): correct callee saved registers.
- return 0;
+ return r14.bit() | r15.bit() | r16.bit() | r17.bit() | r18.bit() |
+ r19.bit() | r20.bit() | r21.bit() | r22.bit() | r23.bit() |
+ r24.bit() | r25.bit() | r26.bit() | r27.bit() | r28.bit() |
+ r29.bit() | r30.bit() | fp.bit();
}
static Register CRegisterParameter(int i) {
- static Register register_parameters[] = {x0, x1, x2, x3, x4, x5, x6, x7};
+ static Register register_parameters[] = {r3, r4, r5, r6, r7, r8, r9, r10};
return register_parameters[i];
}
static int CRegisterParametersLength() { return 8; }
};
-typedef LinkageHelper<Arm64LinkageHelperTraits> LH;
+typedef LinkageHelper<PPCLinkageHelperTraits> LH;
CallDescriptor* Linkage::GetJSCallDescriptor(Zone* zone, bool is_osr,
int parameter_count,
« no previous file with comments | « src/compiler/ppc/instruction-selector-ppc.cc ('k') | src/ic/ppc/handler-compiler-ppc.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698