Reviewers: Yang, danno, dusmil.imgtec, balazs.kilvady, akos.palfi.imgtec,

Message:
PTAL, also see the discussion v8:3992.

Description:
MIPS64: Fix exception return from regexp CheckStackGuardState().

Lack of sign extension on simulator builds gives bad value for
RETRY and EXCEPTION codes.

TEST=mjsunit/regexp-stack-overflow, regress-crbug-467047
BUG=v8:3992
LOG=n

Please review this at https://codereview.chromium.org/1040753003/

Base URL: https://chromium.googlesource.com/v8/v8.git@master

Affected files (+5, -6 lines):
  M src/mips64/regexp-macro-assembler-mips64.h
  M src/mips64/regexp-macro-assembler-mips64.cc


Index: src/mips64/regexp-macro-assembler-mips64.cc
diff --git a/src/mips64/regexp-macro-assembler-mips64.cc b/src/mips64/regexp-macro-assembler-mips64.cc index c1c0e4c2ea88429c765761452b8f1e6d2d992a5b..bd80a818f0b9fae71b3b0f4c4e6f5dbf673807ba 100644
--- a/src/mips64/regexp-macro-assembler-mips64.cc
+++ b/src/mips64/regexp-macro-assembler-mips64.cc
@@ -1146,9 +1146,9 @@ static T& frame_entry(Address re_frame, int frame_offset) {
 }


-int RegExpMacroAssemblerMIPS::CheckStackGuardState(Address* return_address,
-                                                   Code* re_code,
-                                                   Address re_frame) {
+int64_t RegExpMacroAssemblerMIPS::CheckStackGuardState(Address* return_address,
+                                                       Code* re_code,
+                                                       Address re_frame) {
   Isolate* isolate = frame_entry<Isolate*>(re_frame, kIsolate);
   StackLimitCheck check(isolate);
   if (check.JsHasOverflowed()) {
Index: src/mips64/regexp-macro-assembler-mips64.h
diff --git a/src/mips64/regexp-macro-assembler-mips64.h b/src/mips64/regexp-macro-assembler-mips64.h index ae4d25b79aaf473211cfaf4dd1ad95953ebd82df..dd02611fbeb38aa45c3839d6731ac95fdda9a2a2 100644
--- a/src/mips64/regexp-macro-assembler-mips64.h
+++ b/src/mips64/regexp-macro-assembler-mips64.h
@@ -90,9 +90,8 @@ class RegExpMacroAssemblerMIPS: public NativeRegExpMacroAssembler {
   // Called from RegExp if the stack-guard is triggered.
   // If the code object is relocated, the return address is fixed before
   // returning.
-  static int CheckStackGuardState(Address* return_address,
-                                  Code* re_code,
-                                  Address re_frame);
+ static int64_t CheckStackGuardState(Address* return_address, Code* re_code,
+                                      Address re_frame);

   void print_regexp_frame_constants();



--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to