Re: [PATCH] upload-pack: use priority queue in reachable() check

2016-10-11 Thread Junio C Hamano
Jeff King writes: > Like a lot of old commit-traversal code, this keeps a > commit_list in commit-date order, and and inserts parents > into the list. This means each insertion is potentially > linear, and the whole thing is quadratic (though the exact > runtime depends on the relationship betwee

[PATCH] upload-pack: use priority queue in reachable() check

2016-10-11 Thread Jeff King
Like a lot of old commit-traversal code, this keeps a commit_list in commit-date order, and and inserts parents into the list. This means each insertion is potentially linear, and the whole thing is quadratic (though the exact runtime depends on the relationship between the commit dates and the par