If it were head to head, Iran would win it at a gentle walk. They have the stronger military and are FAR more experienced, and the taking of the Muslim holy sites is considered something of a duty by the Iranians, so the population would be solidly behind the war, a not inconsiderable bonus.
Which brings us to the custody of said holy sites. Saudi is Sunni. The vast majority of Muslims world wide are Sunni, thanks in part to the Saudi's spreading Wahhabism like some malignant virus. The Sunni's won't let the Shi'ites take or hold Mecca or Medina. Any other inter-faith conflict would stop dead at the prospect - Iran knows this. We sometimes throw around the idea of "a billion pissed off Muslims" - Iran would basically be facing that, and no military is that strong.