https://bugs.winehq.org/show_bug.cgi?id=57782
Bug ID: 57782 Summary: gdiplus:brush test crashes in _controlfp_s on intel mac Product: Wine Version: 10.0 Hardware: x86-64 OS: MacOS Status: NEW Severity: normal Priority: P2 Component: msvcrt Assignee: wine-bugs@winehq.org Reporter: madewokherd@gmail.com
On my intel mac, the gdiplus:brush crashes with: 0024:err:seh:call_seh_handlers invalid frame 00000001000FF790 (0000000000022000-0000000000220000) 0024:err:seh:NtRaiseException Exception frame is not in stack limits => unable to dispatch exception.
If I comment out the line calling _controlfp_s in brush.c, the test succeeds.
https://bugs.winehq.org/show_bug.cgi?id=57782
Esme Povirk madewokherd@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |madewokherd@gmail.com Keywords| |download, source, testcase
https://bugs.winehq.org/show_bug.cgi?id=57782
Piotr Caban piotr.caban@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Component|msvcrt |-unknown CC| |piotr.caban@gmail.com
--- Comment #1 from Piotr Caban piotr.caban@gmail.com --- It's not an msvcrt bug - setting component to unknown.
The same exception can be seen on Linux when Wine is compiled with Clang. We're getting _EM_INVALID exception in monitor_get_dpi function when computing scale_x and scale_y. I didn't look what exactly is happening there. I'm not sure what's the correct fix - maybe we should mask some floating point exceptions in syscalls.
There are more exceptions if monitor_get_dpi is hacked to workaround this issue. I didn't look on the next one.
https://bugs.winehq.org/show_bug.cgi?id=57782
--- Comment #2 from Piotr Caban piotr.caban@gmail.com --- In case of monitor_get_dpi it should be possible to avoid the problem with MulDiv function.
Next problem is in GdipInvertMatrix. In this case code generated by Clang also throws EM_INVALID exception. I have worked around it with a hack and all the remaining tests passed. So these seems to be the only 2 functions that are affected.
Probably the next step is to determine if compiler is correct creating code that can emit such exception.