Static buffer allowed to save a lot of memory. Now tsp consumes ~ 500Mb
unordered_map gives 5 times speed-up.