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

Side by Side Diff: src/arm/codegen-arm.cc

Issue 570003: Use MemOperand directly to load argv on arm. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 10 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 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 6460 matching lines...) Expand 10 before | Expand all | Expand 10 after
6471 // Called from C, so do not pop argc and args on exit (preserve sp) 6471 // Called from C, so do not pop argc and args on exit (preserve sp)
6472 // No need to save register-passed args 6472 // No need to save register-passed args
6473 // Save callee-saved registers (incl. cp and fp), sp, and lr 6473 // Save callee-saved registers (incl. cp and fp), sp, and lr
6474 __ stm(db_w, sp, kCalleeSaved | lr.bit()); 6474 __ stm(db_w, sp, kCalleeSaved | lr.bit());
6475 6475
6476 // Get address of argv, see stm above. 6476 // Get address of argv, see stm above.
6477 // r0: code entry 6477 // r0: code entry
6478 // r1: function 6478 // r1: function
6479 // r2: receiver 6479 // r2: receiver
6480 // r3: argc 6480 // r3: argc
6481 __ add(r4, sp, Operand((kNumCalleeSaved + 1)*kPointerSize)); 6481 __ ldr(r4, MemOperand(sp, (kNumCalleeSaved + 1) * kPointerSize)); // argv
6482 __ ldr(r4, MemOperand(r4)); // argv
6483 6482
6484 // Push a frame with special values setup to mark it as an entry frame. 6483 // Push a frame with special values setup to mark it as an entry frame.
6485 // r0: code entry 6484 // r0: code entry
6486 // r1: function 6485 // r1: function
6487 // r2: receiver 6486 // r2: receiver
6488 // r3: argc 6487 // r3: argc
6489 // r4: argv 6488 // r4: argv
6490 __ mov(r8, Operand(-1)); // Push a bad frame pointer to fail if it is used. 6489 __ mov(r8, Operand(-1)); // Push a bad frame pointer to fail if it is used.
6491 int marker = is_construct ? StackFrame::ENTRY_CONSTRUCT : StackFrame::ENTRY; 6490 int marker = is_construct ? StackFrame::ENTRY_CONSTRUCT : StackFrame::ENTRY;
6492 __ mov(r7, Operand(Smi::FromInt(marker))); 6491 __ mov(r7, Operand(Smi::FromInt(marker)));
(...skipping 435 matching lines...) Expand 10 before | Expand all | Expand 10 after
6928 // Call the runtime; it returns -1 (less), 0 (equal), or 1 (greater) 6927 // Call the runtime; it returns -1 (less), 0 (equal), or 1 (greater)
6929 // tagged as a small integer. 6928 // tagged as a small integer.
6930 __ bind(&runtime); 6929 __ bind(&runtime);
6931 __ TailCallRuntime(ExternalReference(Runtime::kStringCompare), 2, 1); 6930 __ TailCallRuntime(ExternalReference(Runtime::kStringCompare), 2, 1);
6932 } 6931 }
6933 6932
6934 6933
6935 #undef __ 6934 #undef __
6936 6935
6937 } } // namespace v8::internal 6936 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698