On Thu, 25 Jul 2024 22:53:36 GMT, Phil Race <[email protected]> wrote:

> Migrate from using Unsafe to FFM's MemorySegment API for allocating and 
> setting native memory.
> This code is used by Metal, OpenGL and D3D, so I manually tested SwingSet2 
> and J2Demo as well as running all the usual tests.
> I also did some micro-benchmarking on the performance of Unsafe vs 
> MemorySegment.
> The performance of either is more than sufficient for us .. ie they could be 
> 10x slower and we wouldn't even notice.
> But they are in the same ballpark, and if one or the other is clearly faster 
> it is the new FFM code.

This pull request has now been integrated.

Changeset: c0384b6f
Author:    Phil Race <[email protected]>
URL:       
https://git.openjdk.org/jdk/commit/c0384b6f3584501fb3bd93854734eeacf6620a7e
Stats:     78 lines in 1 file changed: 4 ins; 18 del; 56 mod

8337237: Use FFM instead of Unsafe for Java 2D RenderBuffer class

Reviewed-by: jvernee, jdv

-------------

PR: https://git.openjdk.org/jdk/pull/20339

Reply via email to