I doubt that the Mazda5 outclasses the CX-5 in handling and acceleration but unless a professional reviewer does a side by side comparison on the same track, we do not really know for sure. In any case, neither the Mazda5 nor the CX-5 are rocket ships and slight handling differences hardly make a difference for typical driving on public roads. Naturally, when it comes to utility, they are different vehicles and when maximum interior volume is the goal, the Mazda5 wins.
One reason why we bought a CX-5 for our teenage kids is its excellent crash rating: http://www.iihs.org/iihs/ratings/vehicle/v/mazda/cx-5-4-door-suv
In contrast, the Mazda5 has one of the worst small overlap crash results: http://www.iihs.org/iihs/ratings/vehicle/v/mazda/5-4-door-wagon/2015
One reason why we bought a CX-5 for our teenage kids is its excellent crash rating: http://www.iihs.org/iihs/ratings/vehicle/v/mazda/cx-5-4-door-suv
In contrast, the Mazda5 has one of the worst small overlap crash results: http://www.iihs.org/iihs/ratings/vehicle/v/mazda/5-4-door-wagon/2015