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

Side by Side Diff: src/regexp/ppc/regexp-macro-assembler-ppc.cc

Issue 2752143003: [regexp] Remove remainder of native RegExpExecStub (Closed)
Patch Set: Fix non-sim arm64 and mips builds Created 3 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
« no previous file with comments | « src/regexp/ppc/regexp-macro-assembler-ppc.h ('k') | src/regexp/regexp-macro-assembler.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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #if V8_TARGET_ARCH_PPC 5 #if V8_TARGET_ARCH_PPC
6 6
7 #include "src/regexp/ppc/regexp-macro-assembler-ppc.h" 7 #include "src/regexp/ppc/regexp-macro-assembler-ppc.h"
8 8
9 #include "src/base/bits.h" 9 #include "src/base/bits.h"
10 #include "src/code-stubs.h" 10 #include "src/code-stubs.h"
(...skipping 20 matching lines...) Expand all
31 * - r30: End of input (points to byte after last character in input). 31 * - r30: End of input (points to byte after last character in input).
32 * - r31: Frame pointer. Used to access arguments, local variables and 32 * - r31: Frame pointer. Used to access arguments, local variables and
33 * RegExp registers. 33 * RegExp registers.
34 * - r12: IP register, used by assembler. Very volatile. 34 * - r12: IP register, used by assembler. Very volatile.
35 * - r1/sp : Points to tip of C stack. 35 * - r1/sp : Points to tip of C stack.
36 * 36 *
37 * The remaining registers are free for computations. 37 * The remaining registers are free for computations.
38 * Each call to a public method should retain this convention. 38 * Each call to a public method should retain this convention.
39 * 39 *
40 * The stack will have the following structure: 40 * The stack will have the following structure:
41 * - fp[44] Isolate* isolate (address of the current isolate) 41 * - fp[40] Isolate* isolate (address of the current isolate)
42 * - fp[40] secondary link/return address used by native call.
43 * - fp[36] lr save area (currently unused) 42 * - fp[36] lr save area (currently unused)
44 * - fp[32] backchain (currently unused) 43 * - fp[32] backchain (currently unused)
45 * --- sp when called --- 44 * --- sp when called ---
46 * - fp[28] return address (lr). 45 * - fp[28] return address (lr).
47 * - fp[24] old frame pointer (r31). 46 * - fp[24] old frame pointer (r31).
48 * - fp[0..20] backup of registers r25..r30 47 * - fp[0..20] backup of registers r25..r30
49 * --- frame pointer ---- 48 * --- frame pointer ----
50 * - fp[-4] direct_call (if 1, direct call from JavaScript code, 49 * - fp[-4] direct_call (if 1, direct call from JavaScript code,
51 * if 0, call through the runtime system). 50 * if 0, call through the runtime system).
52 * - fp[-8] stack_area_base (high end of the memory area to use as 51 * - fp[-8] stack_area_base (high end of the memory area to use as
(...skipping 21 matching lines...) Expand all
74 * character of the string). The remaining registers start out as garbage. 73 * character of the string). The remaining registers start out as garbage.
75 * 74 *
76 * The data up to the return address must be placed there by the calling 75 * The data up to the return address must be placed there by the calling
77 * code and the remaining arguments are passed in registers, e.g. by calling the 76 * code and the remaining arguments are passed in registers, e.g. by calling the
78 * code entry as cast to a function with the signature: 77 * code entry as cast to a function with the signature:
79 * int (*match)(String* input_string, 78 * int (*match)(String* input_string,
80 * int start_index, 79 * int start_index,
81 * Address start, 80 * Address start,
82 * Address end, 81 * Address end,
83 * int* capture_output_array, 82 * int* capture_output_array,
83 * int num_capture_registers,
84 * byte* stack_area_base, 84 * byte* stack_area_base,
85 * Address secondary_return_address, // Only used by native call. 85 * bool direct_call = false,
86 * bool direct_call = false) 86 * Isolate* isolate);
87 * The call is performed by NativeRegExpMacroAssembler::Execute() 87 * The call is performed by NativeRegExpMacroAssembler::Execute()
88 * (in regexp-macro-assembler.cc) via the CALL_GENERATED_REGEXP_CODE macro 88 * (in regexp-macro-assembler.cc) via the CALL_GENERATED_REGEXP_CODE macro
89 * in ppc/simulator-ppc.h. 89 * in ppc/simulator-ppc.h.
90 * When calling as a non-direct call (i.e., from C++ code), the return address
91 * area is overwritten with the LR register by the RegExp code. When doing a
92 * direct call from generated code, the return address is placed there by
93 * the calling code, as in a normal exit frame.
94 */ 90 */
95 91
96 #define __ ACCESS_MASM(masm_) 92 #define __ ACCESS_MASM(masm_)
97 93
98 RegExpMacroAssemblerPPC::RegExpMacroAssemblerPPC(Isolate* isolate, Zone* zone, 94 RegExpMacroAssemblerPPC::RegExpMacroAssemblerPPC(Isolate* isolate, Zone* zone,
99 Mode mode, 95 Mode mode,
100 int registers_to_save) 96 int registers_to_save)
101 : NativeRegExpMacroAssembler(isolate, zone), 97 : NativeRegExpMacroAssembler(isolate, zone),
102 masm_(new MacroAssembler(isolate, NULL, kRegExpCodeSize, 98 masm_(new MacroAssembler(isolate, NULL, kRegExpCodeSize,
103 CodeObjectRequired::kYes)), 99 CodeObjectRequired::kYes)),
(...skipping 1222 matching lines...) Expand 10 before | Expand all | Expand 10 after
1326 } 1322 }
1327 1323
1328 1324
1329 #undef __ 1325 #undef __
1330 1326
1331 #endif // V8_INTERPRETED_REGEXP 1327 #endif // V8_INTERPRETED_REGEXP
1332 } // namespace internal 1328 } // namespace internal
1333 } // namespace v8 1329 } // namespace v8
1334 1330
1335 #endif // V8_TARGET_ARCH_PPC 1331 #endif // V8_TARGET_ARCH_PPC
OLDNEW
« no previous file with comments | « src/regexp/ppc/regexp-macro-assembler-ppc.h ('k') | src/regexp/regexp-macro-assembler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698