I would check the oil pressure reading through the sensor. If it stars to fail, the engine will shut off to protect from damage. Also, check the regulator as it has filters internal to the connections. Should they become clogged, will only run for a short period. There is also a drain on the regulator, remove to see how much tar is inside. May need to replace regulator.