Re: [Qemu-devel] [Bug 645662] x87 fpu emulation not accurate enough

2017-12-06 Thread KONRAD Frederic
On 11/29/2017 04:32 PM, Thomas Huth wrote: On 29.11.2017 16:20, KONRAD Frederic wrote: On 11/29/2017 01:51 PM, Peter Maydell wrote: On 29 November 2017 at 12:47, KONRAD Frederic wrote: Maybe a little hack might work for x86 on x86 though. Something like hardcoding the helper with an inlin

Re: [Qemu-devel] [Bug 645662] x87 fpu emulation not accurate enough

2017-11-29 Thread Thomas Huth
On 29.11.2017 16:20, KONRAD Frederic wrote: > > > On 11/29/2017 01:51 PM, Peter Maydell wrote: >> On 29 November 2017 at 12:47, KONRAD Frederic >> wrote: >>> Maybe a little hack might work for x86 on x86 though. >>> Something like hardcoding the helper with an inline assembly >>> code? >> >> The

Re: [Qemu-devel] [Bug 645662] x87 fpu emulation not accurate enough

2017-11-29 Thread KONRAD Frederic
On 11/29/2017 01:51 PM, Peter Maydell wrote: On 29 November 2017 at 12:47, KONRAD Frederic wrote: Maybe a little hack might work for x86 on x86 though. Something like hardcoding the helper with an inline assembly code? The set of people who want to emulate x86 on x86 is surely even smaller

Re: [Qemu-devel] [Bug 645662] x87 fpu emulation not accurate enough

2017-11-29 Thread Peter Maydell
On 29 November 2017 at 12:47, KONRAD Frederic wrote: > Maybe a little hack might work for x86 on x86 though. > Something like hardcoding the helper with an inline assembly > code? The set of people who want to emulate x86 on x86 is surely even smaller than the already tiny set of people who want

Re: [Qemu-devel] [Bug 645662] x87 fpu emulation not accurate enough

2017-11-29 Thread KONRAD Frederic
On 11/29/2017 11:27 AM, Peter Maydell wrote: On 29 November 2017 at 09:59, william lin wrote: This bug has been around for 7+ years now. Qemu switched to softfloat and it did not fix this. I think its most likely caused by Qemu's internal representation not being accurate enough or accuracy l

Re: [Qemu-devel] [Bug 645662] x87 fpu emulation not accurate enough

2017-11-29 Thread Peter Maydell
On 29 November 2017 at 09:59, william lin wrote: > This bug has been around for 7+ years now. Qemu switched to softfloat and > it did not fix this. I think its most likely caused by Qemu's internal > representation not being accurate enough or accuracy lost during > conversion. However this is bas

Re: [Qemu-devel] [Bug 645662] x87 fpu emulation not accurate enough

2017-11-29 Thread KONRAD Frederic
I would write some more basic tests. eg: at instruction level and compare KVM vs TCG mode to find out which trigo instructions are differents (probably not only one). BTW I'm not floating point expert at all :). Fred On 11/29/2017 10:59 AM, william lin wrote: Hi, The goal of the project is to

Re: [Qemu-devel] [Bug 645662] x87 fpu emulation not accurate enough

2017-11-29 Thread william lin
Hi, The goal of the project is to fix the bug. Sorry I should have been more clear. This bug has been around for 7+ years now. Qemu switched to softfloat and it did not fix this. I think its most likely caused by Qemu's internal representation not being accurate enough or accuracy lost during con

Re: [Qemu-devel] [Bug 645662] x87 fpu emulation not accurate enough

2017-11-29 Thread KONRAD Frederic
Hi, I have the same problem here with some of our math testsuites. It's about some precision issue with trigonometric tests. I didn't had time to figure out what happen neither what is really going wrong. eg: trigonometric function or? A quick workaround is to use KVM when possible. Fred On 1