Created attachment 185277 [details] STYLE in conditional formatting The attached spreadsheet (FODT, simplified to bare minimum) has two cells (A1:A2) with conditional formatting having STYLE function that tries to set a style name differing (in character case) from the style name present in the document: it uses "STYLE(A1)" formula. The content of the cells is "A"; the style in the document is named "a" (and it gets applied to the cells, as one can see in the stylist). Since v.5.1, opening it and having the two cells in view, results in continuous 100% CPU consumption (single core). In that version, using OpenGL (Windows), menus still were working OK. Since v.5.2, using OpenGL, menus are shown blank (likely, the priority of drawing their content is lower than the priority of the continuous processing taking the 100% of a core). Disabling OpenGL, the menus are drawn OK, but the CPU consumption is unchanged (so the menu drawing priority is obviously different). In current master, Skia works the same way as OpenGL in old versions (now showing menus when the cells are in view; likely because it was modelled after OpenGL render, and has similar priorities). As before, not using Skia still shows continuous CPU consumption. Changing cells' content from "A" to "a" (to match case of actual style) stops the CPU consumption. The usefulness of using STYLE in conditional formatting is not a matter here, only the wrong effects.
Mike Kaganski committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/a80630b6ee6e7636d2c93c42724ce815c991311c Related: tdf#153510 Avoid modification of iterated container It will be available in 7.6.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
The CPU consumption part started after commit 87199d3829257420429057336283c55be6ae7481 ("vcl: re-introduce idle handling.", 2015-11-24). The menus disappeared after commit 8d6c1b6981f01bbc0057234f53fd139e87a5f010 ("tdf#96385 - opengl: dynamically adjust priority of swap buffers.", 2016-01-12).
Mike Kaganski committed a patch related to this issue. It has been pushed to "libreoffice-7-5": https://git.libreoffice.org/core/commit/a01f4a1c317520a7a3090cfb2f1c9f21bbc50922 Related: tdf#153510 Avoid modification of iterated container It will be available in 7.5.2. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Mike Kaganski committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/208a4ecafafa97ea7fcc5a135fa8160e91ea0a74 tdf#153510: STYLE: try harder to detect when there's nothing to do It will be available in 7.6.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Mike Kaganski committed a patch related to this issue. It has been pushed to "libreoffice-7-5": https://git.libreoffice.org/core/commit/fed875f35be3204a7d77bf315a07caaa3bf635e9 tdf#153510: STYLE: try harder to detect when there's nothing to do It will be available in 7.5.2. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Mike Kaganski committed a patch related to this issue. It has been pushed to "libreoffice-7-4": https://git.libreoffice.org/core/commit/f6aa9d4f9f5e7b46a89bf409a40b552570cf4d5f Related: tdf#153510 Avoid modification of iterated container It will be available in 7.4.6. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Let me call this fixed. The problem can still be reproduced by using three-argument STYLE in conditional formatting (and using different styles for immediate and delayed application), but that would be another issue (I suppose it would be much less likely to occur, and I don't have a good idea how to avoid the problem then, other than preventing misuse of the function in conditional formatting at all).
Mike Kaganski committed a patch related to this issue. It has been pushed to "libreoffice-7-4": https://git.libreoffice.org/core/commit/b2494cc8b9a22429e331e29093f7bb066ae5f8f2 tdf#153510: STYLE: try harder to detect when there's nothing to do It will be available in 7.4.6. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.