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

Unified Diff: src/ppc/macro-assembler-ppc.cc

Issue 2141723003: PPC/s390: [builtins] Construct builtin frame in String/Number ctors (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fixed Load instr, don't have to update sp Created 4 years, 5 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/ppc/macro-assembler-ppc.h ('k') | src/s390/builtins-s390.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ppc/macro-assembler-ppc.cc
diff --git a/src/ppc/macro-assembler-ppc.cc b/src/ppc/macro-assembler-ppc.cc
index 45c35961fd262eb77c19efa7899f97153464f4d5..888987b02e9760262c550e1500f51b99393f02f9 100644
--- a/src/ppc/macro-assembler-ppc.cc
+++ b/src/ppc/macro-assembler-ppc.cc
@@ -1072,6 +1072,49 @@ int MacroAssembler::LeaveFrame(StackFrame::Type type, int stack_adjustment) {
return frame_ends;
}
+void MacroAssembler::EnterBuiltinFrame(Register context, Register target,
+ Register argc) {
+ int fp_delta = 0;
+ mflr(r0);
+ if (FLAG_enable_embedded_constant_pool) {
+ if (target.is_valid()) {
+ Push(r0, fp, kConstantPoolRegister, context, target);
+ fp_delta = 3;
+ } else {
+ Push(r0, fp, kConstantPoolRegister, context);
+ fp_delta = 2;
+ }
+ } else {
+ if (target.is_valid()) {
+ Push(r0, fp, context, target);
+ fp_delta = 2;
+ } else {
+ Push(r0, fp, context);
+ fp_delta = 1;
+ }
+ }
+ addi(fp, sp, Operand(fp_delta * kPointerSize));
+ Push(argc);
+}
+
+void MacroAssembler::LeaveBuiltinFrame(Register context, Register target,
+ Register argc) {
+ Pop(argc);
+ if (FLAG_enable_embedded_constant_pool) {
+ if (target.is_valid()) {
+ Pop(r0, fp, kConstantPoolRegister, context, target);
+ } else {
+ Pop(r0, fp, kConstantPoolRegister, context);
+ }
+ } else {
+ if (target.is_valid()) {
+ Pop(r0, fp, context, target);
+ } else {
+ Pop(r0, fp, context);
+ }
+ }
+ mtlr(r0);
+}
// ExitFrame layout (probably wrongish.. needs updating)
//
« no previous file with comments | « src/ppc/macro-assembler-ppc.h ('k') | src/s390/builtins-s390.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698