Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0001285OCamlOCaml generalpublic2002-07-31 18:522002-08-02 14:18
Reporteradministrator 
Assigned To 
PrioritynormalSeverityminorReproducibilityalways
StatusclosedResolutionno change required 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version 
Summary0001285: ocamlopt 3.05 + gcc 2.96 on redhat 7.1 = segfault
DescriptionFull_Name: Dan DuVarney
Version: 3.05
OS: RedHat 7.1
Submission from: ws58.seclab.cs.sunysb.edu (130.245.137.58)


I have a friend using caml 3.05 on a RedHat 7.1 system, and ocamlopt generates
bad code, even for programs like "hello world."

I suspect this is due to problems with gcc, but according to the release notes
for 3.05, ocaml is supposed to have a workaround for the gcc bug(s).

Anyway, the following session illustrates what I am talking about.

[dan@flute xxx]$ uname -a
 uname -a
Linux flute.seclab.cs.sunysb.edu 2.4.9-31 #1 Tue Feb 26 07:11:02 EST 2002 i686
unknown
[dan@flute xxx]$ gcc -v
gcc -v
Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/2.96/specs
gcc version 2.96 20000731 (Red Hat Linux 7.1 2.96-98)
[dan@flute xxx]$ cat hello.ml
cat hello.ml
let main () =
    print_string "Hello, World!\n"

let _ = main ()

[dan@flute xxx]$ ocamlopt -o hello hello.ml
ocamlopt -o hello hello.ml
[dan@flute xxx]$ ./hello
./hello
Segmentation fault
[dan@flute xxx]$

That's it. Let me know if you need any additional information.

-Dan
--
dand@cs.sunysb.edu

TagsNo tags attached.
Attached Files

- Relationships

-  Notes
(0002539)
administrator (administrator)
2002-08-01 13:29

> I have a friend using caml 3.05 on a RedHat 7.1 system, and ocamlopt
> generates bad code, even for programs like "hello world."
>
> I suspect this is due to problems with gcc, but according to the
> release notes for 3.05, ocaml is supposed to have a workaround for
> the gcc bug(s).

The problems with some versions of gcc 2.96 lead to more subtle
crashes than this one. Since you're the only one who reported this
problem, I suspect a corrupted file or library somewhere. Did you
install from sources or from RPM? It might help to try the other
installation method (e.g. install from RPM if you compiled from
source). Also, you can send me the hello.cmx, hello.o and hello files
generated in your test.

- Xavier Leroy

(0002540)
administrator (administrator)
2002-08-02 14:18

Prlbme went away when compiling and installing from sources. Looks like a
library issue with the RPM distrib. Couldn't pinpoint it, though.

- Issue History
Date Modified Username Field Change
2005-11-18 10:14 administrator New Issue


Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker