If Mario is itemless then Sonic willl kick his ass no matter which situation they are in because Mario can't counter any of Sonics moves because he is much more slower then Sonic. And Eventually he will be tired frm all the dodging and will drop his guard.
And thats when Sonic will Spin atack's right trough him.
If Mario is with Items then this ill be a long and difficult battle.
Sonic needs rings to maintain his super form while Mario can just spam stars , Mega mushroms and Metal caps untill Sonic runs out of Juice. After that it's gonna be Sonic running and trying to wait untill Mario runs out of items aswell , but as we see in New super Mario bros Mega mushrooms actually increase your speed.
So as a last ditch Mario will pull out a P-wing, Mega mushroom and Starman , chase sonic down and stomp him.
There is alot of situations that might break such scenarios like Sonic possesing Master emerald for infinite powerup or him running away from the start of the battle. But overall if the contestants have no idea about each others powers this is how t play out in my opinion. Mario just has alot of items that sonic can't counter.