cvs commit: src/sys/i386/isa apic_vector.s clock.c src/sys/kern kern_intr.c kern_sig.c kern_slaballoc.c kern_switch.c kern_systimer.c kern_upcall.c lwkt_msgport.c lwkt_thread.c lwkt_token.c src/sys/sys slaballoc.h

YONETANI Tomokazu qhwt+dragonfly-bugs at les.ath.cx
Thu Feb 19 15:22:34 PST 2004


On Thu, Feb 19, 2004 at 11:44:05AM -0800, Matthew Dillon wrote:
> :> Interestingly enough, on my dfly test box, recent kernels built with gcc2
> :> along with CPUTYPE=i686 set in make.conf yield broken kernels almost
> :> identical to what you are describing. Removing CPUTYPE from make.conf yields
> :> working kernel with gcc2. Is this reproducible on your end ?
> :
> :Yes, that did it.
> 
>     Umm..  you guys realize that setting CPUTYPE will generate specific
>     instructions for that particular processor?  If you do not actually
>     have a pentium-pro cpu in your box, using CPUTYPE=i686 is likely to
>     produce instructions that your cpu does not support. 
> 
>     In particular, ppro optimizations will use the CMOV instruction.
>     Is 'CMOV' in the Features line near the top of your dmesg?   
> 
>     Post the first 25 lines of your dmesg output.

Sure.

Copyright (c) 2003-2004 The DragonFly Project.
Copyright (c) 1992-2003 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
	The Regents of the University of California. All rights reserved.
DragonFly 1.0-CURRENT #0: Thu Feb 19 00:32:39 JST 2004
    root at xxxxxxxxx:/usr/obj/home/source/dragonfly/src/sys/GZL:gcc3
CPU: Mobile Intel(R) Pentium(R) III CPU - M  1333MHz (849.87-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0x6b4  Stepping = 4
  Features=0x383f9ff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,MMX,FXSR,SSE>
real memory  = 251592704 (245696K bytes)
config> q
avail memory = 237109248 (231552K bytes)
Preloaded elf kernel "/kernel" at 0xc03bd000.
Preloaded userconfig_script "/boot/kernel.conf" at 0xc03bd288.
Preloaded elf module "/modules/splash_bmp.ko" at 0xc03bd2d8.
Preloaded elf module "/modules/vesa.ko" at 0xc03bd384.
Preloaded elf module "/modules/linux.ko" at 0xc03bd42c.
link_elf: symbol LINUX_SIGF_HANDLER undefined
Preloaded elf module "/modules/miibus.ko" at 0xc03bd4d4.
Preloaded elf module "/modules/if_fxp.ko" at 0xc03bd57c.
Preloaded elf module "/modules/snd_pcm.ko" at 0xc03bd624.
Preloaded elf module "/modules/snd_t4dwave.ko" at 0xc03bd6cc.
Preloaded elf module "/modules/usb.ko" at 0xc03bd778.
VESA: v2.0, 16384k memory, flags:0x0, mode table:0xc0331a20 (1000040)
VESA: Trident CYBER 8820

>     Also, what -O optimization level are you trying to compile things
>     under?  e.g. for example, -O2 or -O3 has historically been rather buggy
>     with GCC2.  Even so, I tried recompiling my kernel with
>     gcc2 -march=pentiumpro -O3 on an AMD64, and it seemed to work.

I do not specify -O flags for buildworld/buildkernel, but let Makefiles
choose correct ones. `make -V CFLAGS -V CXXFLAGS' at the top of the source
tree shows
-O -pipe -march=pentiumpro
 -O -pipe -march=pentiumpro

As already mentioned in another message, if I compile kern_slaballoc.c
without -march=pentiumpro(by specifying NO_CPU_COPT_FLAGS=yes) and the
kernel boots OK. I've put the assembly outputs at for those who are
interested:
  http://les.ath.cx/DragonFly/kern_slaballoc.c
  http://les.ath.cx/DragonFly/kern_slaballoc.c.ppro

Regards.





More information about the Bugs mailing list