First off the car wont rev past 4000 rpm in park, because thats the rev limiter/fuel cut off.
As for the car sputtering and dying, have you done a tune up lately?
Are there any Check engine lights on the could help tell what the problem is?
Some of these symptoms could be a faulty cam or crank sensor, thus telling the computer to cut spark and fuel and make it die.