Just a couple of thoughts:
1. The Viper won't idle at 300. The first bar off of zero is 500, the third bar is 700. The PCM forces the IAC to set the idle rpm at approximately 670.
2. A cheap scan tool will tell you right away what is happening.
3. Closed loop operation is where the pcm learns. This can be both good and bad habits. It may be as easy as pulling the C1, C2 and C3, wait for ten minutes this will clear all the adaptives. Turn on the key and slowly floor the throttle so that the pcm knows where wot is. Then drive it for at least 30 minutes.
4. If that doesn't clear it up like everyone said, the IAC or the battery could be possible culprits. Merely check the battery voltage without the engine running, it should be a minimum of 12.5. If it is, that probably rules out the battery.
5. Here are the remaining culprits:
a. IAC doesn't have to be just dirty, one of the coils could be bad.
b. An O2 sensor could be bad, with a scan tool at idle if the voltage goes over 1.0, the sensor is probably bad and is forcing one bank into a super lean condition at idle, this will stall the car. A voltage of over 1.0 tells us the car is running rich, but with a bad O2 it could be lean, therefore, the pcm pulls fuel and makes it leaner, at some point shutting down one bank.
c. The fuel pump is a long shot, it will affect more than idle, therefore, easy to diagnose.
Once again, with a scan tool by looking at the long-term trim, the O2 voltage and the IAC step position you can narow down the issue.
Good Luck