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

Unified Diff: src/ic/stub-cache.cc

Issue 1846963002: Use a dictionary-mode code cache on the map rather than a dual system. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Addressed comment Created 4 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/ic/s390/stub-cache-s390.cc ('k') | src/ic/x64/handler-compiler-x64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ic/stub-cache.cc
diff --git a/src/ic/stub-cache.cc b/src/ic/stub-cache.cc
index 4a5f9bd7ade3c5d03b850464a126c4ec4cfe59ed..5d71c1fe6b2a5d422402d929c93746c38d98151d 100644
--- a/src/ic/stub-cache.cc
+++ b/src/ic/stub-cache.cc
@@ -23,7 +23,7 @@ void StubCache::Initialize() {
static Code::Flags CommonStubCacheChecks(Name* name, Map* map,
Code::Flags flags) {
- flags = Code::RemoveTypeAndHolderFromFlags(flags);
+ flags = Code::RemoveHolderFromFlags(flags);
// Validate that the name does not move on scavenge, and that we
// can use identity checks instead of structural equality checks.
@@ -36,8 +36,7 @@ static Code::Flags CommonStubCacheChecks(Name* name, Map* map,
DCHECK_EQ(Code::HANDLER, Code::ExtractKindFromFlags(flags));
STATIC_ASSERT((Code::ICStateField::kMask & 1) == 1);
- // Make sure that the code type and cache holder are not included in the hash.
- DCHECK(Code::ExtractTypeFromFlags(flags) == 0);
+ // Make sure that the cache holder are not included in the hash.
DCHECK(Code::ExtractCacheHolderFromFlags(flags) == 0);
return flags;
@@ -56,8 +55,7 @@ Code* StubCache::Set(Name* name, Map* map, Code* code) {
// secondary cache before overwriting it.
if (old_code != isolate_->builtins()->builtin(Builtins::kIllegal)) {
Map* old_map = primary->map;
- Code::Flags old_flags =
- Code::RemoveTypeAndHolderFromFlags(old_code->flags());
+ Code::Flags old_flags = Code::RemoveHolderFromFlags(old_code->flags());
int seed = PrimaryOffset(primary->key, old_flags, old_map);
int secondary_offset = SecondaryOffset(primary->key, old_flags, seed);
Entry* secondary = entry(secondary_, secondary_offset);
« no previous file with comments | « src/ic/s390/stub-cache-s390.cc ('k') | src/ic/x64/handler-compiler-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698