Re: Tuning numerical computations for LuaJIT (was Re: [ANN] Sci-1.0-beta1)

  • From: "M. Edward (Ed) Borasky" <znmeb@xxxxxxxxx>
  • To: luajit@xxxxxxxxxxxxx
  • Date: Thu, 20 Sep 2012 14:46:56 -0700

I'm sure this is old news to most of you, but the absolute best
resource I've ever found on x86_64 optimization, premature or
otherwise, is http://www.agner.org/optimize/.

The flip side is that I don't know of anything similar for ARM. Then
again, given that my i5 laptop gets about 10 GFLOPS and iPads are
straining to get 50 MFLOPS, maybe it can wait. ;-)


On Thu, Sep 20, 2012 at 12:28 PM, Geoff Leyland
<geoff_leyland@xxxxxxxxxxx> wrote:
> On 21/09/2012, at 12:28 AM, Mike Pall wrote:
>
>> * Do not try to second-guess the JIT compiler.
>>  - It's perfectly ok to write 'z = x[a+b] + y[a+b]'.
>>    - Do not try CSE by hand, e.g. 'local c = a+b'.
>
> Could you expand on this a little?  I asks because sometimes "hand-made CSE" 
> improves readability, so:
>  - Is it actually detrimental to do the above, or just pointless as a speed 
> optimization?
>  - Does this only apply to index expressions? (I suspect not, but all your 
> examples involved indexes)
>  - Does this only apply to relatively simple expressions, if so, can you say 
> roughly how simple?
>
> Geoff



-- 
Twitter: http://twitter.com/znmeb; Computational Journalism Publishers
Workbench: http://j.mp/QCsXOr

How the Hell can the lion sleep with all those people singing "A weem
oh way!" at the top of their lungs?

Other related posts: