| Index: src/x64/code-stubs-x64.cc
|
| diff --git a/src/x64/code-stubs-x64.cc b/src/x64/code-stubs-x64.cc
|
| index c08e38b50992bbc1a2fbae027654f08cda603c2c..62ce31cc744d3f29904d261698061758a88630dc 100644
|
| --- a/src/x64/code-stubs-x64.cc
|
| +++ b/src/x64/code-stubs-x64.cc
|
| @@ -1574,19 +1574,14 @@ void RegExpExecStub::Generate(MacroAssembler* masm) {
|
| __ ret(REG_EXP_EXEC_ARGUMENT_COUNT * kPointerSize);
|
|
|
| __ bind(&exception);
|
| - // Result must now be exception. If there is no pending exception already a
|
| - // stack overflow (on the backtrack stack) was detected in RegExp code but
|
| - // haven't created the exception yet. Handle that in the runtime system.
|
| - // TODO(592): Rerunning the RegExp to get the stack overflow exception.
|
| + // Result must now be exception.
|
| ExternalReference pending_exception_address(
|
| Isolate::kPendingExceptionAddress, isolate());
|
| Operand pending_exception_operand =
|
| masm->ExternalOperand(pending_exception_address, rbx);
|
| - __ movp(rax, pending_exception_operand);
|
| __ LoadRoot(rdx, Heap::kTheHoleValueRootIndex);
|
| - __ cmpp(rax, rdx);
|
| - __ j(equal, &runtime);
|
| - __ movp(pending_exception_operand, rdx);
|
| + __ movp(rax, pending_exception_operand);
|
| + __ movp(pending_exception_operand, rdx); // Clear pending exception.
|
|
|
| __ CompareRoot(rax, Heap::kTerminationExceptionRootIndex);
|
| Label termination_exception;
|
|
|