marcomachadosantos / gwt-chronoscope

Automatically exported from code.google.com/p/gwt-chronoscope
GNU Lesser General Public License v2.1
0 stars 0 forks source link

Optimize some hot methods in DefaultXYPlot to improve web-mode rendering performance #88

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
This issue is loosely related to Issue #87 (http://code.google.com/p/gwt-
chronoscope/issues/detail?id=87), which deals with removing some argument 
checking in 
JavaArray2D.get() to facilitate more optimized GWT compiled code.

On Nov-10-2008, Ray Cromwell wrote:

  After that getX() method, the next 2 methods which are hot (besides drawText and 
drawCurvePart) is the dataToUser call for domain axis, and the 
DefaultXYPlot.rangeToScreenY()  
The dataToUser() function  contains a denominator getRange() which is 
unchanging unless some 
other state in the axis changes. So we can optimize this further by caching the 
result and making 
getRange() return a cached value.

About 9% of the time is taken up by the canCastUnsafe/dynamicCast routines 
inserted by the 
GWT compiler, which we can do nothing about. I'm going to agitate for a 
compilation mode that 
switches these off.

Original issue reported on code.google.com by chadtaka...@gmail.com on 11 Nov 2008 at 9:23

GoogleCodeExporter commented 8 years ago

Original comment by cromwell...@gmail.com on 10 Mar 2010 at 1:22