Here's some facts excerpted from Mazda's website to compare these two engines.
2017 Mazda MX-5 Engine Specifications:
Engine type SKYACTIV®1 -G 2.0L DOHC 16-valve 4-cylinder with VVT
Horsepower 155 hp @ 6000 rpm
Torque 148 lb-ft @ 4600 rpm
Redline 6800 rpm
Displacement (cc) 1998
Bore x stroke (mm) 83.5 x 91.2
Compression ratio 13 : 1
Fuel system Electronically controlled fuel injection
Recommended fuel Premium unleaded, 91 octane or greater
Minimum octane requirement (R+M/2) Regular unleaded, 87 octane or greater
Valvetrain Chain-driven dual overhead cams, 4 valves per cylinder with variable intake valve timing (VVT)
Ignition system Distributor-less ignition
Engine block Aluminum alloy
Cylinder head Aluminum alloy
Emission control type (Fed/Cal) ULEV / Tier2 Bin5
2017 Mazda 3 Engine Specifications (2.0L):
Engine type SKYACTIV®-G1 2.0L DOHC 4-cylinder with VVT
Horsepower 155 hp @ 6000 rpm
Torque 150 lb-ft @ 4000 rpm
Redline 6800 rpm
Displacement (cc) 1998
Bore x stroke (mm) 83.5 x 91.2
Compression ratio 13.0 : 1
Fuel system Advanced Direct Injection
Recommended fuel Regular unleaded
Valvetrain Chain-driven dual overhead cams, 4 valves per cylinder with variable intake valve timing (VVT)
Ignition system Direct coil-on-plug electronic ignition with platinum-tipped spark plugs
Engine block Aluminum alloy
Cylinder head Aluminum alloy
Emission control type (Fed/Cal) PZEV
I highlighted the stated differences. Note that the differences in torque rating @ RPM, and different emission control type. Other than the external differences required due to packaging in a FWD vs RWD platform and ancillary parts, the engine internals are identical. The TUNING is the difference where the premium fuel comes into play, but it is not obvious from just the specs above.
Clearly the MX-5 must be running a more aggressive timing to net a broader torque curve that pushes its torque peak closer to its HP peak, making it more suitable to a sports car application. The 3 is tuned to hit its torque peak at relatively low RPMs and then fizzle out above that, which is fine for a typical family car. If you were to compare dyno curves for HP & Torque vs. RPM between a stock MX-5 & Mazda3, you'll see this in the curves.
^No. See above, it's in the tuning. A few degrees of timing advance drives the recommendation for premium.