[Numpy-discussion] Request for review: dynamic_cpu_branch

Charles R Harris charlesr.harris at gmail.com
Tue Dec 23 00:55:51 EST 2008


On Mon, Dec 22, 2008 at 10:40 PM, David Cournapeau <cournape at gmail.com>wrote:

> On Tue, Dec 23, 2008 at 2:35 PM, Robert Kern <robert.kern at gmail.com>
> wrote:
>
> >
> > I think he meant that it can be discovered at runtime in general, not
> > at numpy-run-time, so we can write a small C program that can be run
> > at numpy-build-time to add another entry to config.h.
>
> But then we only move the problem: people who want to build universal
> numpy extensions will have the wrong value, no ? The fundamental point
> of my patch is that the value is set whenever ndarrayobject.h is
> included. So even if I build numpy on PPC, NPY_BIGENDIAN will not be
> defined when the header is included for a file build with gcc -arch
> i386.
>

We can probably set things up so the determination is at run time -- but we
need to be sure that the ABI isn't affected. I did that once for an old
project that needed data portability. In any case, it sounds like a project
for a later release.

Chuck
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20081222/cb9585b7/attachment.html>


More information about the NumPy-Discussion mailing list