|
View:
New views
3 Messages
—
Rating Filter:
Alert me
|
|
|
|
|
|
Re: Re: [MLton-commit] r6887On Tue, 30 Sep 2008, Matthew Fluet wrote:
> On Tue, 23 Sep 2008, Wesley Terpstra wrote: >> feround.c and IEEEReal.c carried duplicated fesetround code. >> The IEEEReal i386 version also works on x86_64. > > This is not technically true, as it only sets the control word on the x87 > unit and not on the SSE unit. For amd64, we use the SSE instructions > exclusively for floating-point computation, so changing the x87 control word > has no effect. See > http://sources.redhat.com/cgi-bin/cvsweb.cgi/~checkout~/libc/sysdeps/x86_64/fpu/fesetround.c?rev=1.2&cvsroot=glibc > > I doubt that there is any amd64 platform that does not provide > fe{get,set}round in libm, so I don't think it is necesary to provide assembly > for amd64. Hmm, I got confused looking at just the patch in the commit log. I guess the SSE control word changes were added some time ago. And, looking at that commit entry (r6693), it seems that MinGW on Win64 does not provide (working) fe{get,set}round in libm. _______________________________________________ MLton mailing list MLton@... http://mlton.org/mailman/listinfo/mlton |
|
|
Re: Re: [MLton-commit] r6887On Tue, Sep 30, 2008 at 11:17 PM, Matthew Fluet <fluet@...> wrote:
> On Tue, 23 Sep 2008, Wesley Terpstra wrote: >> feround.c and IEEEReal.c carried duplicated fesetround code. >> The IEEEReal i386 version also works on x86_64. > > This is not technically true, as it only sets the control word on the x87 > unit and not on the SSE unit. An earlier commit by me added the SSE instructions to update the SSE unit at the same time (check IEEEReal.c -- I added 64 bit assembly) as the x87 unit. At the time I didn't realize there were two copies so only updated the one. The commit you saw merged them and removed the old version. > For amd64, we use the SSE instructions exclusively for floating-point computation, so changing the x87 control word has no effect. > I doubt that there is any amd64 platform that does not provide > fe{get,set}round in libm, so I don't think it is necesary to provide > assembly for amd64. Not true. I added that code because it was needed on MinGW/win64. The "libc" there also uses x87 ops, so we need to set both since MLton native codegen uses the other. I assume it's supposed to affect cos/sin/etc? At least it passes the regressions as it is now. _______________________________________________ MLton mailing list MLton@... http://mlton.org/mailman/listinfo/mlton |
| Free Forum Powered by Nabble | Forum Help |