Hello all, this is more of a follow up to an old post that doesn't exist anymore.
If your malibu shuts off on you after some time of drive and you've checked/changed everything anyone has recommended. Don't give up I have one thing you should check, actually change.
It's the Brake vacuum it sits on the top right side of the engine it connects to the camshaft, inner parts will break on it and you'll hear a knocking noise if you do that's your first sign. When you remove it be careful because if the inner part is broken they can fall inside the engine.
If your car stalls only when you hit that brake that's most likely your cause.
Try it let me know how it goes.