Problems? Is your data what you think it is? | |
PerlMonks |
Re^9: Can you improve upon my algorithm.by salva (Canon) |
on Mar 13, 2015 at 23:28 UTC ( [id://1120009]=note: print w/replies, xml ) | Need Help?? |
Here we go!
On my old home computer it merges at around 3GB/min, 100GB in half an hour. As it is just a prove of concept, it can only handle records formed by integers of type int64_t. The meaning of the constants are as follows: The source files are passed as arguments on the command line, the sorted output is sent to STDOUT. Only tested on Ubuntu 64bits. Update: It is difficult to count the number of instructions inside the loop on the hot path. It is certainly below 100, don't know if I have been able to reach the 50 I have predicted... I blame gcc -O3 for that for unrolling small loops as the key comparison.
In Section
Seekers of Perl Wisdom
|
|