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/regexp-macro-assembler.cc

Issue 1457223005: Remove a bunch of Isolate::Current() callsites from simulators (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: updates Created 5 years, 1 month 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/ppc/simulator-ppc.cc ('k') | src/x64/simulator-x64.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 #include "src/regexp/regexp-macro-assembler.h" 5 #include "src/regexp/regexp-macro-assembler.h"
6 6
7 #include "src/assembler.h" 7 #include "src/assembler.h"
8 #include "src/ast.h" 8 #include "src/ast.h"
9 #include "src/isolate-inl.h" 9 #include "src/isolate-inl.h"
10 #include "src/regexp/regexp-stack.h" 10 #include "src/regexp/regexp-stack.h"
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
182 const byte* input_start, 182 const byte* input_start,
183 const byte* input_end, 183 const byte* input_end,
184 int* output, 184 int* output,
185 int output_size, 185 int output_size,
186 Isolate* isolate) { 186 Isolate* isolate) {
187 // Ensure that the minimum stack has been allocated. 187 // Ensure that the minimum stack has been allocated.
188 RegExpStackScope stack_scope(isolate); 188 RegExpStackScope stack_scope(isolate);
189 Address stack_base = stack_scope.stack()->stack_base(); 189 Address stack_base = stack_scope.stack()->stack_base();
190 190
191 int direct_call = 0; 191 int direct_call = 0;
192 int result = CALL_GENERATED_REGEXP_CODE(code->entry(), 192 int result = CALL_GENERATED_REGEXP_CODE(
193 input, 193 isolate, code->entry(), input, start_offset, input_start, input_end,
194 start_offset, 194 output, output_size, stack_base, direct_call, isolate);
195 input_start,
196 input_end,
197 output,
198 output_size,
199 stack_base,
200 direct_call,
201 isolate);
202 DCHECK(result >= RETRY); 195 DCHECK(result >= RETRY);
203 196
204 if (result == EXCEPTION && !isolate->has_pending_exception()) { 197 if (result == EXCEPTION && !isolate->has_pending_exception()) {
205 // We detected a stack overflow (on the backtrack stack) in RegExp code, 198 // We detected a stack overflow (on the backtrack stack) in RegExp code,
206 // but haven't created the exception yet. 199 // but haven't created the exception yet.
207 isolate->StackOverflow(); 200 isolate->StackOverflow();
208 } 201 }
209 return static_cast<Result>(result); 202 return static_cast<Result>(result);
210 } 203 }
211 204
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
302 } 295 }
303 *stack_base = new_stack_base; 296 *stack_base = new_stack_base;
304 intptr_t stack_content_size = old_stack_base - stack_pointer; 297 intptr_t stack_content_size = old_stack_base - stack_pointer;
305 return new_stack_base - stack_content_size; 298 return new_stack_base - stack_content_size;
306 } 299 }
307 300
308 #endif // V8_INTERPRETED_REGEXP 301 #endif // V8_INTERPRETED_REGEXP
309 302
310 } // namespace internal 303 } // namespace internal
311 } // namespace v8 304 } // namespace v8
OLDNEW
« no previous file with comments | « src/ppc/simulator-ppc.cc ('k') | src/x64/simulator-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698