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

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

Issue 12221064: Implement many KeyedStoreStubs using Crankshaft (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Add runtime flag and address review feedback Created 7 years, 9 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
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 2962 matching lines...) Expand 10 before | Expand all | Expand 10 after
2973 Handle<Map> receiver_map) { 2973 Handle<Map> receiver_map) {
2974 // ----------- S t a t e ------------- 2974 // ----------- S t a t e -------------
2975 // -- r0 : value 2975 // -- r0 : value
2976 // -- r1 : key 2976 // -- r1 : key
2977 // -- r2 : receiver 2977 // -- r2 : receiver
2978 // -- lr : return address 2978 // -- lr : return address
2979 // -- r3 : scratch 2979 // -- r3 : scratch
2980 // ----------------------------------- 2980 // -----------------------------------
2981 ElementsKind elements_kind = receiver_map->elements_kind(); 2981 ElementsKind elements_kind = receiver_map->elements_kind();
2982 bool is_js_array = receiver_map->instance_type() == JS_ARRAY_TYPE; 2982 bool is_js_array = receiver_map->instance_type() == JS_ARRAY_TYPE;
2983 Handle<Code> stub = 2983 if (FLAG_compiled_keyed_stores &&
2984 KeyedStoreElementStub(is_js_array, 2984 (receiver_map->has_fast_elements() ||
2985 elements_kind, 2985 receiver_map->has_external_array_elements())) {
2986 store_mode_).GetCode(isolate()); 2986 Handle<Code> stub = KeyedStoreFastElementStub(
2987 2987 is_js_array,
2988 __ DispatchMap(r2, r3, receiver_map, stub, DO_SMI_CHECK); 2988 elements_kind,
2989 store_mode_).GetCode(isolate());
2990 __ DispatchMap(r2, r3, receiver_map, stub, DO_SMI_CHECK);
2991 } else {
2992 Handle<Code> stub =
2993 KeyedStoreElementStub(is_js_array, elements_kind,
2994 store_mode_).GetCode(isolate());
2995 __ DispatchMap(r2, r3, receiver_map, stub, DO_SMI_CHECK);
Hannes Payer (out of office) 2013/03/20 10:22:35 Can you declare Handle<Code> stube before the if/e
danno 2013/03/20 11:44:10 Done.
2996 }
2989 2997
2990 TailCallBuiltin(masm(), MissBuiltin(kind())); 2998 TailCallBuiltin(masm(), MissBuiltin(kind()));
2991 2999
2992 // Return the generated code. 3000 // Return the generated code.
2993 return GetICCode(kind(), Code::NORMAL, factory()->empty_string()); 3001 return GetICCode(kind(), Code::NORMAL, factory()->empty_string());
2994 } 3002 }
2995 3003
2996 3004
2997 Handle<Code> KeyedStoreStubCompiler::CompileStorePolymorphic( 3005 Handle<Code> KeyedStoreStubCompiler::CompileStorePolymorphic(
2998 MapHandleList* receiver_maps, 3006 MapHandleList* receiver_maps,
(...skipping 949 matching lines...) Expand 10 before | Expand all | Expand 10 after
3948 TailCallBuiltin(masm, Builtins::kKeyedStoreIC_Slow); 3956 TailCallBuiltin(masm, Builtins::kKeyedStoreIC_Slow);
3949 } 3957 }
3950 } 3958 }
3951 3959
3952 3960
3953 #undef __ 3961 #undef __
3954 3962
3955 } } // namespace v8::internal 3963 } } // namespace v8::internal
3956 3964
3957 #endif // V8_TARGET_ARCH_ARM 3965 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/arm/lithium-codegen-arm.cc ('k') | src/ast.h » ('j') | src/ic.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698