But the difference between the price of premium fuel and regular fuel is negligible in the grand scheme of everything you have to pay for with a car.
The 2011 Impreza 2.5 has a 16.9 gallon, so if it did burn premium it would cost $3.38 more to fill it up, so instead of paying $54 to fill it up when it was completely empty it would be $57. With a combined mpg of 23mpg you could drive go 388 miles on one tank.
The Mazda3 has a 15.9 gallon tank and gets 24mpg combined, so if it did burn premium it would cost $3.18 more to fille it up, so instead of paying $51 it would be $54. With a combined mpg of 24mpg you could drive 381.6 miles on one tank.
Assuming you drive 12,000 miles per year like the average American, the Subaru would require 31 fill ups. That's $1,674 on regular and $1,764 on premium, a grand total of $90 more per year to run 93 over 87. Looking at the Mazda, you'd need 31 fill ups as well. That's $1,581 for regular and $1,674 for premium, a difference of $93.
That's $90 over the course of a year, which is nothing when you factor in what maintenance costs on a car per year. Basically you are kvetshing over nothing when it comes to premium vs. regular. Just buy the car you like better and skip out on buying two pops, three bags of chips, three candy bars, or a magazine every week and you'll easily make up for the fuel difference.
With that said, I'd buy the Mazda3, it's probably a better car.