I used to have a diesel Jeep that did that very stunt whenever the fuel filter was marginally clogging. Except for the warning (it gave none). Fuel filter just at the edge would run fine as long as you didn't demand lots of power, then it would go into limp mode without warning "to protect the equipment." Restart, and it was fine until the next time you pushed the go-pedal down, when it would repeat. Nothing more thrilling than pulling out onto a busy highway and trying to get up to speed to avoid being crushed by that semi, only to discover your top speed was now 35 mph, and it took half-an-hour to reach that.