FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Debian > Debian Development

 
 
LinkBack Thread Tools
 
Old 05-04-2010, 12:54 PM
Niko Tyni
 
Default perl: 64-bit integers and long doubles

(sent to -devel and -perl; followups to -devel only, please)

Hi,

unlike earlier versions, perl 5.12.0-1 in experimental is configured with
the "use64bitint" and "uselongdouble" options on all architectures. I'm
looking for input on whether this is the right choice for sid.

For reference, quoting the upstream INSTALL file:

The "use64bitint" option does only as much as is required to get 64-bit
integers into Perl (this may mean, for example, using "long longs")
while your memory may still be limited to 2 gigabytes (because your
pointers could still be 32-bit). Note that the name "64bitint" does
not imply that your C compiler will be using 64-bit "int"s (it might,
but it doesn't have to). The "use64bitint" simply means that you will
be able to have 64 bit-wide scalar values.

In some systems you may be able to use long doubles to enhance the
range and precision of your double precision floating point numbers
(that is, Perl's numbers). Use Configure -Duselongdouble to enable
this support (if it is available)

The benefits are obviously improved numeric range and precision. The
downside is presumably increased memory usage. I have no measurement
data on this; suggestions on suitable tests would be welcome.

There's a short upstream discussion on the topic starting at
http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2010-04/msg00757.html
with the conclusion that you can't please everybody.

It would be possible to choose these settings separately for each architecture.
Should I exclude the 'smaller' architectures (armel, mips*?)

It looks like powerpc won't get long doubles anyway, see #578295.


My test rebuilds have turned out just one package breaking due to
use64bitint (#579450) and a dozen due to the uselongdouble setting.

http://bugs.debian.org/cgi-bin/pkgreport.cgi?tag=perl-long-double;users=debian-perl@lists.debian.org

The longdouble failures are mostly equivalence comparisons of floating
point values, which is normally a bug even when it works.

A complication is that it's hard to change these settings after an upload
to unstable because they change the binary interface. The perlapi-*
dependencies specified in the Perl policy only allow for ABI breaks when
the upstream version changes, so the transition would be a mess.

See #579457 for an idea of how to make a cleaner transition possible;
even with that, it would be very much preferrable to get this "right"
the first time.
--
Niko Tyni ntyni@debian.org


--
To UNSUBSCRIBE, email to debian-devel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 20100504125419.GA8081@madeleine.local.invalid">htt p://lists.debian.org/20100504125419.GA8081@madeleine.local.invalid
 
Old 05-04-2010, 03:29 PM
Florian Weimer
 
Default perl: 64-bit integers and long doubles

* Niko Tyni:

> The benefits are obviously improved numeric range and precision. The
> downside is presumably increased memory usage. I have no measurement
> data on this; suggestions on suitable tests would be welcome.

I have run into several incompatibilities between i386 and amd64 due
to different Perl integer sizes, so I'm definitely in favor of 64-bit
integers.

I'm not sure if long doubles are a win. The rest of the world runs on
64 bit floating point numbers, so this would introduce additional
incompatibilities.


--
To UNSUBSCRIBE, email to debian-devel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 87iq73u1mo.fsf@mid.deneb.enyo.de">http://lists.debian.org/87iq73u1mo.fsf@mid.deneb.enyo.de
 
Old 05-05-2010, 03:50 AM
"Brendan O'Dea"
 
Default perl: 64-bit integers and long doubles

On 4 May 2010 22:54, Niko Tyni <ntyni@debian.org> wrote:
> unlike earlier versions, perl 5.12.0-1 in experimental is configured with
> the "use64bitint" and "uselongdouble" options on all architectures. I'm
> looking for input on whether this is the right choice for sid.

Sounds like a good idea to me. I had intended to do this for 5.10, as
noted in #310995, but it appears to have slipped through the cracks at
the time.

> It would be possible to choose these settings separately for each architecture.
> Should I exclude the 'smaller' architectures (armel, mips*?)

You could ask debian-arm@lists.debian.org and the other ports lists,
but it seems reasonable to include 64bit support only on those
architectures where there is native 64 bit support in the chipset.

> A complication is that it's hard to change these settings after an upload
> to unstable because they change the binary interface. The perlapi-*
> dependencies specified in the Perl policy only allow for ABI breaks when
> the upstream version changes, so the transition would be a mess.
>
> See #579457 for an idea of how to make a cleaner transition possible;
> even with that, it would be very much preferrable to get this "right"
> the first time.

I suspect that you may be over-thinking this. More comments in that
bug shortly.

--bod


--
To UNSUBSCRIBE, email to debian-devel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: AANLkTikRlwvLFCJPi5V0DO16lci6t2yPkAKe39f1LKzl@mail .gmail.com">http://lists.debian.org/AANLkTikRlwvLFCJPi5V0DO16lci6t2yPkAKe39f1LKzl@mail .gmail.com
 
Old 05-08-2010, 10:28 AM
Niko Tyni
 
Default perl: 64-bit integers and long doubles

On Tue, May 04, 2010 at 05:29:03PM +0200, Florian Weimer wrote:
> * Niko Tyni:
>
> > The benefits are obviously improved numeric range and precision. The
> > downside is presumably increased memory usage. I have no measurement
> > data on this; suggestions on suitable tests would be welcome.
>
> I have run into several incompatibilities between i386 and amd64 due
> to different Perl integer sizes, so I'm definitely in favor of 64-bit
> integers.
>
> I'm not sure if long doubles are a win. The rest of the world runs on
> 64 bit floating point numbers, so this would introduce additional
> incompatibilities.

I wasn't initially going for long doubles, but several upstream
developers recommended that they be enabled together.

http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2010-04/msg00773.html
http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2010-04/msg00895.html

Given that we've already run into a dozen or so incompatibilities
with just the CPAN modules, -Duselongdouble seems to be a pretty
rare thing to do. I'm inclined to revert this setting.

On Wed, May 05, 2010 at 01:50:30PM +1000, Brendan O'Dea wrote:
> On 4 May 2010 22:54, Niko Tyni <ntyni@debian.org> wrote:

> > It would be possible to choose these settings separately for each architecture.
> > Should I exclude the 'smaller' architectures (armel, mips*?)
>
> You could ask debian-arm@lists.debian.org and the other ports lists,
> but it seems reasonable to include 64bit support only on those
> architectures where there is native 64 bit support in the chipset.

Good point. Can anybody list our "pure" 32-bit architectures off-hand
or suggest a simple test? Checking the instruction set for each one
is a bit on the laborous side...

Ideally, I'd like to have a concrete plan to send to the ports lists
and just ask for any objections.
--
Niko Tyni ntyni@debian.org


--
To UNSUBSCRIBE, email to debian-devel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 20100508102808.GA9836@madeleine.local.invalid">htt p://lists.debian.org/20100508102808.GA9836@madeleine.local.invalid
 
Old 05-08-2010, 03:15 PM
Frans Pop
 
Default perl: 64-bit integers and long doubles

Niko Tyni wrote:
> Can anybody list our "pure" 32-bit architectures off-hand
> or suggest a simple test?

AFAIK for Squeeze the arches are as follows, but please anybody correct me
where incorrect.

arch kernel userland
-------------- ------ --------
i386 32/64 32
amd64 64 64
alpha 32 32
armel 32 32
hppa 32/64 32
ia64 64 64
mips/mipsel 32 32
powerpc 32/64 32
sparc 32 32
s390 64 32

kfreebsd-i386 32/64 32
kfreebsd-amd64 64 64
hurd-i386 32 32

hurd-i386 does not seem to have a 64-bit kernel option.

Cheers,
FJP


--
To UNSUBSCRIBE, email to debian-devel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 201005081715.51168.elendil@planet.nl">http://lists.debian.org/201005081715.51168.elendil@planet.nl
 
Old 05-08-2010, 03:26 PM
Julien Cristau
 
Default perl: 64-bit integers and long doubles

On Sat, May 8, 2010 at 17:15:50 +0200, Frans Pop wrote:

> Niko Tyni wrote:
> > Can anybody list our "pure" 32-bit architectures off-hand
> > or suggest a simple test?
>
> AFAIK for Squeeze the arches are as follows, but please anybody correct me
> where incorrect.
>
> arch kernel userland
> -------------- ------ --------
> i386 32/64 32
> amd64 64 64
> alpha 32 32

alpha is all 64.

> armel 32 32
> hppa 32/64 32
> ia64 64 64
> mips/mipsel 32 32
> powerpc 32/64 32
> sparc 32 32

and sparc kernel is 64.

> s390 64 32
>
> kfreebsd-i386 32/64 32
> kfreebsd-amd64 64 64
> hurd-i386 32 32
>
> hurd-i386 does not seem to have a 64-bit kernel option.
>
Cheers,
Julien
 
Old 05-08-2010, 03:44 PM
Philipp Kern
 
Default perl: 64-bit integers and long doubles

On 2010-05-08, Frans Pop <elendil@planet.nl> wrote:
> arch kernel userland
> -------------- ------ --------
> alpha 32 32

Isn't alpha the first 64bit of all?

> mips/mipsel 32 32

I think that's 32/64, 32; at least for mipsel.

> sparc 32 32

Certainly 64, 32 here.

> s390 64 32

64/31 *grin*, at least if talking about memory addresses.

Kind regards,
Philipp Kern


--
To UNSUBSCRIBE, email to debian-devel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: slrnhub1m3.akb.trash@kelgar.0x539.de">http://lists.debian.org/slrnhub1m3.akb.trash@kelgar.0x539.de
 
Old 05-08-2010, 04:06 PM
Frans Pop
 
Default perl: 64-bit integers and long doubles

On Saturday 08 May 2010, Julien Cristau wrote:
> alpha is all 64.

Shows that alpha is the arch I'm least familiar with...

> and sparc kernel is 64.

This I should have gotten right :-(

Thanks.


--
To UNSUBSCRIBE, email to debian-devel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 201005081806.52852.elendil@planet.nl">http://lists.debian.org/201005081806.52852.elendil@planet.nl
 
Old 05-08-2010, 04:38 PM
Florian Lohoff
 
Default perl: 64-bit integers and long doubles

On Sat, May 08, 2010 at 03:44:03PM +0000, Philipp Kern wrote:
> On 2010-05-08, Frans Pop <elendil@planet.nl> wrote:
> > arch kernel userland
> > -------------- ------ --------
> > alpha 32 32
>
> Isn't alpha the first 64bit of all?
>
> > mips/mipsel 32 32
>
> I think that's 32/64, 32; at least for mipsel.

Userspace for mips and mipsel is 32bit (o32 abi) and the kernel is
32/64 depending on the machine type. This has nothing to do with the
endianess - we should have 64 bit swarm little and big endian kernels.

Flo
--
Florian Lohoff f@zz.de
"Es ist ein grobes Missverständnis und eine Fehlwahrnehmung, dem Staat
im Internet Zensur- und Überwachungsabsichten zu unterstellen."
- - Bundesminister Dr. Wolfgang Schäuble -- 10. Juli in Berlin
 
Old 05-09-2010, 08:04 AM
Stefan Fritsch
 
Default perl: 64-bit integers and long doubles

On Wednesday 05 May 2010, Brendan O'Dea wrote:
> > It would be possible to choose these settings separately for each
> > architecture. Should I exclude the 'smaller' architectures
> > (armel, mips*?)
>
> You could ask debian-arm@lists.debian.org and the other ports
> lists, but it seems reasonable to include 64bit support only on
> those architectures where there is native 64 bit support in the
> chipset.

I may be a bit late to this discussion, but aren't 64bit ints (and
especially pack/unpack "Q") very useful for 64bit file pointers and
such? IMHO, this means that they would also be very useful on
"smaller" architectures like arm.

In any case, there isn't really a strong connection with 64bit
instructions in the processor. An executable compiled for 32bit cannot
use those instructions anyway. So the issue is just perl's memory
usage compared to the memory usually available on such systems. Do you
have any experience how memory usage increases with 64bit support in
real life usage?


Cheers,
Stefan


--
To UNSUBSCRIBE, email to debian-devel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 201005091004.59281.sf@sfritsch.de">http://lists.debian.org/201005091004.59281.sf@sfritsch.de
 

Thread Tools




All times are GMT. The time now is 08:32 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2007 - 2008, www.linux-archive.org