On 8 June 2015 at 19:24, Liviu Ionescu <i...@livius.net> wrote: > >> On 08 Jun 2015, at 21:18, Peter Maydell <peter.mayd...@linaro.org> wrote: >> >> ... I meant >> rom = rom_ptr(0x08000000); > > this version worked for apps linked at 0x08000000 and obviously > failed for those linked at 0x0.
OK, so the problem diagnosis is right. I'm playing around with a patch which postpones PC/SP load until we start execution. There are some awkward issues there, though: if you're running QEMU under a debugger and you look at registers before we start running the system, what happens if the user reads the PC/SP? What happens if they write it? (What happens in this case if you're doing JTAG debugging of real hardware?) -- PMM