I followed https://sourceware.org/binutils/docs/ld/Overlay-Description.html#Overlay-Description and gotten overlays building and verified working when I step through the code. I then followed https://www.sourceware.org/gdb/onlinedocs/gdb.html#Overlays to get the gdb client working with overlays (e.g. after loading a new overlay, have gdb display the correct associated source) but this causes gdb to disconnect (or crash?).
To test, after loading an overlay into memory I stop at a breakpoint just before stepping into a function in the overlay. I then do "overlay manual". Then "overlay map .overlay_section_name". If I "overlay list-overlays" it properly displays the load and vma addresses of the just mapped overlay. However, as soon as I do a single machine instruction step gdb disconnects (or crashes?). If I don't do the previous gdb commands it single steps fine. Even just doing "overlay manual" without the other commands will cause gdb to disconnect after single step.
Has anyone gotten overlays working with gdb? I've tried on 7-2018-q2 and 8-2018-q4 with the same results.
Thanks in advance for any help.
-Kevin