Hi!

----

32bit ast-ksh.2009-05-05 _may_ crash on Solaris 11 SPARC+x86 when
running fftw-2.1.5 "configure". The problem is a bit difficult to
reproduce since it only occurs around ~30% of the "configure" runs, only
happens for 32bit binaries and only if "configure" exclusively uses
ksh93 (this happens on OpenSolaris/Indiana where
/sbin/sh+/bin/sh+/usr/bin/sh is ksh93).

Steps to reproduce:
1. Install _32bit_ ast-ksh.2009-05-05 as /home/test001/bin/ksh
$ wget
'http://src.opensolaris.org/source/raw/sfw/usr/src/lib/fftw2/fftw-2.1.5.tar.gz'
2. Run the following build sequence:
-- snip --
( gzcat <fftw-2.1.5.tar.gz | tar -xf - ; cd fftw-2.1.5 ; cat configure |
sed 's/\/bin\/sh/\/home\/test001\/bin\/ksh/g' >configure_mod ; (LC_ALL=C
SHELL=/home/test001/bin/ksh CONFIG_SHELL=/home/test001/bin/ksh VMDEBUG=a
/home/test001/bin/ksh configure_mod --no-reexec --prefix=/usr
--enable-threads --enable-shared --disable-static) 2>&1 | tee
buildlog.log)
-- snip --

"configure_mod" then crashes like this:
-- snip --
checking for a BSD-compatible install... /usr/bin/ginstall -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking type prefix for installed files... (none)
checking for vendor's cc to be used instead of gcc... checking for cc...
cc
checking for C compiler default output... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables... 
checking for suffix of object files... o
checking whether we are using the GNU C compiler... no
checking whether cc accepts -g... yes
checking for cc option to accept ANSI C... none needed
checking for style of include used by make... GNU
checking dependency style of cc... none
checking whether we are using gcc 2.90 or later... no
checking for a BSD-compatible install... /usr/bin/ginstall -c
checking whether make sets $(MAKE)... (cached) yes
checking for ranlib... ranlib
checking whether ln -s works... yes
checking build system type... sparc-sun-solaris2.11
checking host system type... sparc-sun-solaris2.11
checking for non-GNU ld... /usr/ccs/bin/ld
checking if the linker (/usr/ccs/bin/ld) is GNU ld... no
checking for /usr/ccs/bin/ld option to reload object files... -r
checking for BSD-compatible nm... /usr/ccs/bin/nm -p
checking for a sed that does not truncate output... /usr/bin/gsed
checking how to recognise dependent libraries... pass_all
checking command to parse /usr/ccs/bin/nm -p output... ok
checking how to run the C preprocessor... cc -E
checking for egrep... egrep
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking dlfcn.h usability... yes
checking dlfcn.h presence... yes
checking for dlfcn.h... yes
checking for ranlib... (cached) ranlib
checking for strip... strip
checking for objdir... .libs
checking for cc option to produce PIC... -KPIC
checking if cc PIC flag -KPIC works... yes
checking if cc static flag -Bstatic works... no
checking if cc supports -c -o file.o... yes
checking if cc supports -c -o file.lo... yes
checking whether the linker (/usr/ccs/bin/ld) supports shared
libraries... yes
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... no
checking dynamic linker characteristics... solaris2.11 ld.so
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... no
creating libtool
checking for perl... perl
checking for g77... g77
checking whether we are using the GNU Fortran 77 compiler... yes
checking whether g77 accepts -g... yes
checking how to get verbose linking output from g77... -v
checking for Fortran 77 libraries... -ksh93: 18425: Memory
fault(coredump)
-- snip --

Stack trace looks like this:
-- snip --
program terminated by signal SEGV (no mapping at the fault address)
0xff23f338: strlen+0x0018:      ldub     [%o2], %o1
Current function is varsub
 1697                                  
mac_copy(mp,v,vsize>0?vsize:strlen(v));
(dbx) where
  [1] strlen(0x29, 0x272770, 0x29, 0x80808000, 0x1, 0x80808080), at
0xff23f338 
=>[2] varsub(mp = 0x262810), line 1697 in "macro.c"
  [3] copyto(mp = 0x262810, endch = 0, newquote = 0), line 587 in
"macro.c"
  [4] sh_mactrim(shp = 0x24d3e4, str = 0x2ab229
"ac_save_positional="$@"", mode = -1), line 173 in "macro.c"
  [5] nv_setlist(arg = 0x2ab220, flags = 131584), line 324 in "name.c"
  [6] sh_exec(t = 0x2ab248, flags = 4), line 817 in "xec.c"
  [7] sh_exec(t = 0x2acf90, flags = 4), line 1539 in "xec.c"
  [8] sh_exec(t = 0x2aa590, flags = 4), line 1805 in "xec.c"
  [9] sh_exec(t = 0x2aa440, flags = 4), line 1805 in "xec.c"
  [10] sh_exec(t = 0x2afed0, flags = 4), line 1539 in "xec.c"
  [11] sh_exec(t = 0x268cf0, flags = 4), line 1803 in "xec.c"
  [12] exfile(shp = 0x24d3e4, iop = 0x2794c8, fno = 10), line 595 in
"main.c"
  [13] sh_main(ac = 7, av = 0xffbffb0c, userinit = (nil)), line 370 in
"main.c"
  [14] main(argc = 7, argv = 0xffbffb0c), line 46 in "pmain.c"
(dbx) print *mp
*mp = {
    shp      = 0x24d3e4
    sp       = (nil)
    arghead  = (nil)
    ifsp     = 0x26cd30 " ^I\n"
    fields   = 0
    quoted   = 1
    ifs      = ' '
    quote    = '\001'
    lit      = '\0'
    split    = '\0'
    pattern  = '\0'
    patfound = '\0'
    assign   = '\002'
    arith    = '\0'
    let      = '\0'
    zeros    = '\0'
    arrayok  = '\0'
    subcopy  = '\0'
    dotdot   = 0
    nvwalk   = (nil)
}
(dbx) print c, type, v, *v, argp, *argp, np, *np, dolg, mode, lp, *lp,
*ap, dolmax, vsize, offset, nulflg, replen, bysub, idbuff, id, pattern,
repstr, *repstr, arrmax, *arrmax, addsub, oldpat, idnum, flag, stkp,
*stkp
c = 0
type = 0
v = 0x29 "<bad address 0x29>"
dbx: cannot access address 0x29
argp = (nil)
dbx: reference through nil pointer
np = (nil)
dbx: reference through nil pointer
dolg = 2
mode = 64
lp = 0x2628c0
*lp = {
    sh          = 0x24d3e4
    arg         = (nil)
    heredoc     = (nil)
    token       = 2048
    lastline    = 8635
    lasttok     = 0
    digits      = 0
    aliasok     = '\0'
    assignok    = '\0'
    inexec      = '\0'
    intypeset   = '\0'
    comp_assign = '\0'
    comsub      = '\0'
    inlineno    = 8633
    firstline   = 0
    kiafile     = (nil)
    kiatmp      = (nil)
    script      = 0
    fscript     = 0
    current     = 0
    unknown     = 0
    kiabegin    = 0
    scriptname  = (nil)
    entity_tree = (nil)
}
dbx: reference through nil pointer
dolmax = 3
vsize = -1
offset = -1
nulflg = 0
replen = 0
bysub = 0
idbuff = "@"
id = 0xffbfe41d "@"
pattern = (nil)
repstr = 0x1 "<bad address 0x1>"
dbx: cannot access address 0x1
arrmax = (nil)
dbx: reference through nil pointer
addsub = 0
oldpat = 0
idnum = 0
flag = 0
stkp = 0x24e790
*stkp = {
    _next  = 0x2b01d4 "sr/bin/grep"
    _endw  = 0x2b09d8 "????????????"
    _endr  = 0x2b01c0 "ac_save_positional= sr/bin/grep"
    _endb  = 0x2b09d8 "????????????"
    _push  = 0x268c10
    _flags = 518U
    _file  = -1
    _data  = 0x2b01c0 "ac_save_positional= sr/bin/grep"
    _size  = 4080
    _val   = 4080
}
-- snip --

Glenn: Can you reproduce the problem on your side ?

----

Bye,
Roland

-- 
  __ .  . __
 (o.\ \/ /.o) [email protected]
  \__\/\/__/  MPEG specialist, C&&JAVA&&Sun&&Unix programmer
  /O /==\ O\  TEL +49 641 3992797
 (;O/ \/ \O;)
_______________________________________________
ast-users mailing list
[email protected]
https://mailman.research.att.com/mailman/listinfo/ast-users

Reply via email to