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

Side by Side Diff: src/ic/ic-inl.h

Issue 2669193002: [stubs] Remove obsolete CALL_IC code kind. (Closed)
Patch Set: Created 3 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
« no previous file with comments | « src/ic/ic.cc ('k') | src/log.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 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_IC_INL_H_ 5 #ifndef V8_IC_INL_H_
6 #define V8_IC_INL_H_ 6 #define V8_IC_INL_H_
7 7
8 #include "src/ic/ic.h" 8 #include "src/ic/ic.h"
9 9
10 #include "src/debug/debug.h" 10 #include "src/debug/debug.h"
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 52
53 void IC::SetTargetAtAddress(Address address, Code* target, 53 void IC::SetTargetAtAddress(Address address, Code* target,
54 Address constant_pool) { 54 Address constant_pool) {
55 if (AddressIsDeoptimizedCode(target->GetIsolate(), address)) return; 55 if (AddressIsDeoptimizedCode(target->GetIsolate(), address)) return;
56 56
57 DCHECK(target->is_inline_cache_stub() || target->is_compare_ic_stub()); 57 DCHECK(target->is_inline_cache_stub() || target->is_compare_ic_stub());
58 58
59 DCHECK(!target->is_inline_cache_stub() || 59 DCHECK(!target->is_inline_cache_stub() ||
60 (target->kind() != Code::LOAD_IC && 60 (target->kind() != Code::LOAD_IC &&
61 target->kind() != Code::KEYED_LOAD_IC && 61 target->kind() != Code::KEYED_LOAD_IC &&
62 target->kind() != Code::CALL_IC && target->kind() != Code::STORE_IC && 62 target->kind() != Code::STORE_IC &&
63 target->kind() != Code::KEYED_STORE_IC)); 63 target->kind() != Code::KEYED_STORE_IC));
64 64
65 Heap* heap = target->GetHeap(); 65 Heap* heap = target->GetHeap();
66 Code* old_target = GetTargetAtAddress(address, constant_pool); 66 Code* old_target = GetTargetAtAddress(address, constant_pool);
67 #ifdef DEBUG 67 #ifdef DEBUG
68 // STORE_IC and KEYED_STORE_IC use Code::extra_ic_state() to mark 68 // STORE_IC and KEYED_STORE_IC use Code::extra_ic_state() to mark
69 // ICs as language mode. The language mode of the IC must be preserved. 69 // ICs as language mode. The language mode of the IC must be preserved.
70 if (old_target->kind() == Code::STORE_IC || 70 if (old_target->kind() == Code::STORE_IC ||
71 old_target->kind() == Code::KEYED_STORE_IC) { 71 old_target->kind() == Code::KEYED_STORE_IC) {
72 DCHECK(StoreICState::GetLanguageMode(old_target->extra_ic_state()) == 72 DCHECK(StoreICState::GetLanguageMode(old_target->extra_ic_state()) ==
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 bool IC::AddressIsDeoptimizedCode(Isolate* isolate, Address address) { 148 bool IC::AddressIsDeoptimizedCode(Isolate* isolate, Address address) {
149 Code* host = 149 Code* host =
150 isolate->inner_pointer_to_code_cache()->GetCacheEntry(address)->code; 150 isolate->inner_pointer_to_code_cache()->GetCacheEntry(address)->code;
151 return (host->kind() == Code::OPTIMIZED_FUNCTION && 151 return (host->kind() == Code::OPTIMIZED_FUNCTION &&
152 host->marked_for_deoptimization()); 152 host->marked_for_deoptimization());
153 } 153 }
154 } // namespace internal 154 } // namespace internal
155 } // namespace v8 155 } // namespace v8
156 156
157 #endif // V8_IC_INL_H_ 157 #endif // V8_IC_INL_H_
OLDNEW
« no previous file with comments | « src/ic/ic.cc ('k') | src/log.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698