Revision: 5508
Author: [email protected]
Date: Thu Sep 23 01:06:19 2010
Log: Unuse labels when bailing out of StubCompiler methods.
There are 3 methods where early return happen before the
miss label is bound. This is harmless in Release mode,
in Debug an assertion fails.
Review URL: http://codereview.chromium.org/3405022
http://code.google.com/p/v8/source/detail?r=5508
Modified:
/branches/bleeding_edge/src/arm/stub-cache-arm.cc
/branches/bleeding_edge/src/ia32/stub-cache-ia32.cc
/branches/bleeding_edge/src/x64/stub-cache-x64.cc
=======================================
--- /branches/bleeding_edge/src/arm/stub-cache-arm.cc Tue Sep 21 05:54:12
2010
+++ /branches/bleeding_edge/src/arm/stub-cache-arm.cc Thu Sep 23 01:06:19
2010
@@ -2084,7 +2084,10 @@
name,
r1,
&miss);
- if (cell->IsFailure()) return cell;
+ if (cell->IsFailure()) {
+ miss.Unuse();
+ return cell;
+ }
}
// Return undefined if maps of the full prototype chain are still the
@@ -2134,7 +2137,10 @@
Failure* failure = Failure::InternalError();
bool success = GenerateLoadCallback(object, holder, r0, r2, r3, r1, r4,
callback, name, &miss, &failure);
- if (!success) return failure;
+ if (!success) {
+ miss.Unuse();
+ return failure;
+ }
__ bind(&miss);
GenerateLoadMiss(masm(), Code::LOAD_IC);
@@ -2282,7 +2288,10 @@
Failure* failure = Failure::InternalError();
bool success = GenerateLoadCallback(receiver, holder, r1, r0, r2, r3, r4,
callback, name, &miss, &failure);
- if (!success) return failure;
+ if (!success) {
+ miss.Unuse();
+ return failure;
+ }
__ bind(&miss);
GenerateLoadMiss(masm(), Code::KEYED_LOAD_IC);
=======================================
--- /branches/bleeding_edge/src/ia32/stub-cache-ia32.cc Tue Sep 21 05:54:12
2010
+++ /branches/bleeding_edge/src/ia32/stub-cache-ia32.cc Thu Sep 23 01:06:19
2010
@@ -2455,7 +2455,10 @@
name,
edx,
&miss);
- if (cell->IsFailure()) return cell;
+ if (cell->IsFailure()) {
+ miss.Unuse();
+ return cell;
+ }
}
// Return undefined if maps of the full prototype chain are still the
@@ -2505,7 +2508,10 @@
Failure* failure = Failure::InternalError();
bool success = GenerateLoadCallback(object, holder, eax, ecx, ebx, edx,
edi,
callback, name, &miss, &failure);
- if (!success) return failure;
+ if (!success) {
+ miss.Unuse();
+ return failure;
+ }
__ bind(&miss);
GenerateLoadMiss(masm(), Code::LOAD_IC);
@@ -2666,9 +2672,13 @@
Failure* failure = Failure::InternalError();
bool success = GenerateLoadCallback(receiver, holder, edx, eax, ebx,
ecx, edi,
callback, name, &miss, &failure);
- if (!success) return failure;
+ if (!success) {
+ miss.Unuse();
+ return failure;
+ }
__ bind(&miss);
+
__ DecrementCounter(&Counters::keyed_load_callback, 1);
GenerateLoadMiss(masm(), Code::KEYED_LOAD_IC);
=======================================
--- /branches/bleeding_edge/src/x64/stub-cache-x64.cc Tue Sep 21 05:54:12
2010
+++ /branches/bleeding_edge/src/x64/stub-cache-x64.cc Thu Sep 23 01:06:19
2010
@@ -1701,7 +1701,10 @@
Failure* failure = Failure::InternalError();
bool success = GenerateLoadCallback(object, holder, rax, rcx, rbx, rdx,
rdi,
callback, name, &miss, &failure);
- if (!success) return failure;
+ if (!success) {
+ miss.Unuse();
+ return failure;
+ }
__ bind(&miss);
GenerateLoadMiss(masm(), Code::LOAD_IC);
@@ -1757,7 +1760,10 @@
name,
rdx,
&miss);
- if (cell->IsFailure()) return cell;
+ if (cell->IsFailure()) {
+ miss.Unuse();
+ return cell;
+ }
}
// Return undefined if maps of the full prototype chain are still the
@@ -1895,7 +1901,10 @@
Failure* failure = Failure::InternalError();
bool success = GenerateLoadCallback(receiver, holder, rdx, rax, rbx,
rcx, rdi,
callback, name, &miss, &failure);
- if (!success) return failure;
+ if (!success) {
+ miss.Unuse();
+ return failure;
+ }
__ bind(&miss);
__ DecrementCounter(&Counters::keyed_load_callback, 1);
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev