SARASOTA, Fla. -- Powered by a strong wind, the Orioles and Red Sox engaged in a slugfest Monday afternoon, with the O's coming out on top, 12-9, at Ed Smith Stadium.

With the game tied at 9 in the seventh inning, J.J. Hardy connected on a three-run shot -- Baltimore's fifth homer of the game -- to put the O's ahead to stay.

Boston catcher Christian Vazquez started the homer parade with a two-run homer off Orioles starter T.J. McFarland in the second, and the O's responded with Wilson Betemit's three-run game-tying shot in the bottom of the frame.

Betemit, who had four RBIs, exited in the fifth with a right knee ligament sprain and will be reevaluated further on Tuesday. The O's designated hitter was carted off the field and wearing a brace.

Orioles center fielder Adam Jones, who participated in the World Baseball Classic, connected for his first two spring homers, while Matt Wieters hit a solo shot in the fourth off Red Sox bullpen hopeful Clay Mortensen.

Boston starter Graham Godfrey was tagged with six runs on nine hits over three innings, while McFarland allowed four runs on eight hits with five strikeouts in 3 2/3 innings. The Orioles' Rule 5 Draft pick, McFarland made his first spring start Monday as the organization tries to find a way to keep him in either a starter or relief role.

Red Sox outfielder Jonny Gomes blasted a two-run homer off Orioles closer Jim Johnson in the seventh and third baseman Will Middlebrooks chipped in with a pair of RBIs.

Up next: Kevin Gausman will make his second spring start on Tuesday at 1:05 p.m. ET in Fort Myers, Fla., where he will oppose Twins right-hander Liam Hendriks. Gausman, the O's top pitching prospect behind Dylan Bundy, will be making his seventh appearance in his first Major League Spring Training.