> From: Taylor R Campbell <[email protected]> > Date: Sat, 11 Jun 2011 16:48:10 +0000 > > [...] > The second patch implements BORKED_FENV. > > That this is necessary is a bit surprising.
Let me sing it for you, Brother. I "fixed" this easily enough and verified, via debugging traces and fegetexcept() in gdb, that ALL exceptions were masked. Yet gdb said I was trapping in Pango, looking for a font or sump'n. I worried about uninitialized struct members, that other thread, etc, etc. I compared my gtk-event-viewer to its straight-C cousin gtkev, which (oh, the terror!) could mask and unmask exceptions, set AND clear them... reliably!! I eventually got down on my hands and knees and looked at the bloody native bloody floating-point bloody instructions. I am flabbergasted that it started working with (just!) those two patches. > Can you set a breakpoint in gdb on alienate_float_environment, both > with libc's fe* and with Scheme's fe*, and step through the machine > instructions to compare what they do differently? Of course! Can't we all? :-) > I looked at the glibc source code, and I see no substantial > difference beyond fnstcw vs fstcw in fedisableexcept (which shouldnt > make a difference here). There is also the sse_p issue, x87_clear_exceptions (fnclex) versus x87_read/write_environment (fnstenv&fldcw/fldenv), and all that stuff I don't know anything about, like T7500 (Core2Duo) fpu bugs. I pounded Chaos into a corner. I rest now. How about someone else verifying that I am not hallucinating? Perhaps I am just the unfortunate victim of a heat issue in my old notebook. One must never underestimate The Great Adversary! > [...] I guess the only way to test this would be to allocate a > stack large enough that it doesn't fit in the low 4 GB of the > virtual address space, which would fall outside the domain of our > automated testing facilities... I don't remember which f instruction trapped. I just assumed they all would have a problem with esp. :-) The (patched) emulation worked well on Ubuntu 11.04 amd64 too, BTW, yet (surprise!) is no longer needed there. ? _______________________________________________ MIT-Scheme-devel mailing list [email protected] https://lists.gnu.org/mailman/listinfo/mit-scheme-devel
