comp.lang.ada
 help / color / mirror / Atom feed
From: Robert Eachus <rieachus@comcast.net>
Subject: Re: Extend slices for n dimensional arrays for Ada 202X
Date: Fri, 27 Jan 2017 16:58:36 -0800 (PST)
Date: 2017-01-27T16:58:36-08:00	[thread overview]
Message-ID: <e5b5c26f-9797-4502-a720-c8e126b37ab6@googlegroups.com> (raw)
In-Reply-To: <o6gl6n$c9p$1@franka.jacob-sparre.dk>

On Friday, January 27, 2017 at 6:30:32 PM UTC-5, Randy Brukardt wrote:

> Single dimensional slices are of course completely different, and I wasn't 
> talking about them. (Although your advice for copying them is 25 years out 
> of date: Intel hardware, at least, automatically makes many of those 
> optimizations so there is no value to manually doing them yourself - that 
> actually would make your code slower.)

As it happens, when I get down to the point of considering actual cache sizes and TLBs, I am coding for AMD CPUs.  (Even have one in this system. ;-)  But believe me, 4 or 5% time improvement is considered worthwhile, and I am usually doing finding 50% or more.  It also turns out that I am usually working on low-level routines often in BLAS that are eating loads of CPU time.  Oh, and I have yet to convince anyone to make the main program Ada instead of Fortran, but that's another issue.

Yes, modern CPUs will reorder operations to improve performance, but the reorder buffers have a limited reach.  So if you are transposing an array which is thousands of rows and columns in size, the programmer has to bring the instructions that should be brought together close enough that the CPU can do the rest.


  reply	other threads:[~2017-01-28  0:58 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-26 13:29 REQ: Extend slices for n dimensional arrays for Ada 202X Lucretia
2017-01-26 14:01 ` Lucretia
2017-01-26 14:03   ` Lucretia
2017-01-26 14:52   ` Dmitry A. Kazakov
2017-01-27  9:19     ` Alejandro R. Mosteo
2017-01-27 14:04     ` Lucretia
2017-01-26 18:29 ` Randy Brukardt
2017-01-27  1:54   ` Robert Eachus
2017-01-27  5:39     ` Robert Eachus
2017-01-27 14:06     ` Lucretia
2017-01-27 23:30     ` Randy Brukardt
2017-01-28  0:58       ` Robert Eachus [this message]
2017-01-27  9:34   ` Dmitry A. Kazakov
2017-01-27 13:53     ` G.B.
2017-01-27 14:20       ` Dmitry A. Kazakov
2017-01-27 23:37       ` Randy Brukardt
2017-01-28  9:08         ` Dmitry A. Kazakov
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox