18 Jan
2007
18 Jan
'07
5:27 a.m.
On 1/17/07, Dan McGee <dpmcgee@gmail.com> wrote:
/* TODO only use of a math.h function in entire libalpm, * can we get rid of it? Former code line: *if(numscans > numtargs) { */ if(numscans > sqrt(numtargs)) {
Interesting point. It does appear that the sqrt is merely an optimization. We could probably use numtargs/2 and achieve much the same overall speedup, as 'N' in these loops is probably in the 100-1000 range, this won't be a bottleneck. Might be worth a test though. Still, I have no real opinion on whether the removal of libm as a dep is worth it or not.