On Mon Jun 30 13:14:24 2025 +0000, Vibhav Pant wrote:
> It would improve readability if `full_charge_capacity`, `capacity_now`
> and `rate_now` in `linux_battery` were instead replaced with an inline
> `union` type, something like
> ```c
> union {
> struct {
> int charge_full_uah;
> int charge_now_uah;
> int current_now_ua;
> } charge;
> struct {
> int energy_full_uwh;
> int energy_now_uwh;
> int power_now_uw;
> } energy;
> } capacity_now;
> ```
> With `power_unit` as the tag. The `fill_battery_state` code would also
> be much clearer as a result.
Hi Vibhav,
I had forgotten to ask if the changes reflected your suggestion.
Let me know if you'd prefer something else or I got something wrong. Thanks.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/8460#note_108509
Fixes gdiplus tests in Clang build.
When the compiler assumes non-trapping floating-point math, it may apply more aggressive optimizations. For example, in the fast path of `GdipInvertMatrix`, it may merge paired divisions into a single `divss` instruction. This can leave unused lanes whose results are ignored, but they still execute and may cause a division by zero, breaking tests that have the FP exception mask enabled.
Using `-ffp-exception-behavior=maytrap` prevents the compiler from performing such transformations.
It's a bit surprising that this flag also disables optimizations like those seen in the dmime tests, so there’s likely room for improvement on the compiler side. Regardless, relying on `round()` in tests isn't valid, as it's not available in msvcrt.dll and may depend on compiler-specific behavior.
--
v3: configure: Build PEs with -ffp-exception-behavior=maytrap.
https://gitlab.winehq.org/wine/wine/-/merge_requests/8474
MAX messenger crashes without getting a valid pointer to PersistentZoneIdentifier COM object. Adding a stubbed COM object solves the problem
--
v4: urlmon: Add PersistentZoneIdentifier COM object stubs
https://gitlab.winehq.org/wine/wine/-/merge_requests/8456
MAX messenger crashes without getting a valid pointer to PersistentZoneIdentifier COM object. Adding a stubbed COM object solves the problem
--
v3: urlmon: Add PersistentZoneIdentifier COM object stubs
https://gitlab.winehq.org/wine/wine/-/merge_requests/8456
Fixes gdiplus tests in Clang build.
When the compiler assumes non-trapping floating-point math, it may apply more aggressive optimizations. For example, in the fast path of `GdipInvertMatrix`, it may merge paired divisions into a single `divss` instruction. This can leave unused lanes whose results are ignored, but they still execute and may cause a division by zero, breaking tests that have the FP exception mask enabled.
Using `-ffp-exception-behavior=maytrap` prevents the compiler from performing such transformations.
It's a bit surprising that this flag also disables optimizations like those seen in the dmime tests, so there’s likely room for improvement on the compiler side. Regardless, relying on `round()` in tests isn't valid, as it's not available in msvcrt.dll and may depend on compiler-specific behavior.
--
v2: configure: Build PEs with -ffp-exception-behavior=maytrap.
dmime/tests: Use ceil instead of round.
https://gitlab.winehq.org/wine/wine/-/merge_requests/8474