25.04.2014 21:24, Peter Maydell wrote: > On 25 April 2014 09:13, Dmitry Poletaev <[email protected]> wrote: > >> Emulated program can execute that test and after that >> can understand environment not real. > > It is always going to be possible to determine that you're > running on an emulator rather than real hardware, so changing > QEMU behaviour just for this is uninteresting. If QEMU > behaves differently from the specification (in this case > the x86 hardware and architecture manuals) that's an interesting > bug. If we just happen to choose a different undefined > behaviour from that which hardware does, that is not in > my opinion a problem.
Actually it might be a problem. We know a ton of examples where hardware had bugs and software had to compensate and actually _expect_ buggy behavour. Or when software depends on (reliable repeating) certain behavour in undocumented parts, and hell breaks when this (undocumented!) behavour changes. Thanks, /mjt
