Re: Bug#609690: Debian x86 32-bits built for i586 !?

2011-05-17 Thread Henrique de Moraes Holschuh
On Tue, 17 May 2011, Matthias Klose wrote:
> >Assuming we can't just do away with i486 support for now, did anyone track
> >down exactly what was causing breakages that forced the change from
> >march=486 to march=586?
> 
> libgomp assumes 586; there were some GFortran/OMP issues on i386.

"assumes 586" is pretty damn vague.  Does it use 586-only instructions,
or what?

I have no strong opinions about dropping i486 or not.  All boxes I could
ever care about, even at work, are either amd64 or i686.

-- 
  "One disk to rule them all, One disk to find them. One disk to bring
  them all and in the darkness grind them. In the Land of Redmond
  where the shadows lie." -- The Silicon Valley Tarot
  Henrique Holschuh


-- 
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20110518004514.ga2...@khazad-dum.debian.net



Re: Bug#609690: Debian x86 32-bits built for i586 !?

2011-05-17 Thread Matthias Klose

On 05/16/2011 04:36 AM, Henrique de Moraes Holschuh wrote:

On Mon, 16 May 2011, Ben Hutchings wrote:

I think any claim that Debian supports 486-class processors is more of
an aspiration.  What maintainer has the time to test on such antiques
regularly?


Well, nobody is running regular kernel regression testing on 486-class
hardware AFAIK, and that includes the kernel upstream.  I'd doubt even i586
is getting any serious testing...

So yes, it will break every so often, and the situation is not going to get
any better.


Note that some software is only built for i586 and newer processors, like 
OpenJDK in both lenny and squeeze, but apparently not used/tested on 486-class 
systems.



--
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/4dd23bcc.9090...@debian.org



Re: Bug#609690: Debian x86 32-bits built for i586 !?

2011-05-17 Thread Matthias Klose

On 05/15/2011 04:39 PM, Henrique de Moraes Holschuh wrote:

On Sun, 15 May 2011, Ben Hutchings wrote:

On Sun, 2011-05-15 at 09:28 -0300, Henrique de Moraes Holschuh wrote:

On Sun, 15 May 2011, Mike Hommey wrote:

I just found out that gcc is compiled with --with-arch-32=i586, which
effectively means it builds with -march=i586 by default (and that it
still claims an i486-linux-gnu target).

I'm wondering. Is the project at large aware that we're not building for
i486, but for i586 ? That even the maintainer doesn't know why for


No.  And unless we got a bug report form an i486 user, our users
probably didn't notice it either.

What are the *exact* differences between code generated for march=i486
to code generated for march=i586?  What CPUs would break?

[...]

There are a few new instructions on the Pentium that can be used in ring
3: cmpxchg8 and rdtsc.  Linux has separate options for '586' and '586
with TSC', both of which result in -m586, so gcc does not appear to
assume the existence of rdtsc.  I would not expect gcc to generate
cmpxchg8 except through an intrinsic, but I could be wrong.


Assuming we can't just do away with i486 support for now, did anyone track
down exactly what was causing breakages that forced the change from
march=486 to march=586?


libgomp assumes 586; there were some GFortran/OMP issues on i386.


--
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/4dd23a92.1090...@debian.org



Re: Debian x86 32-bits built for i586 !?

2011-05-16 Thread Ben Hutchings
On Mon, May 16, 2011 at 04:34:10PM +0200, Joachim Wiedorn wrote:
> Drake Wilson  wrote on 2011-05-15 18:57:
> 
> > FWIW, I'm using Debian on a Soekris box with an AMD Geode.  ISTR being
> 
> > | model name  : Geode(TM) Integrated Processor by National Semi
> 
> 
> For clarification. There were some different Geode CPUs on the market:
>
> CPUs of the old company National Semiconductor (NS):
>   GX1; GX2 (with 3DNow!); GXLV  
>   (for the first time in year 2000 / 2001)
> 
> CPUs of the new company AMD:
>   GX (similar to NS GX2); LX (better GX); NX (similar to Athlon XP)
>   (for the first time in year 2003 / 2004)
> 
> My CPU "AMD Geode LX" already run with i686 kernel:
[...]

However, a 486 kernel will probably be faster and will be the only
option from 2.6.39 onward, as this processor doesn't support PAE.
 
Ben.

-- 
Ben Hutchings
We get into the habit of living before acquiring the habit of thinking.
  - Albert Camus


-- 
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20110516153902.ga29...@decadent.org.uk



Re: Debian x86 32-bits built for i586 !?

2011-05-16 Thread Joachim Wiedorn
Drake Wilson  wrote on 2011-05-15 18:57:

> FWIW, I'm using Debian on a Soekris box with an AMD Geode.  ISTR being

> | model name  : Geode(TM) Integrated Processor by National Semi


For clarification. There were some different Geode CPUs on the market:

CPUs of the old company National Semiconductor (NS):
  GX1; GX2 (with 3DNow!); GXLV  
  (for the first time in year 2000 / 2001)

CPUs of the new company AMD:
  GX (similar to NS GX2); LX (better GX); NX (similar to Athlon XP)
  (for the first time in year 2003 / 2004)

My CPU "AMD Geode LX" already run with i686 kernel:

processor   : 0
vendor_id   : AuthenticAMD
cpu family  : 5
model   : 10
model name  : Geode(TM) Integrated Processor by AMD PCS
stepping: 2
cpu MHz : 498.078
cache size  : 128 KB
fpu : yes
fpu_exception   : yes
cpuid level : 1
wp  : yes
flags   : fpu de pse tsc msr cx8 sep pge cmov clflush mmx
  mmxext 3dnowext 3dnow up 
bogomips: 996.15
clflush size: 32
cache_alignment : 32
address sizes   : 32 bits physical, 32 bits virtual
power management:


---
Have a nice day.

Joachim (Germany)


-- 
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20110516163410.06b7d...@jupiter.home



Re: Debian x86 32-bits built for i586 !?

2011-05-15 Thread Henrique de Moraes Holschuh
On Mon, 16 May 2011, Ben Hutchings wrote:
> I think any claim that Debian supports 486-class processors is more of
> an aspiration.  What maintainer has the time to test on such antiques
> regularly?

Well, nobody is running regular kernel regression testing on 486-class
hardware AFAIK, and that includes the kernel upstream.  I'd doubt even i586
is getting any serious testing...

So yes, it will break every so often, and the situation is not going to get
any better.

-- 
  "One disk to rule them all, One disk to find them. One disk to bring
  them all and in the darkness grind them. In the Land of Redmond
  where the shadows lie." -- The Silicon Valley Tarot
  Henrique Holschuh


-- 
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20110516023637.gb9...@khazad-dum.debian.net



Re: Debian x86 32-bits built for i586 !?

2011-05-15 Thread Drake Wilson
Quoth Ben Hutchings , on 2011-05-15 14:36:03 +0100:
> There are a few new instructions on the Pentium that can be used in ring
> 3: cmpxchg8 and rdtsc.  Linux has separate options for '586' and '586
> with TSC', both of which result in -m586, so gcc does not appear to
> assume the existence of rdtsc.  I would not expect gcc to generate
> cmpxchg8 except through an intrinsic, but I could be wrong.

FWIW, I'm using Debian on a Soekris box with an AMD Geode.  ISTR being
told in the past that this is a 486-class machine, but /proc/cpuinfo
reports (with some lines elided):

| processor   : 0
| vendor_id   : Geode by NSC
| cpu family  : 5
| model   : 4
| model name  : Geode(TM) Integrated Processor by National Semi
| stepping: 0
| cpu MHz : 266.571
| cpuid level : 2
| wp  : yes
| flags   : fpu tsc msr cx8 cmov mmx
| clflush size: 32

So it does have TSC, CMPXCHG8, and CMOV support.  I'm not sure where
that places it exactly on the ix86 processor chart; supposedly those
are the main architectural differences that can actually break things
compiled for i586?

   ---> Drake Wilson


-- 
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20110516015702.ga11...@drache.begriffli.ch



Re: Debian x86 32-bits built for i586 !?

2011-05-15 Thread Russ Allbery
Ben Hutchings  writes:

> I think any claim that Debian supports 486-class processors is more of
> an aspiration.  What maintainer has the time to test on such antiques
> regularly?

Yes, this isn't something that we're going to be able to really do without
automated tools that would detect problematic binaries.  Without that, the
most that I suspect people will be able to do is fix problems that happen
to be stumbled upon by i486 users.

-- 
Russ Allbery (r...@debian.org)   


-- 
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/87boz3l942@windlord.stanford.edu



Re: Debian x86 32-bits built for i586 !?

2011-05-15 Thread Ben Hutchings
On Sun, 2011-05-15 at 21:48 +0200, Raphael Hertzog wrote:
> On Sun, 15 May 2011, Henrique de Moraes Holschuh wrote:
> > On Sun, 15 May 2011, Mike Hommey wrote:
> > > I'm wondering. Is the project at large aware that we're not building for
> > > i486, but for i586 ? That even the maintainer doesn't know why for
> > 
> > No.  And unless we got a bug report form an i486 user, our users
> > probably didn't notice it either.
> 
> I used Debian on some embedded computers based on this processor:
> http://www.vortex86sx.com
> 
> cat /proc/cpuinfo reports "486"
> 
> But I have not tried Squeeze yet. So it's possible that other users have
> not found the problem yet.

The kernel in 'lenny' was broken on 486 for 6 months after release
(#515982).

I think any claim that Debian supports 486-class processors is more of
an aspiration.  What maintainer has the time to test on such antiques
regularly?

Ben.

-- 
Ben Hutchings
Once a job is fouled up, anything done to improve it makes it worse.


signature.asc
Description: This is a digitally signed message part


Re: Debian x86 32-bits built for i586 !?

2011-05-15 Thread David Goodenough
On Sunday 15 May 2011, Raphael Hertzog wrote:
> On Sun, 15 May 2011, Henrique de Moraes Holschuh wrote:
> > On Sun, 15 May 2011, Mike Hommey wrote:
> > > I'm wondering. Is the project at large aware that we're not building
> > > for i486, but for i586 ? That even the maintainer doesn't know why for
> > 
> > No.  And unless we got a bug report form an i486 user, our users
> > probably didn't notice it either.
> 
> I used Debian on some embedded computers based on this processor:
> http://www.vortex86sx.com
> 
> cat /proc/cpuinfo reports "486"
> 
> But I have not tried Squeeze yet. So it's possible that other users have
> not found the problem yet.
> 
> Cheers,
I also run Debian on embedded computers mainly running SC1100 CPUs and
/proc/cpuinfo reports:-

processor   : 0
vendor_id   : AuthenticAMD
cpu family  : 4
model   : 9
model name  : 486 DX/4-WB
stepping: 4

The kit may be over 8 years old, but it runs just fine and has been running
Debian stock kernels all its life.  I would like to keep it that way.

David


-- 
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: 
http://lists.debian.org/201105152245.43104.david.goodeno...@btconnect.com



Re: Debian x86 32-bits built for i586 !?

2011-05-15 Thread Raphael Hertzog
On Sun, 15 May 2011, Henrique de Moraes Holschuh wrote:
> On Sun, 15 May 2011, Mike Hommey wrote:
> > I'm wondering. Is the project at large aware that we're not building for
> > i486, but for i586 ? That even the maintainer doesn't know why for
> 
> No.  And unless we got a bug report form an i486 user, our users
> probably didn't notice it either.

I used Debian on some embedded computers based on this processor:
http://www.vortex86sx.com

cat /proc/cpuinfo reports "486"

But I have not tried Squeeze yet. So it's possible that other users have
not found the problem yet.

Cheers,
-- 
Raphaël Hertzog ◈ Debian Developer

Follow my Debian News ▶ http://RaphaelHertzog.com (English)
  ▶ http://RaphaelHertzog.fr (Français)


-- 
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20110515194842.gc32...@rivendell.home.ouaza.com



Re: Debian x86 32-bits built for i586 !?

2011-05-15 Thread Julien Cristau
On Sun, May 15, 2011 at 14:08:00 +0200, Mike Hommey wrote:

> I'm wondering. Is the project at large aware that we're not building for
> i486, but for i586 ? That even the maintainer doesn't know why for
> sure[1] and that no changelog entry documents when or why that happened?
> (nothing in debian/changelog, and the corresponding svn commit says
> "Update to SVN 20100625 (r161383) from the gcc-4_5-branch.")
> And that as far as I can see, this hasn't been discussed or documented
> in the released notes?
> 
To the best of my knowledge neither the release managers nor the release
notes editors for squeeze were notified of this change.

Cheers,
Julien


-- 
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20110515190558.gy2...@radis.liafa.jussieu.fr



Re: Debian x86 32-bits built for i586 !?

2011-05-15 Thread brian m. carlson
On Sun, May 15, 2011 at 09:28:05AM -0300, Henrique de Moraes Holschuh wrote:
> What are the *exact* differences between code generated for march=i486
> to code generated for march=i586?  What CPUs would break?

With -march=i586, code will be generated that runs on a Pentium without
MMX (or later chips) instead of code that runs on any i486 or better.
The extra instructions are CMPXCHG8B, CPUID, RDMSR, WRMSR, RDTSC, and
MOV (when it's used with a control register)[0].  AIUI, some IDT
Winchips do not support these instructions either.

With -march=i486, the code will work on any 32-bit or 64-bit x86
processor other than the i386 itself.  We originally switched to
generating code for the i486 because it was needed for certain C++
support in GCC and libstdc++, although that is no longer the case, IIRC.

The -march use, which specifies which instructions may be generated, is
different from -mtune, which specifies for which processor the
instructions are scheduled.  -mtune has been set to i686 (since most
32-bit processors these days are i686) and tuning for the i586 is a bad
idea since it was designed for executing 16-bit code efficiently, not
32-bit code.  I believe the -mtune value should remain i686.

[0] http://www.singlix.com/trdos/pentium.txt

-- 
brian m. carlson / brian with sandals: Houston, Texas, US
+1 832 623 2791 | http://www.crustytoothpaste.net/~bmc | My opinion only
OpenPGP: RSA v4 4096b: 88AC E9B2 9196 305B A994 7552 F1BA 225C 0223 B187


signature.asc
Description: Digital signature


Re: Debian x86 32-bits built for i586 !?

2011-05-15 Thread Henrique de Moraes Holschuh
On Sun, 15 May 2011, Ben Hutchings wrote:
> On Sun, 2011-05-15 at 09:28 -0300, Henrique de Moraes Holschuh wrote:
> > On Sun, 15 May 2011, Mike Hommey wrote:
> > > I just found out that gcc is compiled with --with-arch-32=i586, which
> > > effectively means it builds with -march=i586 by default (and that it
> > > still claims an i486-linux-gnu target).
> > > 
> > > I'm wondering. Is the project at large aware that we're not building for
> > > i486, but for i586 ? That even the maintainer doesn't know why for
> > 
> > No.  And unless we got a bug report form an i486 user, our users
> > probably didn't notice it either.
> > 
> > What are the *exact* differences between code generated for march=i486
> > to code generated for march=i586?  What CPUs would break?
> [...]
> 
> There are a few new instructions on the Pentium that can be used in ring
> 3: cmpxchg8 and rdtsc.  Linux has separate options for '586' and '586
> with TSC', both of which result in -m586, so gcc does not appear to
> assume the existence of rdtsc.  I would not expect gcc to generate
> cmpxchg8 except through an intrinsic, but I could be wrong.

Assuming we can't just do away with i486 support for now, did anyone track
down exactly what was causing breakages that forced the change from
march=486 to march=586?

-- 
  "One disk to rule them all, One disk to find them. One disk to bring
  them all and in the darkness grind them. In the Land of Redmond
  where the shadows lie." -- The Silicon Valley Tarot
  Henrique Holschuh


-- 
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20110515143922.gb11...@khazad-dum.debian.net



Re: Debian x86 32-bits built for i586 !?

2011-05-15 Thread Ben Hutchings
On Sun, 2011-05-15 at 09:28 -0300, Henrique de Moraes Holschuh wrote:
> On Sun, 15 May 2011, Mike Hommey wrote:
> > I just found out that gcc is compiled with --with-arch-32=i586, which
> > effectively means it builds with -march=i586 by default (and that it
> > still claims an i486-linux-gnu target).
> > 
> > I'm wondering. Is the project at large aware that we're not building for
> > i486, but for i586 ? That even the maintainer doesn't know why for
> 
> No.  And unless we got a bug report form an i486 user, our users
> probably didn't notice it either.
> 
> What are the *exact* differences between code generated for march=i486
> to code generated for march=i586?  What CPUs would break?
[...]

There are a few new instructions on the Pentium that can be used in ring
3: cmpxchg8 and rdtsc.  Linux has separate options for '586' and '586
with TSC', both of which result in -m586, so gcc does not appear to
assume the existence of rdtsc.  I would not expect gcc to generate
cmpxchg8 except through an intrinsic, but I could be wrong.

Ben.

-- 
Ben Hutchings
Once a job is fouled up, anything done to improve it makes it worse.


signature.asc
Description: This is a digitally signed message part


Re: Debian x86 32-bits built for i586 !?

2011-05-15 Thread Henrique de Moraes Holschuh
On Sun, 15 May 2011, Mike Hommey wrote:
> I just found out that gcc is compiled with --with-arch-32=i586, which
> effectively means it builds with -march=i586 by default (and that it
> still claims an i486-linux-gnu target).
> 
> I'm wondering. Is the project at large aware that we're not building for
> i486, but for i586 ? That even the maintainer doesn't know why for

No.  And unless we got a bug report form an i486 user, our users
probably didn't notice it either.

What are the *exact* differences between code generated for march=i486
to code generated for march=i586?  What CPUs would break?

> > >I believe, that even plain i486 have to be supported,
> > >also changelog claims that default should still be i486.
> > 
> > yes, I think I did change that to avoid libgomp failures, which
> > requires i586, and not just i486.  Not sure what to do about that
> > for squeeze.
> > 
> >   $ apt-cache rdepends libgomp1 | wc -l
> >   77
> > 
> > So all these packages would need setting of the -march flag explicitly.
> > 
> > There are other packages which do require i586, like OpenJDK.

We may well consider switching the i386 port to i586.  But lets access
the real impact, first.  And whether we still have enough *active* i486
users (or i586-like CPUs that do not support gcc march=i586 if such a
thing could happen) to care.

-- 
  "One disk to rule them all, One disk to find them. One disk to bring
  them all and in the darkness grind them. In the Land of Redmond
  where the shadows lie." -- The Silicon Valley Tarot
  Henrique Holschuh


-- 
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20110515122805.gc32...@khazad-dum.debian.net



Debian x86 32-bits built for i586 !?

2011-05-15 Thread Mike Hommey
Hi,

I just found out that gcc is compiled with --with-arch-32=i586, which
effectively means it builds with -march=i586 by default (and that it
still claims an i486-linux-gnu target).

I'm wondering. Is the project at large aware that we're not building for
i486, but for i586 ? That even the maintainer doesn't know why for
sure[1] and that no changelog entry documents when or why that happened?
(nothing in debian/changelog, and the corresponding svn commit says
"Update to SVN 20100625 (r161383) from the gcc-4_5-branch.")
And that as far as I can see, this hasn't been discussed or documented
in the released notes?

Mike

1. See the following message from bug 609690:

On Tue, Jan 11, 2011 at 05:20:32PM +0100, Matthias Klose wrote:
> On 11.01.2011 16:38, Petr Salinger wrote:
> >Package: gcc-4.4
> >Version: 4.4.5-8
> >
> >Hi,
> >
> >the current gcc-4.4 uses (tested on i386/4.4.5-6 and kfreebsd-i386/4.4.5-8)
> >as a default arch i586.
> >COLLECT_GCC_OPTIONS='-v' '-dD' '-E' '-mtune=generic' '-march=i586'
> >
> >echo "" | gcc-4.4 -dD -x c -E - | grep 86
> >
> >#define __DBL_MAX__ 1.7976931348623157e+308
> >#define __i386 1
> >#define __i386__ 1
> >#define i386 1
> >#define __i586 1
> >#define __i586__ 1
> >
> >It is due to debian/rules2:
> >
> >ifneq (,$(filter $(DEB_TARGET_ARCH), amd64 i386 kfreebsd-i386 
> >kfreebsd-amd64))
> >#CONFARGS += --with-arch-32=i486
> >ifeq ($(distribution),Ubuntu)
> >CONFARGS += --with-arch-32=i686
> >else
> >CONFARGS += --with-arch-32=i586
> >endif
> >endif
> >
> >
> >I believe, that even plain i486 have to be supported,
> >also changelog claims that default should still be i486.
> 
> yes, I think I did change that to avoid libgomp failures, which
> requires i586, and not just i486.  Not sure what to do about that
> for squeeze.
> 
>   $ apt-cache rdepends libgomp1 | wc -l
>   77
> 
> So all these packages would need setting of the -march flag explicitly.
> 
> There are other packages which do require i586, like OpenJDK.
> 
> 
> 


-- 
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20110515120800.ga10...@glandium.org