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

Side by Side Diff: src/stub-cache.cc

Issue 22745003: Remove platform-specific dead code for KeyedStores (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 4 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/stub-cache.h ('k') | src/type-info.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 1837 matching lines...) Expand 10 before | Expand all | Expand 10 after
1848 // Return the generated code. 1848 // Return the generated code.
1849 return GetICCode(kind(), Code::NORMAL, factory()->empty_string()); 1849 return GetICCode(kind(), Code::NORMAL, factory()->empty_string());
1850 } 1850 }
1851 1851
1852 1852
1853 Handle<Code> KeyedStoreStubCompiler::CompileStoreElement( 1853 Handle<Code> KeyedStoreStubCompiler::CompileStoreElement(
1854 Handle<Map> receiver_map) { 1854 Handle<Map> receiver_map) {
1855 ElementsKind elements_kind = receiver_map->elements_kind(); 1855 ElementsKind elements_kind = receiver_map->elements_kind();
1856 bool is_jsarray = receiver_map->instance_type() == JS_ARRAY_TYPE; 1856 bool is_jsarray = receiver_map->instance_type() == JS_ARRAY_TYPE;
1857 Handle<Code> stub; 1857 Handle<Code> stub;
1858 if (FLAG_compiled_keyed_stores && 1858 if (receiver_map->has_fast_elements() ||
1859 (receiver_map->has_fast_elements() || 1859 receiver_map->has_external_array_elements()) {
1860 receiver_map->has_external_array_elements())) {
1861 stub = KeyedStoreFastElementStub( 1860 stub = KeyedStoreFastElementStub(
1862 is_jsarray, 1861 is_jsarray,
1863 elements_kind, 1862 elements_kind,
1864 store_mode_).GetCode(isolate()); 1863 store_mode_).GetCode(isolate());
1865 } else { 1864 } else {
1866 stub = KeyedStoreElementStub(is_jsarray, 1865 stub = KeyedStoreElementStub(is_jsarray,
1867 elements_kind, 1866 elements_kind,
1868 store_mode_).GetCode(isolate()); 1867 store_mode_).GetCode(isolate());
1869 } 1868 }
1870 1869
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
1991 // transitions are still important for performance. 1990 // transitions are still important for performance.
1992 bool is_js_array = receiver_map->instance_type() == JS_ARRAY_TYPE; 1991 bool is_js_array = receiver_map->instance_type() == JS_ARRAY_TYPE;
1993 ElementsKind elements_kind = receiver_map->elements_kind(); 1992 ElementsKind elements_kind = receiver_map->elements_kind();
1994 if (!transitioned_map.is_null()) { 1993 if (!transitioned_map.is_null()) {
1995 cached_stub = ElementsTransitionAndStoreStub( 1994 cached_stub = ElementsTransitionAndStoreStub(
1996 elements_kind, 1995 elements_kind,
1997 transitioned_map->elements_kind(), 1996 transitioned_map->elements_kind(),
1998 is_js_array, 1997 is_js_array,
1999 store_mode_).GetCode(isolate()); 1998 store_mode_).GetCode(isolate());
2000 } else { 1999 } else {
2001 if (FLAG_compiled_keyed_stores && 2000 if (receiver_map->has_fast_elements() ||
2002 (receiver_map->has_fast_elements() || 2001 receiver_map->has_external_array_elements()) {
2003 receiver_map->has_external_array_elements())) {
2004 cached_stub = KeyedStoreFastElementStub( 2002 cached_stub = KeyedStoreFastElementStub(
2005 is_js_array, 2003 is_js_array,
2006 elements_kind, 2004 elements_kind,
2007 store_mode_).GetCode(isolate()); 2005 store_mode_).GetCode(isolate());
2008 } else { 2006 } else {
2009 cached_stub = KeyedStoreElementStub( 2007 cached_stub = KeyedStoreElementStub(
2010 is_js_array, 2008 is_js_array,
2011 elements_kind, 2009 elements_kind,
2012 store_mode_).GetCode(isolate()); 2010 store_mode_).GetCode(isolate());
2013 } 2011 }
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after
2191 Handle<FunctionTemplateInfo>( 2189 Handle<FunctionTemplateInfo>(
2192 FunctionTemplateInfo::cast(signature->receiver())); 2190 FunctionTemplateInfo::cast(signature->receiver()));
2193 } 2191 }
2194 } 2192 }
2195 2193
2196 is_simple_api_call_ = true; 2194 is_simple_api_call_ = true;
2197 } 2195 }
2198 2196
2199 2197
2200 } } // namespace v8::internal 2198 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/stub-cache.h ('k') | src/type-info.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698