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

Side by Side Diff: src/arm/code-stubs-arm.cc

Issue 226503003: Use correct call size for PredictableCodeSizeScopes. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 8 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 | src/arm/full-codegen-arm.cc » ('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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 4933 matching lines...) Expand 10 before | Expand all | Expand 10 after
4944 } 4944 }
4945 masm->LeaveFrame(StackFrame::STUB_FAILURE_TRAMPOLINE); 4945 masm->LeaveFrame(StackFrame::STUB_FAILURE_TRAMPOLINE);
4946 __ mov(r1, Operand(r1, LSL, kPointerSizeLog2)); 4946 __ mov(r1, Operand(r1, LSL, kPointerSizeLog2));
4947 __ add(sp, sp, r1); 4947 __ add(sp, sp, r1);
4948 __ Ret(); 4948 __ Ret();
4949 } 4949 }
4950 4950
4951 4951
4952 void ProfileEntryHookStub::MaybeCallEntryHook(MacroAssembler* masm) { 4952 void ProfileEntryHookStub::MaybeCallEntryHook(MacroAssembler* masm) {
4953 if (masm->isolate()->function_entry_hook() != NULL) { 4953 if (masm->isolate()->function_entry_hook() != NULL) {
4954 PredictableCodeSizeScope predictable(masm, 4 * Assembler::kInstrSize);
4955 ProfileEntryHookStub stub; 4954 ProfileEntryHookStub stub;
4955 int code_size = masm->CallStubSize(&stub) + 2 * Assembler::kInstrSize;
4956 PredictableCodeSizeScope predictable(masm, code_size);
4956 __ push(lr); 4957 __ push(lr);
4957 __ CallStub(&stub); 4958 __ CallStub(&stub);
4958 __ pop(lr); 4959 __ pop(lr);
4959 } 4960 }
4960 } 4961 }
4961 4962
4962 4963
4963 void ProfileEntryHookStub::Generate(MacroAssembler* masm) { 4964 void ProfileEntryHookStub::Generate(MacroAssembler* masm) {
4964 // The entry hook is a "push lr" instruction, followed by a call. 4965 // The entry hook is a "push lr" instruction, followed by a call.
4965 const int32_t kReturnAddressDistanceFromFunctionStart = 4966 const int32_t kReturnAddressDistanceFromFunctionStart =
(...skipping 493 matching lines...) Expand 10 before | Expand all | Expand 10 after
5459 MemOperand(fp, 6 * kPointerSize), 5460 MemOperand(fp, 6 * kPointerSize),
5460 NULL); 5461 NULL);
5461 } 5462 }
5462 5463
5463 5464
5464 #undef __ 5465 #undef __
5465 5466
5466 } } // namespace v8::internal 5467 } } // namespace v8::internal
5467 5468
5468 #endif // V8_TARGET_ARCH_ARM 5469 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « no previous file | src/arm/full-codegen-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698