https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113230
--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> --- (In reply to Jonathan Wakely from comment #2) > The point of the test is to write out a byte that isn't valid UTF-8, and > check that it's printed unchanged, as a single byte. If something does some > kind of iconv-like conversion on the test output and "fixes" the non-UTF-8 > output, then the test's assumption will not hold. Yes that is what I think is happening here. Qemu is doing the conversion from Latin 1 to utf-8 . I filed this to record it until I had sometime to look into it further. Maybe there is some env setting I am supposed to set for qemu to prevent this from happening.