Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bus error on sparc #8143

Closed
vicuna opened this issue May 8, 2003 · 2 comments
Closed

bus error on sparc #8143

vicuna opened this issue May 8, 2003 · 2 comments
Labels

Comments

@vicuna
Copy link

vicuna commented May 8, 2003

Original bug ID: 1682
Reporter: administrator
Status: closed
Resolution: fixed
Priority: normal
Severity: minor
Category: ~DO NOT USE (was: OCaml general)

Bug description

Full_Name: Matthew Kennedy
Version: 3.06
OS: Gentoo GNU/Linux
Submission from: sl-opus-1-0.sprintlink.net (144.232.218.142)

Hi I ran into the folowing build error on a Gentoo GNU/Linux sparc platform.
The details are:

sys-libs/glibc-2.3.1-r4
sys-devel/binutils-2.13.90.0.18-r1
sys-devel/gcc-3.2.2-r2

Linux gentoo 2.4.20-sparc-r8 #5 SMP Mon Apr 28 23:13:45 CDT 2003 sparc64 sun4u
TI UltraSparc IIi GN

I'm happy to provide any further details you request.

Matt

BUILD ERROR (complete build log at
http://cvs.gentoo.org/~mkennedy/ocaml-3.06-build.log)

make[1]: Leaving directory `/home/mkennedy/ocaml-3.06/stdlib'
boot/ocamlrun boot/ocamlc -nostdlib -I boot -warn-error A -I utils -I parsing -I
typing -I bytecom -I asmcomp -I driver -I toplevel -c toplevel/genprintval.mli
boot/ocamlrun boot/ocamlc -nostdlib -I boot -warn-error A -I utils -I parsing -I
typing -I bytecom -I asmcomp -I driver -I toplevel -c toplevel/genprintval.ml
boot/ocamlrun boot/ocamlc -nostdlib -I boot -warn-error A -I utils -I parsing -I
typing -I bytecom -I asmcomp -I driver -I toplevel -c toplevel/toploop.mli
boot/ocamlrun boot/ocamlc -nostdlib -I boot -warn-error A -I utils -I parsing -I
typing -I bytecom -I asmcomp -I driver -I toplevel -c toplevel/toploop.ml
boot/ocamlrun boot/ocamlc -nostdlib -I boot -warn-error A -I utils -I parsing -I
typing -I bytecom -I asmcomp -I driver -I toplevel -c toplevel/trace.mli
boot/ocamlrun boot/ocamlc -nostdlib -I boot -warn-error A -I utils -I parsing -I
typing -I bytecom -I asmcomp -I driver -I toplevel -c toplevel/trace.ml
boot/ocamlrun boot/ocamlc -nostdlib -I boot -warn-error A -I utils -I parsing -I
typing -I bytecom -I asmcomp -I driver -I toplevel -c toplevel/topdirs.mli
boot/ocamlrun boot/ocamlc -nostdlib -I boot -warn-error A -I utils -I parsing -I
typing -I bytecom -I asmcomp -I driver -I toplevel -c toplevel/topdirs.ml
boot/ocamlrun boot/ocamlc -nostdlib -I boot -warn-error A -I utils -I parsing -I
typing -I bytecom -I asmcomp -I driver -I toplevel -c toplevel/topmain.mli
boot/ocamlrun boot/ocamlc -nostdlib -I boot -warn-error A -I utils -I parsing -I
typing -I bytecom -I asmcomp -I driver -I toplevel -c toplevel/topmain.ml
boot/ocamlrun boot/ocamlc -nostdlib -I boot -a -o toplevel/toplevellib.cma
utils/misc.cmo utils/tb cmo utils/config.cmo utils/clflags.cmo
utils/terminfo.cmo utils/ccomp.cmo utils/warnings.cmo parsi /linenum.cmo
parsing/location.cmo parsing/longident.cmo parsing/syntaxerr.cmo
parsing/parser.cmo p sing/lexer.cmo parsing/parse.cmo parsing/printast.cmo
typing/ident.cmo typing/path.cmo typing/prim ive.cmo typing/types.cmo
typing/btype.cmo typing/oprint.cmo typing/subst.cmo typing/predef.cmo typ
g/datarepr.cmo typing/env.cmo typing/typedtree.cmo typing/ctype.cmo
typing/printtyp.cmo typing/inc declass.cmo typing/mtype.cmo
typing/includecore.cmo typing/includemod.cmo typing/parmatch.cmo typi
/typetexp.cmo typing/typecore.cmo typing/typedecl.cmo typing/typeclass.cmo
typing/typemod.cmo byte mp/lambda.cmo bytecomp/printlambda.cmo
bytecomp/typeopt.cmo bytecomp/switch.cmo bytecomp/matching. o
bytecomp/translobj.cmo bytecomp/translcore.cmo bytecomp/translclass.cmo
bytecomp/translmod.cmo b ecomp/simplif.cmo bytecomp/runtimedef.cmo
bytecomp/meta.cmo bytecomp/instruct.cmo bytecomp/bytegen mo
bytecomp/printinstr.cmo bytecomp/opcodes.cmo bytecomp/emitcode.cmo
bytecomp/bytesections.cmo by comp/dll.cmo bytecomp/symtable.cmo
bytecomp/bytelink.cmo bytecomp/bytelibrarian.cmo bytecomp/bytep kager.cmo
driver/pparse.cmo driver/errors.cmo driver/compile.cmo toplevel/genprintval.cmo
toplevel oploop.cmo toplevel/trace.cmo toplevel/topdirs.cmo
toplevel/topmain.cmo
boot/ocamlrun boot/ocamlc -nostdlib -I boot -warn-error A -I utils -I parsing -I
typing -I bytecom -I asmcomp -I driver -I toplevel -c toplevel/topstart.ml
boot/ocamlrun boot/ocamlc -nostdlib -I boot -warn-error A -I utils -I parsing -I
typing -I bytecom -I asmcomp -I driver -I toplevel -c toplevel/expunge.ml
boot/ocamlrun boot/ocamlc -nostdlib -I boot -o expunge utils/misc.cmo
utils/tbl.cmo utils/config. o utils/clflags.cmo typing/ident.cmo typing/path.cmo
typing/types.cmo typing/btype.cmo typing/pred .cmo bytecomp/runtimedef.cmo
bytecomp/bytesections.cmo bytecomp/dll.cmo bytecomp/symtable.cmo topl
el/expunge.cmo
boot/ocamlrun boot/ocamlc -nostdlib -I boot -linkall -o ocaml.tmp
toplevel/toplevellib.cma toplev /topstart.cmo
make: *** [ocaml] Bus error

CONFIGURATION:

mkennedy@gentoo ocaml-3.06 $ ./configure
Configuring for a sparc64-unknown-linux-gnu ...
gcc found
The C compiler is ANSI-compliant.
Checking the sizes of integers and pointers...
OK, this is a regular 32 bit architecture.
64-bit "long long" integer type found (printf with "%ll").
This is a big-endian architecture.
Doubles can be word-aligned.
64-bit integers must be doubleword-aligned.
Native division and modulus have round-towards-zero semantics, will use them.
Dynamic loading of shared libraries is supported.
ranlib found
#! appears to work in shell scripts
POSIX signal handling found.
strerror() found.
times() found.
termcap functions found (with libraries '-lcurses')
You have BSD sockets.
socklen_t is defined in <sys/socket.h>
inet_aton() found.
unistd.h found.
off_t is defined in <sys/types.h>
dirent.h found.
rewinddir() found.
lockf() found.
mkfifo() found.
getcwd() found.
getwd() found.
getpriority() found.
utime() found.
utimes() found.
dup2() found.
fchmod() found.
truncate() found.
sys/select.h found.
select() found.
symlink() found.
waitpid() found.
wait4() found.
getgroups() found.
POSIX termios found.
setitimer() found.
gethostname() found.
uname() found.
gettimeofday() found.
mktime() found.
setsid() found.
putenv() found.
setlocale() and <locale.h> found.
dlopen() found.
mmap() found.
gethostbyname_r() found (with 6 arguments).
gethostbyaddr_r() found (with 8 arguments).
Replay debugger supported.
Cannot detect system stack overflow.
Threads library supported (using bytecode-level scheduling).
X11 not found, the "graph" library will not be supported.
NDBM found (in /usr/include)
Configuring LablTk...
X11 not found.
Configuration failed, LablTk will not be built.

** Configuration summary **

Directories where Objective Caml will be installed:
binaries.................. /usr/local/bin
standard library.......... /usr/local/lib/ocaml
manual pages.............. /usr/local/man (with extension .1)
Configuration for the bytecode compiler:
C compiler used........... gcc
options for compiling..... -fno-defer-pop -Wall -Wno-unused
-D_FILE_OFFSET_BITS=64
options for linking....... -Wl,-E -lm -ldl -lcurses
shared libraries are supported
options for compiling..... -fPIC -fno-defer-pop -Wall -Wno-unused
-D_FILE_OFFSET_BITS=64
command for building...... gcc -shared -o lib.so -Wl,-rpath,/a/path
objs
Configuration for the native-code compiler:
(not supported on this platform)
Source-level replay debugger: supported
Additional libraries supported:
unix str num dynlink bigarray threads dbm
Configuration for the "num" library:
target architecture ...... C
Configuration for the "graph" library:
options for compiling ....
options for linking ...... not found
The "labltk" library: not found

@vicuna
Copy link
Author

vicuna commented May 9, 2003

Comment author: administrator

Hi I ran into the folowing build error on a Gentoo GNU/Linux sparc
platform. The details are:

sys-libs/glibc-2.3.1-r4
sys-devel/binutils-2.13.90.0.18-r1
sys-devel/gcc-3.2.2-r2

This is a known problem with gcc 3.2.2. (See #7994 on the Caml bug
tracking system.) The attached patch to the "configure" script should
fix it.

  • Xavier Leroy

===================================================================
RCS file: /pub/anoncvs/caml/ocaml/configure,v
retrieving revision 1.183
retrieving revision 1.184
diff -u -p -r1.183 -r1.184
--- ocaml/configure 2003/01/09 12:01:51 1.183
+++ ocaml/configure 2003/03/10 17:04:00 1.184
@@ -391,17 +391,25 @@ esac

Determine alignment constraints

-sh ./runtest dblalign.c
-case $? in

    1. echo "Doubles can be word-aligned."
  • echo "#undef ARCH_ALIGN_DOUBLE" >> m.h;;
    
    1. echo "Doubles must be doubleword-aligned."
  • echo "#define ARCH_ALIGN_DOUBLE" >> m.h;;
    
  • *) echo "Something went wrong during alignment determination for doubles."
  • echo "I'm going to assume this architecture has alignment constraints over doubles."
    
  • echo "That's a safe bet: Objective Caml will work even if"
    
  • echo "this architecture has actually no alignment constraints."
    
  • echo "#define ARCH_ALIGN_DOUBLE" >> m.h;;
    

+case "$host" in

  • sparc--)
  • On Sparc V9 with certain versions of gcc, determination of double

  • alignment is not reliable (ocaml 3.06 fails to build on sparc with gcc 3.2. #7994), hence force it

  • echo "Doubles must be doubleword-aligned."
  • echo "#define ARCH_ALIGN_DOUBLE" >> m.h;;
  • *)
  • sh ./runtest dblalign.c
  • case $? in
  •  0) echo "Doubles can be word-aligned."
    
  •     echo "#undef ARCH_ALIGN_DOUBLE" >> m.h;;
    
  •  1) echo "Doubles must be doubleword-aligned."
    
  •     echo "#define ARCH_ALIGN_DOUBLE" >> m.h;;
    
  •  *) echo "Something went wrong during alignment determination for doubles."
    
  •     echo "I'm going to assume this architecture has alignment constraints over doubles."
    
  •     echo "That's a safe bet: Objective Caml will work even if"
    
  •     echo "this architecture has actually no alignment constraints."
    
  •     echo "#define ARCH_ALIGN_DOUBLE" >> m.h;;
    
  • esac;;
    esac

if $int64_native; then



@vicuna
Copy link
Author

vicuna commented May 9, 2003

Comment author: administrator

See #7994.

@vicuna vicuna closed this as completed May 9, 2003
@vicuna vicuna added the bug label Mar 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant