Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
how about "CHOST=pentium4-pc-linux-gnu"?
View unanswered posts
View posts from last 24 hours

Goto page 1, 2, 3  Next  
Reply to topic    Gentoo Forums Forum Index Gentoo Chat
View previous topic :: View next topic  
Author Message
cnhnln
n00b
n00b


Joined: 20 Nov 2004
Posts: 11

PostPosted: Thu Sep 07, 2006 4:09 pm    Post subject: how about "CHOST=pentium4-pc-linux-gnu"? Reply with quote

when i recompile gcc with "CHOST=pentium4-pc-linux-gnu" . i get...
Code:

checking build system type... i786-pc-linux-gnu
checking host system type... i786-pc-linux-gnu
checking target system type... i786-pc-linux-gnu

Code:

localhost src # gcc -v
使用内建 specs。
目标:pentium4-pc-linux-gnu
配置为:/var/tmp/portage/gcc-4.1.1-r1/work/gcc-4.1.1/configure --prefix=/usr --bindir=/usr/pentium4-pc-linux-gnu/gcc-bin/4.1.1 --includedir=/usr/lib/gcc/pentium4-pc-linux-gnu/4.1.1/include --datadir=/usr/share/gcc-data/pentium4-pc-linux-gnu/4.1.1 --mandir=/usr/share/gcc-data/pentium4-pc-linux-gnu/4.1.1/man --infodir=/usr/share/gcc-data/pentium4-pc-linux-gnu/4.1.1/info --with-gxx-include-dir=/usr/lib/gcc/pentium4-pc-linux-gnu/4.1.1/include/g++-v4 --host=pentium4-pc-linux-gnu --build=pentium4-pc-linux-gnu --disable-altivec --enable-nls --without-included-gettext --with-system-zlib --disable-checking --disable-werror --disable-libunwind-exceptions --disable-multilib --disable-libmudflap --disable-libssp --disable-libgcj --enable-languages=c,c++,fortran --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu
线程模型:posix
gcc 版本 4.1.1 (Gentoo 4.1.1-r1)
localhost src #

Code:

localhost src # pe
pentium4-pc-linux-gnu-c++             pentium4-pc-linux-gnu-gfortran
pentium4-pc-linux-gnu-c++-4.1.1       pentium4-pc-linux-gnu-gfortran-4.1.1
pentium4-pc-linux-gnu-cpp             pentium4-pc-linux-gnu-protoize
pentium4-pc-linux-gnu-cpp-4.1.1       pentium4-pc-linux-gnu-unprotoize
pentium4-pc-linux-gnu-g++             perl
pentium4-pc-linux-gnu-g++32           perl5.8.8
pentium4-pc-linux-gnu-g++-4.1.1       perlbug
pentium4-pc-linux-gnu-gcc             perlcc
pentium4-pc-linux-gnu-gcc32           perl-cleaner
pentium4-pc-linux-gnu-gcc-4.1.1       perldoc
pentium4-pc-linux-gnu-gccbug          perlivp
pentium4-pc-linux-gnu-gcov
localhost src #

who know and talk this?
thanks


Last edited by cnhnln on Thu Sep 07, 2006 4:37 pm; edited 3 times in total
Back to top
View user's profile Send private message
ciaranm
Retired Dev
Retired Dev


Joined: 19 Jul 2003
Posts: 1719
Location: In Hiding

PostPosted: Thu Sep 07, 2006 4:26 pm    Post subject: Reply with quote

Uh... Don't do that. You can't stick arbitrary values in CHOST and expect it to work.
Back to top
View user's profile Send private message
Dominique_71
Veteran
Veteran


Joined: 17 Aug 2005
Posts: 1589
Location: Switzerland (Romandie)

PostPosted: Thu Sep 07, 2006 4:30 pm    Post subject: Reply with quote

Please read this: Configuring the Compile Options
CHOST=i786-pc-linux-gnu doesn't exist. Use CHOST=i686-pc-linux-gnu and it will solve your problem.

And use safe CFLAGS and CXXFLAGS.
If not absolutely sure, change only the march=<your processor> and you will be just fine.
-fomit-frame-pointer is safe, it will speed the system a little, but does at debugging is impossible. -pipe and -O2 are safe.
All the other CFLAGS can cause some kind of troubles. That because the gentoo programmers use -pipe -O2, and all the other combinations are not tested.
_________________
[[[ To any NSA and FBI agents reading that text: please consider ]]]
[[[ whether defending the US Constitution against all enemies, ]]]
[[[ foreign or domestic, requires you to follow Snowden's example. ]]]
Back to top
View user's profile Send private message
Archangel1
Veteran
Veteran


Joined: 21 Apr 2004
Posts: 1212
Location: Work

PostPosted: Thu Sep 07, 2006 10:51 pm    Post subject: Reply with quote

Wow, you've discovered the previously unknown 786 architecture - this must be a conspiracy by Intel and GCC to keep us from getting more optimisation for our systems!!1!!one
:roll:
_________________
What are you, stupid?
Back to top
View user's profile Send private message
Chaosite
Guru
Guru


Joined: 13 Dec 2003
Posts: 540
Location: Right over here.

PostPosted: Thu Sep 07, 2006 11:08 pm    Post subject: Reply with quote

...

this made me say "WTF!?" out loud.

definitely another one for funroll-loops.org.
Back to top
View user's profile Send private message
jiangtao
Tux's lil' helper
Tux's lil' helper


Joined: 16 Mar 2004
Posts: 75

PostPosted: Sat Sep 09, 2006 10:45 am    Post subject: Reply with quote

I am using CHOST="pentium4-pc-linux-gnu" && remerged gcc .....
I use it (CHOST="pentium4-pc-linux-gnu") to emerge firefox 1.5.0.6 & audacious & It seem working fine ......

But , XGL + compiz-quinnstorm can't work for me ....
No window decorations..............

gcc or compiz's bug ?
Back to top
View user's profile Send private message
monkey89
Guru
Guru


Joined: 08 Mar 2004
Posts: 596

PostPosted: Sat Sep 09, 2006 11:37 am    Post subject: Reply with quote

pentium4 is nonsense... but actually, from what I can tell, i786 may actually be a valid CHOST. Has anyone checked this out at all? Not that the optimization would probably make any difference, but it is something I've never heard of before. Wikipedia says it refers to chips based on the NetBurst architecture (P4s since 2000).
Back to top
View user's profile Send private message
Dominique_71
Veteran
Veteran


Joined: 17 Aug 2005
Posts: 1589
Location: Switzerland (Romandie)

PostPosted: Sat Sep 09, 2006 12:35 pm    Post subject: Reply with quote

Wikipedia is not gentoo official documentation.

If you want a working system, you must use a valid CHOST and use the -march CLFAG to tell gcc for which processor you want the optimisation.
_________________
[[[ To any NSA and FBI agents reading that text: please consider ]]]
[[[ whether defending the US Constitution against all enemies, ]]]
[[[ foreign or domestic, requires you to follow Snowden's example. ]]]
Back to top
View user's profile Send private message
cnhnln
n00b
n00b


Joined: 20 Nov 2004
Posts: 11

PostPosted: Sat Sep 09, 2006 12:37 pm    Post subject: Reply with quote

where can i found CHOST define?gcc.gnu.org or other page?
Back to top
View user's profile Send private message
Dominique_71
Veteran
Veteran


Joined: 17 Aug 2005
Posts: 1589
Location: Switzerland (Romandie)

PostPosted: Sat Sep 09, 2006 1:05 pm    Post subject: Reply with quote

jiangtao wrote:
I am using CHOST="pentium4-pc-linux-gnu" && remerged gcc .....
I use it (CHOST="pentium4-pc-linux-gnu") to emerge firefox 1.5.0.6 & audacious & It seem working fine ......

But , XGL + compiz-quinnstorm can't work for me ....
No window decorations..............

gcc or compiz's bug ?


The problem is between the chair and the keyboard in this case. One more time, read Configuring the Compile Options
Quote:
The CHOST variable declares the target build host for your system. This variable should already be set to the correct value. Do not edit it as that might break your system. If the CHOST variable does not look correct to you, you might be using the wrong stage3 tarball.

_________________
[[[ To any NSA and FBI agents reading that text: please consider ]]]
[[[ whether defending the US Constitution against all enemies, ]]]
[[[ foreign or domestic, requires you to follow Snowden's example. ]]]
Back to top
View user's profile Send private message
Dominique_71
Veteran
Veteran


Joined: 17 Aug 2005
Posts: 1589
Location: Switzerland (Romandie)

PostPosted: Sat Sep 09, 2006 1:08 pm    Post subject: Reply with quote

cnhnln wrote:
where can i found CHOST define?gcc.gnu.org or other page?

With x86 architecture, it is i686-pc-linux-gnu for all modern x86 processors.
_________________
[[[ To any NSA and FBI agents reading that text: please consider ]]]
[[[ whether defending the US Constitution against all enemies, ]]]
[[[ foreign or domestic, requires you to follow Snowden's example. ]]]
Back to top
View user's profile Send private message
Dominique_71
Veteran
Veteran


Joined: 17 Aug 2005
Posts: 1589
Location: Switzerland (Romandie)

PostPosted: Sat Sep 09, 2006 1:16 pm    Post subject: Reply with quote

And as I daid before, use safe CFLAGS. It is not because at a program compile that it will work as expected. Many Cflags can do worng code without even a warning. All depend of the combination of the code and the Cflags. The CFLAGS in the manual are safe, and well tested, all the other can or not work depending on which program you compile with. Generally, for the programs that need special Cflags, the ebuild and/or the sources of the program take care of it.
_________________
[[[ To any NSA and FBI agents reading that text: please consider ]]]
[[[ whether defending the US Constitution against all enemies, ]]]
[[[ foreign or domestic, requires you to follow Snowden's example. ]]]
Back to top
View user's profile Send private message
jiangtao
Tux's lil' helper
Tux's lil' helper


Joined: 16 Mar 2004
Posts: 75

PostPosted: Sat Sep 09, 2006 1:29 pm    Post subject: Reply with quote

:?

It is working now .
Why not use it?

As your idea, i386 + -O0 is enough.
:roll:
Back to top
View user's profile Send private message
ciaranm
Retired Dev
Retired Dev


Joined: 19 Jul 2003
Posts: 1719
Location: In Hiding

PostPosted: Sat Sep 09, 2006 1:57 pm    Post subject: Reply with quote

jiangtao wrote:
:?

It is working now .
Why not use it?

Congratulations, your system will break next time you update certain packages, and there's absolutely nothing you can do to fix it.
Back to top
View user's profile Send private message
jiangtao
Tux's lil' helper
Tux's lil' helper


Joined: 16 Mar 2004
Posts: 75

PostPosted: Sat Sep 09, 2006 2:21 pm    Post subject: Reply with quote

ciaranm wrote:
jiangtao wrote:
:?

It is working now .
Why not use it?

Congratulations, your system will break next time you update certain packages, and there's absolutely nothing you can do to fix it.

I can use an other Linux suite to rebuild gcc.
:wink:
Back to top
View user's profile Send private message
ciaranm
Retired Dev
Retired Dev


Joined: 19 Jul 2003
Posts: 1719
Location: In Hiding

PostPosted: Sat Sep 09, 2006 2:29 pm    Post subject: Reply with quote

jiangtao wrote:
ciaranm wrote:
jiangtao wrote:
:?

It is working now .
Why not use it?

Congratulations, your system will break next time you update certain packages, and there's absolutely nothing you can do to fix it.

I can use an other Linux suite to rebuild gcc.
:wink:

And just how do you plan to fix gcc-config and binutils-config?
Back to top
View user's profile Send private message
monkey89
Guru
Guru


Joined: 08 Mar 2004
Posts: 596

PostPosted: Sat Sep 09, 2006 10:13 pm    Post subject: Reply with quote

Dominique_71 wrote:
Wikipedia is not gentoo official documentation.

If you want a working system, you must use a valid CHOST and use the -march CLFAG to tell gcc for which processor you want the optimisation.


Again, I'm perfectly happy with i686. I'm wondering if i786 actually is a valid CHOST - so to do further investigation I looked at the gcc source code. In gcc-4.1.1/config.sub, there is the following code:

Code:

        pentiumpro | p6 | 6x86 | athlon | athlon_*)
                basic_machine=i686-pc
                ;;
        pentiumii | pentium2 | pentiumiii | pentium3)
                basic_machine=i686-pc
                ;;
        pentium4)
                basic_machine=i786-pc
                ;;
        pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*)
                basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'`
                ;;
        pentiumpro-* | p6-* | 6x86-* | athlon-*)
                basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
                ;;
        pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*)
                basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
                ;;
        pentium4-*)
                basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'`
                ;;


I know extremely little about the gcc source code, but looking at the behavior of his build, it would lead me to believe that i786 is recognized as something. Whether or not that something is the exact same as i686 or if its actually different is a question I can't really answer without looking a bit more into it.
Back to top
View user's profile Send private message
ciaranm
Retired Dev
Retired Dev


Joined: 19 Jul 2003
Posts: 1719
Location: In Hiding

PostPosted: Sat Sep 09, 2006 10:26 pm    Post subject: Reply with quote

monkey89 wrote:
Dominique_71 wrote:
Wikipedia is not gentoo official documentation.

If you want a working system, you must use a valid CHOST and use the -march CLFAG to tell gcc for which processor you want the optimisation.


Again, I'm perfectly happy with i686. I'm wondering if i786 actually is a valid CHOST - so to do further investigation I looked at the gcc source code. In gcc-4.1.1/config.sub, there is the following code:

Not a gcc issue. You should be looking at binutils and glibc.
Back to top
View user's profile Send private message
jiangtao
Tux's lil' helper
Tux's lil' helper


Joined: 16 Mar 2004
Posts: 75

PostPosted: Sun Sep 10, 2006 3:11 am    Post subject: Reply with quote

ciaranm wrote:
jiangtao wrote:
ciaranm wrote:
jiangtao wrote:
:?

It is working now .
Why not use it?

Congratulations, your system will break next time you update certain packages, and there's absolutely nothing you can do to fix it.

I can use an other Linux suite to rebuild gcc.
:wink:

And just how do you plan to fix gcc-config and binutils-config?

Before validate It's working fine, I will not recompile the base-packages.
So,I can chroot to Gentoo, and re-emerge gcc.
If gcc doesn't work, I can follow : http://gentoo-wiki.com/HOWTO_Recover_from_%22emerge_--unmerge_gcc%22
:wink:
Back to top
View user's profile Send private message
jiangtao
Tux's lil' helper
Tux's lil' helper


Joined: 16 Mar 2004
Posts: 75

PostPosted: Wed Sep 13, 2006 9:24 am    Post subject: Reply with quote

glibs's ebuild-file not support "pentium4-linux-pc-gnu" ,but "i786-linux-pc-gnu"...............
:?
Back to top
View user's profile Send private message
jiangtao
Tux's lil' helper
Tux's lil' helper


Joined: 16 Mar 2004
Posts: 75

PostPosted: Wed Sep 13, 2006 10:38 am    Post subject: Reply with quote

glibc can't be built ......

error......
:cry: :cry: :cry:
Back to top
View user's profile Send private message
ciaranm
Retired Dev
Retired Dev


Joined: 19 Jul 2003
Posts: 1719
Location: In Hiding

PostPosted: Wed Sep 13, 2006 12:13 pm    Post subject: Reply with quote

I told you so.
Back to top
View user's profile Send private message
jiangtao
Tux's lil' helper
Tux's lil' helper


Joined: 16 Mar 2004
Posts: 75

PostPosted: Thu Sep 14, 2006 11:40 am    Post subject: Reply with quote

:(
any idea ?
Back to top
View user's profile Send private message
Dominique_71
Veteran
Veteran


Joined: 17 Aug 2005
Posts: 1589
Location: Switzerland (Romandie)

PostPosted: Thu Sep 14, 2006 12:59 pm    Post subject: Reply with quote

jiangtao wrote:
:(
any idea ?

Reinstall a stage 3, don't modify the CHOST setting, set march according to your processor and use safe CFLAGS. :D
_________________
[[[ To any NSA and FBI agents reading that text: please consider ]]]
[[[ whether defending the US Constitution against all enemies, ]]]
[[[ foreign or domestic, requires you to follow Snowden's example. ]]]
Back to top
View user's profile Send private message
jiangtao
Tux's lil' helper
Tux's lil' helper


Joined: 16 Mar 2004
Posts: 75

PostPosted: Thu Sep 14, 2006 1:28 pm    Post subject: Reply with quote

The error:
Code:
gcc cleanup_compat.c -c -std=gnu99 -O2 -Wall -Winline -Wwrite-strings -fmerge-all-constants -march=pentium4 -mtune=pentium4 -pipe -Wstrict-prototypes -mpreferred-stack-boundary=2 -g    -I../include -I/var/tmp/portage/glibc-2.4-r3/work/build-default-i786-pc-linux-gnu-nptl/nptl -I/var/tmp/portage/glibc-2.4-r3/work/build-default-i786-pc-linux-gnu-nptl -I../sysdeps/i386/elf -I../nptl/sysdeps/unix/sysv/linux/i386 -I../sysdeps/unix/sysv/linux/i386 -I../ports/sysdeps/unix/sysv/linux -I../nptl/sysdeps/unix/sysv/linux -I../nptl/sysdeps/pthread -I../sysdeps/pthread -I../sysdeps/unix/sysv/linux -I../sysdeps/gnu -I../sysdeps/unix/common -I../sysdeps/unix/mman -I../sysdeps/unix/inet -I../ports/sysdeps/unix/sysv/i386 -I../sysdeps/unix/sysv/i386 -I../ports/sysdeps/unix/sysv -I../nptl/sysdeps/unix/sysv -I../sysdeps/unix/sysv -I../sysdeps/unix/i386 -I../ports/sysdeps/unix -I../nptl/sysdeps/unix -I../sysdeps/unix -I../sysdeps/posix -I../sysdeps/i386/i786 -I../sysdeps/i386/i686 -I../sysdeps/i386/i486 -I../nptl/sysdeps/i386/i486 -I../nptl/sysdeps/i386/i686 -I../sysdeps/i386/fpu -I../nptl/sysdeps/i386 -I../sysdeps/i386 -I../sysdeps/wordsize-32 -I../sysdeps/ieee754/ldbl-96 -I../sysdeps/ieee754/dbl-64 -I../sysdeps/ieee754/flt-32 -I../sysdeps/ieee754 -I../sysdeps/generic/elf -I../sysdeps/generic -I../ports -I../nptl  -I.. -I../libio -I. -nostdinc -isystem /usr/lib/gcc/pentium4-pc-linux-gnu/4.1.1/include -isystem /usr/include -D_LIBC_REENTRANT -include ../include/libc-symbols.h   -DNOT_IN_libc=1 -DIS_IN_libpthread=1    -o /var/tmp/portage/glibc-2.4-r3/work/build-default-i786-pc-linux-gnu-nptl/nptl/cleanup_compat.og -MD -MP -MF /var/tmp/portage/glibc-2.4-r3/work/build-default-i786-pc-linux-gnu-nptl/nptl/cleanup_compat.og.dt -MT /var/tmp/portage/glibc-2.4-r3/work/build-default-i786-pc-linux-gnu-nptl/nptl/cleanup_compat.og
../nptl/sysdeps/unix/sysv/linux/sem_post.c: In function '__new_sem_post':
../nptl/sysdeps/unix/sysv/linux/sem_post.c:34: warning: implicit declaration of function 'atomic_increment_val'
../nptl/sysdeps/unix/sysv/linux/sem_post.c:35: error: expected expression before 'do'
../nptl/sysdeps/unix/sysv/linux/sem_post.c:34: warning: unused variable 'nr'
make[2]: *** [/var/tmp/portage/glibc-2.4-r3/work/build-default-i786-pc-linux-gnu-nptl/nptl/sem_post.og] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory `/var/tmp/portage/glibc-2.4-r3/work/glibc-2.4/nptl'
make[1]: *** [nptl/subdir_lib] Error 2
make[1]: Leaving directory `/var/tmp/portage/glibc-2.4-r3/work/glibc-2.4'
make: *** [all] Error 2

!!! ERROR: sys-libs/glibc-2.4-r3 failed.
Call stack:
  ebuild.sh, line 1546:   Called dyn_compile
  ebuild.sh, line 937:   Called src_compile
  glibc-2.4-r3.ebuild, line 1179:   Called toolchain-glibc_src_compile
  glibc-2.4-r3.ebuild, line 253:   Called die

!!! make for default failed
!!! If you need support, post the topmost build error, and the call stack if relevant.

localhost ~ #


/var/tmp/portage/glibc-2.4-r3/work/glibc-2.4/nptl/sysdeps/unix/sysv/linux/sem_post.c:
Code:
#include <shlib-compat.h>

int
__new_sem_post (sem_t *sem)
{
  int *futex = (int *) sem;

  int nr = atomic_increment_val (futex);
  int err = lll_futex_wake (futex, nr); ///////////////////// 35 line
  if (__builtin_expect (err, 0) < 0)
    {
      __set_errno (-err);
      return -1;
    }
  return 0;
}

:?: :?: :?: :?: :?:
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo Chat All times are GMT
Goto page 1, 2, 3  Next
Page 1 of 3

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum