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

Side by Side Diff: src/ic.cc

Issue 165993004: Use holder dictionary-mode to detect FAST or NORMAL (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 10 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 | « no previous file | no next file » | 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 822 matching lines...) Expand 10 before | Expand all | Expand 10 after
833 Handle<Code> IC::ComputeHandler(LookupResult* lookup, 833 Handle<Code> IC::ComputeHandler(LookupResult* lookup,
834 Handle<Object> object, 834 Handle<Object> object,
835 Handle<String> name, 835 Handle<String> name,
836 Handle<Object> value) { 836 Handle<Object> value) {
837 InlineCacheHolderFlag cache_holder = GetCodeCacheForObject(*object); 837 InlineCacheHolderFlag cache_holder = GetCodeCacheForObject(*object);
838 Handle<HeapObject> stub_holder(GetCodeCacheHolder( 838 Handle<HeapObject> stub_holder(GetCodeCacheHolder(
839 isolate(), *object, cache_holder)); 839 isolate(), *object, cache_holder));
840 840
841 Handle<Code> code = isolate()->stub_cache()->FindHandler( 841 Handle<Code> code = isolate()->stub_cache()->FindHandler(
842 name, handle(stub_holder->map()), kind(), cache_holder, 842 name, handle(stub_holder->map()), kind(), cache_holder,
843 lookup->IsNormal() ? Code::NORMAL : Code::FAST); 843 lookup->holder()->HasFastProperties() ? Code::FAST : Code::NORMAL);
844 if (!code.is_null()) { 844 if (!code.is_null()) {
845 #ifdef DEBUG 845 #ifdef DEBUG
846 Handle<Code> compiled = CompileHandler( 846 Handle<Code> compiled = CompileHandler(
847 lookup, object, name, value, cache_holder); 847 lookup, object, name, value, cache_holder);
848 ASSERT(compiled->flags() == code->flags()); 848 ASSERT(compiled->flags() == code->flags());
849 #endif 849 #endif
850 return code; 850 return code;
851 } 851 }
852 852
853 code = CompileHandler(lookup, object, name, value, cache_holder); 853 code = CompileHandler(lookup, object, name, value, cache_holder);
(...skipping 1947 matching lines...) Expand 10 before | Expand all | Expand 10 after
2801 #undef ADDR 2801 #undef ADDR
2802 }; 2802 };
2803 2803
2804 2804
2805 Address IC::AddressFromUtilityId(IC::UtilityId id) { 2805 Address IC::AddressFromUtilityId(IC::UtilityId id) {
2806 return IC_utilities[id]; 2806 return IC_utilities[id];
2807 } 2807 }
2808 2808
2809 2809
2810 } } // namespace v8::internal 2810 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698