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

Unified Diff: src/arm/stub-cache-arm.cc

Issue 6974008: Add missing SMI checks to fix reliability bots (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: fix whitespace Created 9 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/ia32/stub-cache-ia32.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/arm/stub-cache-arm.cc
diff --git a/src/arm/stub-cache-arm.cc b/src/arm/stub-cache-arm.cc
index db681936b891f32c79119dac51e83215593e474b..fea4fa5aa212b7ba8d4f2be1c08746fb78b8eef6 100644
--- a/src/arm/stub-cache-arm.cc
+++ b/src/arm/stub-cache-arm.cc
@@ -3098,6 +3098,9 @@ MaybeObject* KeyedLoadStubCompiler::CompileLoadFastElement(Map* receiver_map) {
// -- r0 : key
// -- r1 : receiver
// -----------------------------------
+ Label miss;
+ __ JumpIfSmi(r1, &miss);
+
MaybeObject* maybe_stub = KeyedLoadFastElementStub().TryGetCode();
Code* stub;
if (!maybe_stub->To(&stub)) return maybe_stub;
@@ -3107,6 +3110,7 @@ MaybeObject* KeyedLoadStubCompiler::CompileLoadFastElement(Map* receiver_map) {
Handle<Code>(stub),
DO_SMI_CHECK);
+ __ bind(&miss);
Handle<Code> ic = isolate()->builtins()->KeyedLoadIC_Miss();
__ Jump(ic, RelocInfo::CODE_TARGET);
@@ -3192,6 +3196,9 @@ MaybeObject* KeyedStoreStubCompiler::CompileStoreFastElement(
// -- lr : return address
// -- r3 : scratch
// -----------------------------------
+ Label miss;
+ __ JumpIfSmi(r1, &miss);
+
bool is_js_array = receiver_map->instance_type() == JS_ARRAY_TYPE;
MaybeObject* maybe_stub =
KeyedStoreFastElementStub(is_js_array).TryGetCode();
@@ -3203,6 +3210,7 @@ MaybeObject* KeyedStoreStubCompiler::CompileStoreFastElement(
Handle<Code>(stub),
DO_SMI_CHECK);
+ __ bind(&miss);
Handle<Code> ic = isolate()->builtins()->KeyedStoreIC_Miss();
__ Jump(ic, RelocInfo::CODE_TARGET);
« no previous file with comments | « no previous file | src/ia32/stub-cache-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698