Update : Jan. 04, 2010
As explained in 'How are closing auctions at the limit price processed? (Part 1)', market orders are regarded as limit orders at the limit price, and additionally as simultaneous orders so time priority does not apply. As such, the shares are distributed as outlined below.
TSE totals up the orders from each Trading Participant and arranges them in descending order from the Trading Participant with the largest order. 1 unit shares each in turn are then distributed.