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

Side by Side Diff: src/macro-assembler-arm.cc

Issue 7223: Introduce a special kind of frames for construct frames, e.g.... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 12 years, 2 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/macro-assembler-arm.h ('k') | src/macro-assembler-ia32.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. 1 // Copyright 2006-2008 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after
244 244
245 ldr(scratch, MemOperand(object)); 245 ldr(scratch, MemOperand(object));
246 mov(ip, Operand(1)); 246 mov(ip, Operand(1));
247 orr(scratch, scratch, Operand(ip, LSL, offset)); 247 orr(scratch, scratch, Operand(ip, LSL, offset));
248 str(scratch, MemOperand(object)); 248 str(scratch, MemOperand(object));
249 249
250 bind(&done); 250 bind(&done);
251 } 251 }
252 252
253 253
254 void MacroAssembler::EnterInternalFrame() { 254 void MacroAssembler::EnterFrame(StackFrame::Type type) {
255 // r0-r3: preserved 255 // r0-r3: preserved
256 int type = StackFrame::INTERNAL;
257
258 stm(db_w, sp, cp.bit() | fp.bit() | lr.bit()); 256 stm(db_w, sp, cp.bit() | fp.bit() | lr.bit());
259 mov(ip, Operand(Smi::FromInt(type))); 257 mov(ip, Operand(Smi::FromInt(type)));
260 push(ip); 258 push(ip);
261 mov(ip, Operand(0)); 259 mov(ip, Operand(0));
262 push(ip); // Push an empty code cache slot. 260 push(ip); // Push an empty code cache slot.
263 add(fp, sp, Operand(3 * kPointerSize)); // Adjust FP to point to saved FP. 261 add(fp, sp, Operand(3 * kPointerSize)); // Adjust FP to point to saved FP.
264 } 262 }
265 263
266 264
267 void MacroAssembler::LeaveInternalFrame() { 265 void MacroAssembler::LeaveFrame(StackFrame::Type type) {
268 // r0: preserved 266 // r0: preserved
269 // r1: preserved 267 // r1: preserved
270 // r2: preserved 268 // r2: preserved
271 269
272 // Drop the execution stack down to the frame pointer and restore the caller 270 // Drop the execution stack down to the frame pointer and restore
273 // frame pointer and return address. 271 // the caller frame pointer and return address.
274 mov(sp, fp); 272 mov(sp, fp);
275 ldm(ia_w, sp, fp.bit() | lr.bit()); 273 ldm(ia_w, sp, fp.bit() | lr.bit());
276 } 274 }
277 275
278 276
279 void MacroAssembler::EnterExitFrame(StackFrame::Type type) { 277 void MacroAssembler::EnterExitFrame(StackFrame::Type type) {
280 ASSERT(type == StackFrame::EXIT || type == StackFrame::EXIT_DEBUG); 278 ASSERT(type == StackFrame::EXIT || type == StackFrame::EXIT_DEBUG);
281 // Compute parameter pointer before making changes and save it as ip 279 // Compute parameter pointer before making changes and save it as ip
282 // register so that it is restored as sp register on exit, thereby 280 // register so that it is restored as sp register on exit, thereby
283 // popping the args. 281 // popping the args.
(...skipping 545 matching lines...) Expand 10 before | Expand all | Expand 10 after
829 #endif 827 #endif
830 mov(r0, Operand(p0)); 828 mov(r0, Operand(p0));
831 push(r0); 829 push(r0);
832 mov(r0, Operand(Smi::FromInt(p1 - p0))); 830 mov(r0, Operand(Smi::FromInt(p1 - p0)));
833 push(r0); 831 push(r0);
834 CallRuntime(Runtime::kAbort, 2); 832 CallRuntime(Runtime::kAbort, 2);
835 // will not return here 833 // will not return here
836 } 834 }
837 835
838 } } // namespace v8::internal 836 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/macro-assembler-arm.h ('k') | src/macro-assembler-ia32.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698