瀏覽代碼

optimize probe0 for less __eq__ and hash compare

szdytom 1 年之前
父節點
當前提交
c047eafa7e
共有 1 個文件被更改,包括 0 次插入1 次删除
  1. 0 1
      src/objects/dict.c

+ 0 - 1
src/objects/dict.c

@@ -78,7 +78,6 @@ static int pkpy_Dict__probe0(const pkpy_Dict* self, void* vm, pkpy_Var key, int6
 
         struct pkpy_DictEntry* entry = &c11__getitem(struct pkpy_DictEntry, &self->_entries, idx);
         if(pkpy_Var__is_null(&entry->key)) return h;
-        if(entry->hash == hash && pkpy_Var__eq__(vm, entry->key, key)) return h;
     }
     PK_UNREACHABLE();
 }