Yes, you can close the window. If it doesn't terminate the lde and ldex processes (assuming you're using X11 not SDL for the display subsystem) kill them off, and then it's safe to start again.
It is possible to attach gdb (or lldb) to the ldex process, and then
print vmem_save("/tmp/lisp.virtualmem")
which should save the state -- but while we might be able to figure out what it was doing, it's not a quick process and it won't be easy to retrieve your code from there (I don't think the vmem it saves is bootable - though I don't know the reason behind that)
-- Nick