Mile forty seems to be cramp time for me too and for that reason 40 has been my longest to date.
I drink 1:1 gatorade-water mix but I think I may need to eat more often.
Still experimenting with that.