public inbox for gsl-discuss@sourceware.org
 help / color / mirror / Atom feed
From: Gerard Jungman <jungman@lanl.gov>
To: GSL Discuss Mailing List <gsl-discuss@sourceware.org>
Subject: Re: gsl container designs
Date: Fri, 08 Jan 2010 20:08:00 -0000	[thread overview]
Message-ID: <1262981361.27244.383.camel@manticore.lanl.gov> (raw)
In-Reply-To: <alpine.LFD.2.00.1001062138040.3462@localhost>

On Wed, 2010-01-06 at 22:29 -0500, Robert G. Brown wrote:

> However, some of my beowulfish friends who work(ed)
> for compiler companies argued that one of Fortran's longstanding
> advantages in numerical code efficiency is simply because of the fact
> that matrices in Fortran are written in stone and so compiler writers
> can optimize the hell out of them.  C pointers, OTOH -- well,

I think the main difference is that fortran can assume no aliasing,
which allows some extra optimization that C cannot do. The new 
'restrict' keyword is supposed to help with this, but we'll see.


> I've written code to do so many times -- Numerical Recipes provides the
> basic idea in its matrix-packing routines.  Simply allocate e.g.
> 
> double **..*m,*v;

I understand the mechanics of it. I'm not sure what my concern was;
I thought about this a few months ago and decided there was some
semantic problem. But it looks like the **..*m has exactly the
same life-cycle and maintenance as *v, so I'm not sure what I
was thinking. It might come back to me.


> I can probably dig this code out and post it here (or post a link to it)
> if you want to look at it.  I think I went up to 9 or 10 dimensions (way
> more than I needed) and did a lot of things via brute force to make the
> purely mechanical recursion obvious; I planned an eventual rewrite into
> a more compact form that I never got around to.

Sure. Feel free to post it. I like to look at everything and
cherry-pick the best parts from other people's stuff. Makes
things a lot easier.


--
G. Jungman


  parent reply	other threads:[~2010-01-08 20:08 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-11-25  0:55 Gerard Jungman
2009-11-29 21:04 ` Brian Gough
2009-12-04 18:48 ` Brian Gough
2009-12-09 21:04   ` using GSL with C++ (was Re: gsl container designs) James Amundson
2009-12-09 21:14     ` Jochen Küpper
2009-12-09 21:54     ` Jari Häkkinen
2009-12-10 11:46     ` Brian Gough
2009-12-10 12:09       ` Brian Gough
2009-12-10 13:42     ` Robert G. Brown
2009-12-10 21:44       ` James Bergstra
2009-12-10 15:15     ` Kevin H. Hobbs
2010-01-06 11:45   ` gsl container designs Tuomo Keskitalo
2010-01-06 15:47     ` Robert G. Brown
2010-01-07  1:50       ` Gerard Jungman
2010-01-07  3:29         ` Robert G. Brown
     [not found]           ` <4a00655d1001062110m139c0a8tf2eae7de67da8f6f@mail.gmail.com>
2010-01-07  5:46             ` Rhys Ulerich
2010-01-07 13:22               ` Robert G. Brown
2010-01-08 20:08           ` Gerard Jungman [this message]
2010-01-07 18:29     ` Brian Gough
2010-01-06 12:04 ` Tuomo Keskitalo
2010-01-06 19:57   ` Gerard Jungman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1262981361.27244.383.camel@manticore.lanl.gov \
    --to=jungman@lanl.gov \
    --cc=gsl-discuss@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).