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

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

Issue 23468015: ARM: replace RegExpCEntryStub with DirectCEntryStub. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 3 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
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 6125 matching lines...) Expand 10 before | Expand all | Expand 10 after
6136 __ pop(lr); 6136 __ pop(lr);
6137 __ pop(r0); 6137 __ pop(r0);
6138 __ pop(r1); 6138 __ pop(r1);
6139 } 6139 }
6140 6140
6141 __ Jump(r2); 6141 __ Jump(r2);
6142 } 6142 }
6143 6143
6144 6144
6145 void DirectCEntryStub::Generate(MacroAssembler* masm) { 6145 void DirectCEntryStub::Generate(MacroAssembler* masm) {
6146 // Place the return address on the stack, making the call
6147 // GC safe. The RegExp backend also relies on this.
6148 __ str(lr, MemOperand(sp, 0));
6149 __ blx(ip); // Call the C++ function.
6150 __ VFPEnsureFPSCRState(r2);
6146 __ ldr(pc, MemOperand(sp, 0)); 6151 __ ldr(pc, MemOperand(sp, 0));
6147 } 6152 }
6148 6153
6149 6154
6150 void DirectCEntryStub::GenerateCall(MacroAssembler* masm, 6155 void DirectCEntryStub::GenerateCall(MacroAssembler* masm,
6151 Register target) { 6156 Register target) {
6152 intptr_t code = 6157 intptr_t code =
6153 reinterpret_cast<intptr_t>(GetCode(masm->isolate()).location()); 6158 reinterpret_cast<intptr_t>(GetCode(masm->isolate()).location());
6159 __ Move(ip, target);
6154 __ mov(lr, Operand(code, RelocInfo::CODE_TARGET)); 6160 __ mov(lr, Operand(code, RelocInfo::CODE_TARGET));
6155 6161 __ blx(lr); // Call the stub.
6156 // Prevent literal pool emission during calculation of return address.
6157 Assembler::BlockConstPoolScope block_const_pool(masm);
6158
6159 // Push return address (accessible to GC through exit frame pc).
6160 // Note that using pc with str is deprecated.
6161 Label start;
6162 __ bind(&start);
6163 __ add(ip, pc, Operand(Assembler::kInstrSize));
6164 __ str(ip, MemOperand(sp, 0));
6165 __ Jump(target); // Call the C++ function.
6166 ASSERT_EQ(Assembler::kInstrSize + Assembler::kPcLoadDelta,
6167 masm->SizeOfCodeGeneratedSince(&start));
6168 __ VFPEnsureFPSCRState(r2);
6169 } 6162 }
6170 6163
6171 6164
6172 void NameDictionaryLookupStub::GenerateNegativeLookup(MacroAssembler* masm, 6165 void NameDictionaryLookupStub::GenerateNegativeLookup(MacroAssembler* masm,
6173 Label* miss, 6166 Label* miss,
6174 Label* done, 6167 Label* done,
6175 Register receiver, 6168 Register receiver,
6176 Register properties, 6169 Register properties,
6177 Handle<Name> name, 6170 Handle<Name> name,
6178 Register scratch0) { 6171 Register scratch0) {
(...skipping 959 matching lines...) Expand 10 before | Expand all | Expand 10 after
7138 __ bind(&fast_elements_case); 7131 __ bind(&fast_elements_case);
7139 GenerateCase(masm, FAST_ELEMENTS); 7132 GenerateCase(masm, FAST_ELEMENTS);
7140 } 7133 }
7141 7134
7142 7135
7143 #undef __ 7136 #undef __
7144 7137
7145 } } // namespace v8::internal 7138 } } // namespace v8::internal
7146 7139
7147 #endif // V8_TARGET_ARCH_ARM 7140 #endif // V8_TARGET_ARCH_ARM
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698