compatibilty with qemu code
and also changes to debugging messages