When does the stack pointer get copied from flash to SP on startup?
I was under the impression the Cortex M4 automatically loaded the first and second entry in the vector table into the SP and PC registers. Is this not the case?


It should.
0x0 contains stack pointer.
0x4 contains reset handler address.

LR should also have been cleared to FF. I suspect your debugger is not resetting the core correctly.