[OpenJDK 2D-Dev] [10] RFR JDK-8191814: Marlin rasterizer spends time computing geometry for stroked segments that do not intersect the clip
Laurent Bourgès
bourges.laurent at gmail.com
Mon Dec 11 20:32:19 UTC 2017
Hi,
I pushed in jdk forrest:
http://hg.openjdk.java.net/jdk/client/rev/fd7fbc929001
Thanks for your reviews, Phil & Sergey !
Laurent
2017-12-07 20:43 GMT+01:00 Sergey Bylokhov <Sergey.Bylokhov at oracle.com>:
> I am not an expert here, I just look to the changes and run the closed
> tests for jdk_desktop group. No new issues were found, so it looks fine to
> me.
>
> On 05/12/2017 06:30, Laurent Bourgès wrote:
>
>> Hi again,
>>
>> Here is a new webrev fixing the ClipShapeTest:
>> http://cr.openjdk.java.net/~lbourges/marlin/marlin-082-8191814.1/
>>
>> Changes:
>> - @run twice to test both Marlin variants (float / double)
>> - use Logger to get & check marlin system properties
>> ("sun.java2d.renderer.clip.runtime.enable") to ensure the test is run
>> against a Marlin renderer having the clipping features
>>
>> I tested the fixed test on JDK9 and it fails:
>> runner finished test: sun/java2d/marlin/ClipShapeTest.java
>> Failed. Execution failed: `main' threw exception:
>> java.lang.RuntimeException: Marlin clipping not enabled at runtime !
>>
>> On JDK10 + patch, it passes:
>> sun/java2d/marlin/ClipShapeTest.java
>> Passed. Execution successful
>>
>>
>> PS: Could anyone review the patch ? before RDP1 deadline ?
>>
>> Regards,
>> Laurent
>>
>>
>> 2017-12-04 23:35 GMT+01:00 Laurent Bourgès <bourges.laurent at gmail.com
>> <mailto:bourges.laurent at gmail.com>>:
>>
>> Hi Sergey,
>>
>> Thanks for your comment.
>>
>> This new test only validates the new clipping algorithms ie it
>> compares the rendering outputs with / without clipping enabled.
>>
>> As such algorithms are only available in Marlin 0.8.2 and the test
>> uses new system properties to enable/disable clipping, I confirm it
>> passes before (jdk9 or jdk10 before patch).
>>
>> To ensure it detects any regression, I manually inserted some bugs
>> in the clipping code, and the test failed.
>>
>> Note: I should add another test @run to check the float variant too
>> (and not only the double variant, the default in jdk10).
>>
>> Finally I could write a new performance test that would prove
>> clipping is more efficient than before.
>> Such test would fail before patch (timeout ?), but it is difficult
>> to make it robust as it depends on the hw.
>> Jim wrote a basic test in the jfx bug showing 300ms without but 2ms
>> now => gain is high.
>> A possible success condition would be: clipping gain > 10 or 50.
>>
>> Regards,
>> Laurent
>>
>>
>> Le 4 déc. 2017 11:11 PM, "Sergey Bylokhov"
>> <Sergey.Bylokhov at oracle.com <mailto:Sergey.Bylokhov at oracle.com>> a
>> écrit :
>>
>> Hi, Laurent.
>>
>> On 29/11/2017 14:30, Laurent Bourgès wrote:
>>
>> - added new ClipShapeTest (jtreg) that checks all possible
>> combinations of (cap / join) for random polyline (Stroker)
>> and polygons (Filler) comparing image outputs rendered with
>> clipping enabled vs disabled
>>
>>
>> I have only one note that the test is passed before the fix, so
>> if we will regress at some point later we will not catch this.
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/2d-dev/attachments/20171211/f21bd1f3/attachment.html>
More information about the 2d-dev
mailing list