I may have misunderstood, but I believe step 1 (eliding loads) is simply a cache scheduling problem. The optimal solution is the greedy "furthest in the future" eviction policy.
[1]: https://blog.henrypoon.com/blog/2014/02/02/proof-of-the-fart...
(provided you know about induction already.)