View Single Post
Old Oct 1st, 2006, 9:44 AM   #29
lectricpharaoh
Caffeinated Neural Net
 
lectricpharaoh's Avatar
 
Join Date: Jun 2005
Location: Dry west coast of Canada
Posts: 925
Rep Power: 4 lectricpharaoh will become famous soon enough
Quote:
Originally Posted by RobEasy View Post
One question though, what the heck would we use this for?
Hint: it starts with 'sort', and ends with 'ing'.
Quote:
Originally Posted by Mocker View Post
oo nice. Question for you people good with them sorts, do you know how to specifically target multiple cpu's in a sort in order to maximize their use (dual core up to large clusters)? I image it would mostly be useful for larger cpu intensive sorts, sort of a divide and conquer by setting multiple threads sorting one portion at a time ?
One possible approach might be to chop the data up into x subsets, and sort each subset on a separate CPU. However, I can only see this improving performance if a) your data set was large enough to justify the overhead (creating the threads for the separate processors, doing the initial data split, etc), b) if there were no significant issues with the CPUs sharing the memory bus (ie, each thread was more or less CPU-bound, and not memory bound, or if memory bound, could fit large chunks in an L1 or L2 cache), and c) the data would split into relatively equally-sized subsets (otherwise, you get one CPU sitting idle after sorting a dozen items, while another chugs away on several million).
__________________
A man's knowledge is like an expanding sphere, the surface corresponding to the boundary between the known and the unknown. As the sphere grows, so does its surface; the more a man learns, the more he realizes how much he does not know. Hence, the most ignorant man thinks he knows it all. - L. Sprague de Camp
lectricpharaoh is offline   Reply With Quote