| Index: src/builtins.cc
|
| ===================================================================
|
| --- src/builtins.cc (revision 7948)
|
| +++ src/builtins.cc (working copy)
|
| @@ -1,4 +1,4 @@
|
| -// Copyright 2006-2008 the V8 project authors. All rights reserved.
|
| +// Copyright 2011 the V8 project authors. All rights reserved.
|
| // Redistribution and use in source and binary forms, with or without
|
| // modification, are permitted provided that the following conditions are
|
| // met:
|
| @@ -1034,6 +1034,8 @@
|
| Object** argv,
|
| FunctionTemplateInfo* info) {
|
| Object* recv = argv[0];
|
| + // API calls are only supported with JSObject receivers.
|
| + if (!recv->IsJSObject()) return heap->null_value();
|
| Object* sig_obj = info->signature();
|
| if (sig_obj->IsUndefined()) return recv;
|
| SignatureInfo* sig = SignatureInfo::cast(sig_obj);
|
| @@ -1347,11 +1349,21 @@
|
| }
|
|
|
|
|
| +static void Generate_KeyedLoadIC_Slow(MacroAssembler* masm) {
|
| + KeyedLoadIC::GenerateRuntimeGetProperty(masm);
|
| +}
|
| +
|
| +
|
| static void Generate_KeyedLoadIC_Miss(MacroAssembler* masm) {
|
| - KeyedLoadIC::GenerateMiss(masm);
|
| + KeyedLoadIC::GenerateMiss(masm, false);
|
| }
|
|
|
|
|
| +static void Generate_KeyedLoadIC_MissForceGeneric(MacroAssembler* masm) {
|
| + KeyedLoadIC::GenerateMiss(masm, true);
|
| +}
|
| +
|
| +
|
| static void Generate_KeyedLoadIC_Generic(MacroAssembler* masm) {
|
| KeyedLoadIC::GenerateGeneric(masm);
|
| }
|
| @@ -1437,10 +1449,20 @@
|
|
|
|
|
| static void Generate_KeyedStoreIC_Miss(MacroAssembler* masm) {
|
| - KeyedStoreIC::GenerateMiss(masm);
|
| + KeyedStoreIC::GenerateMiss(masm, false);
|
| }
|
|
|
|
|
| +static void Generate_KeyedStoreIC_MissForceGeneric(MacroAssembler* masm) {
|
| + KeyedStoreIC::GenerateMiss(masm, true);
|
| +}
|
| +
|
| +
|
| +static void Generate_KeyedStoreIC_Slow(MacroAssembler* masm) {
|
| + KeyedStoreIC::GenerateSlow(masm);
|
| +}
|
| +
|
| +
|
| static void Generate_KeyedStoreIC_Initialize(MacroAssembler* masm) {
|
| KeyedStoreIC::GenerateInitialize(masm);
|
| }
|
|
|