Hacker News new | past | comments | ask | show | jobs | submit login

That was my guess :-) But binary search doesn’t need explicit powers of two. I wonder if maybe the PDP10 is much faster at loops with explicit counters instead of comparing the search upper and lower bounds.



No, the loop would have been slower. That is why they found the starting point with that bizarre two-instruction sequence. For any table size between (2^^n)+1 and 2^^(n+1), inclusive, it returned 2^^n as the starting point. Then of course it had to loop after that.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: