Skip to content

Commit 5601864

Browse files
dschoGit for Windows Build Agent
authored andcommitted
fixup! Merge pull request #964 from jeffhostetler/jeffhostetler/memihash_perf
I should really implement special-handling for a new drop! prefix to commit messages... This commit reverts that Pull Request, in preparation for merging in a new iteration of that work (which looks substantially different from the previous iteration...). Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
1 parent dadc418 commit 5601864

File tree

4 files changed

+0
-22
lines changed

4 files changed

+0
-22
lines changed

cache.h

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -173,9 +173,6 @@ struct cache_entry {
173173
unsigned int ce_flags;
174174
unsigned int ce_namelen;
175175
unsigned int index; /* for link extension */
176-
unsigned int precompute_hash_state;
177-
unsigned int precompute_hash_name;
178-
unsigned int precompute_hash_dir;
179176
struct object_id oid;
180177
char name[FLEX_ARRAY]; /* more */
181178
};
@@ -232,19 +229,6 @@ struct cache_entry {
232229
#error "CE_EXTENDED_FLAGS out of range"
233230
#endif
234231

235-
/*
236-
* Bit set if preload-index precomputed the hash value(s)
237-
* for this cache-entry.
238-
*/
239-
#define CE_PRECOMPUTE_HASH_STATE__SET (1 << 0)
240-
/*
241-
* Bit set if precompute-index also precomputed the hash value
242-
* for the parent directory.
243-
*/
244-
#define CE_PRECOMPUTE_HASH_STATE__DIR (1 << 1)
245-
246-
void precompute_istate_hashes(struct cache_entry *ce);
247-
248232
/* Forward structure decls */
249233
struct pathspec;
250234
struct child_process;

hashmap.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ extern unsigned int strhash(const char *buf);
1212
extern unsigned int strihash(const char *buf);
1313
extern unsigned int memhash(const void *buf, size_t len);
1414
extern unsigned int memihash(const void *buf, size_t len);
15-
extern unsigned int memihash_cont(unsigned int hash_seed, const void *buf, size_t len);
1615

1716
static inline unsigned int sha1hash(const unsigned char *sha1)
1817
{

preload-index.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,6 @@ static void *preload_thread(void *_data)
4646
struct cache_entry *ce = *cep++;
4747
struct stat st;
4848

49-
precompute_istate_hashes(ce);
50-
5149
if (ce_stage(ce))
5250
continue;
5351
if (S_ISGITLINK(ce->ce_mode))

read-cache.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,6 @@ void rename_index_entry_at(struct index_state *istate, int nr, const char *new_n
7777
copy_cache_entry(new, old);
7878
new->ce_flags &= ~CE_HASHED;
7979
new->ce_namelen = namelen;
80-
new->precompute_hash_state = 0;
8180
new->index = 0;
8281
memcpy(new->name, new_name, namelen + 1);
8382

@@ -619,7 +618,6 @@ static struct cache_entry *create_alias_ce(struct index_state *istate,
619618
new = xcalloc(1, cache_entry_size(len));
620619
memcpy(new->name, alias->name, len);
621620
copy_cache_entry(new, ce);
622-
new->precompute_hash_state = 0;
623621
save_or_free_index_entry(istate, ce);
624622
return new;
625623
}
@@ -1550,7 +1548,6 @@ static struct cache_entry *cache_entry_from_ondisk(struct ondisk_cache_entry *on
15501548
ce->ce_stat_data.sd_size = get_be32(&ondisk->size);
15511549
ce->ce_flags = flags & ~CE_NAMEMASK;
15521550
ce->ce_namelen = len;
1553-
ce->precompute_hash_state = 0;
15541551
ce->index = 0;
15551552
hashcpy(ce->oid.hash, ondisk->sha1);
15561553
memcpy(ce->name, name, len);

0 commit comments

Comments
 (0)