[OpenJDK 2D-Dev] RFR 8159638: Improve array caches and renderer stats in Marlin renderer
    Jim Graham 
    james.graham at oracle.com
       
    Tue Aug  2 21:56:50 UTC 2016
    
    
  
Thanks Laurent,
On 08/02/2016 05:57 AM, Laurent Bourgès wrote:
> Thanks for the tip, I made another webrev (for archive) that shows the
> proper diffs in ArrayCache / ArrayCacheConst:
> http://cr.openjdk.java.net/~lbourges/marlin/marlin-8159638.1_bis/
> <http://cr.openjdk.java.net/%7Elbourges/marlin/marlin-8159638.1_bis/>
Thanks!
>     In Renderer.java, you create the alphaLine and blkFlags refs as
>     Clean, but then you always put them back using indices of (0, 0) so
>     they will never actually be cleaned - is there a reason you don't
>     just use a dirty ref there?
>
> Both alphaLine and blkFlags arrays must be zero-filled as these arrays
> are storing accumulated values:
>
> It is not possible to use a dirty reference in this case as both
> allocated and returned array may contain garbage data (from the
> IntArrayCache).
D'oh!  I guess that was obvious.  I wasn't thinking of the fact that 
dirty caches can initially return a non-zero-filled array - the fact 
that they clean on "put" is only half of their zero guarantee...
>     Other than that question, I don't see any problems with the fix...
>
> Ready to go ?
> or I need another reviewer, phil ?
Ready from my end.  Phil?
			...jim
    
    
More information about the 2d-dev
mailing list