Re: Docs for allocation sinking optimization

  • From: Mike Pall <mike-1207@xxxxxxxxxx>
  • To: luajit@xxxxxxxxxxxxx
  • Date: Thu, 12 Jul 2012 12:09:55 +0200

Stefan Marr wrote:
> On 11 Jul 2012, at 17:59, Mike Pall wrote:
> > I'd be grateful, if anyone could point me to 1) a mistake in the
> > Java code or 2) an option that would allow Hotspot to eliminate
> > the temporary allocations.
> 
> Not sure whether you consider that cheating, or to much
> difference, but I would try to help the compiler by telling it
> that x and y are 'final'.

Doesn't change anything, same timing.

> Another thing the compiler could prefer is the 'ideomatic' use
> of getters and private fields.

Ditto.

Anyway, since reddit is discussing this now, I'm expecting a
massive collaborative effort by Javaists (is that what you call
them?) to improve the code. ;-)

http://www.reddit.com/r/programming/comments/wewx2/allocation_sinking_optimization_in_luajit/

--Mike

Other related posts: