This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: Possible improvement in next_permutation implementation
- From: Paolo Carlini <pcarlini at suse dot de>
- To: David GONZALEZ MALINE <David dot Gonzalez dot Maline at cern dot ch>
- Cc: libstdc++ at gcc dot gnu dot org
- Date: Wed, 05 Mar 2008 18:42:47 +0100
- Subject: Re: Possible improvement in next_permutation implementation
- References: <47CE831E.2030703@cern.ch>
Hi David,
and many thanks for your feedback. By the way, months ago I mentioned
many times in private talk with people working at CERN that I was
"disappointed" by the lack of feedback from all the power users working
there... Good news, then ;)
I wonder whether it would be possible to make an implementation of the
standard library method closer to what the gsl algorithm does. The
three algorithms are intrinsically the same one, but the way they have
been implemented differ in the small details, and that is what makes
the difference in time. I also wonder, what is the reason to have
implemented the algorithm this way. There may be reasons I do not see
because of my poor knowledge of the implementation of the library.
I will look into it, but I suppose there aren't very deep explanations,
assuming the basic algorithm is the same, of course, only historical
reasons, the usual ones, lack of feedback (see above)... As I said, I
will look into the details of the issue, but in the meanwhile, if you
feel like providing additional help (I don't know, pseudo-code,
whatever), you are more than welcome, of course.
Paolo.
PS Last saturday, I visited ATLAS!