mame / quine-relay

An uroboros program with 100+ programming languages
14.06k stars 556 forks source link

Failed at Fortran #2

Closed thedufer closed 11 years ago

thedufer commented 11 years ago
> gfortran -o QR QR.f && ./QR > QR.f90
gfortran: internal compiler error: Killed (program f951)
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-4.6/README.Bugs> for instructions.
> gfortran --version
GNU Fortran (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3
Copyright (C) 2011 Free Software Foundation, Inc.

GNU Fortran comes with NO WARRANTY, to the extent permitted by law.
You may redistribute copies of GNU Fortran
under the terms of the GNU General Public License.
For more information about these matters, see the file named COPYING

The source file is 27685 lines long, so I'm going to pass on putting it here.

> lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 12.04 LTS
Release:    12.04
Codename:   precise

I used your apt-get line to install everything (except clojure; couldn't find package clojure1.4). Do I need to upgrade Fortran?

mame commented 11 years ago

gfortran: internal compiler error: Killed (program f951) Please submit a full bug report, with preprocessed source if appropriate.

... ;-) I guess it's not my fault. Are you using 32bit?

thedufer commented 11 years ago

Nope, its 64 bit. I'll see if I can figure out installing a new version..

mame commented 11 years ago

The compilation of QR.f seems to require 700MB memory.

$ /usr/bin/time -f "%M KB" gfortran -o QR QR.f
754648 KB

It may require more depending on your platform. So I guess this bug is caused by out of memory. Please add swap space. Smarter encoding (of Fortran90) will reduce memory usage, but will make the formatted Ruby code bigger. Rather, I'd like to keep it simple, stupid.

mame commented 11 years ago

I think I've found a workaround: tcc can be used to compile QR.f much faster, with much less memory than gcc. Now Makefile uses tcc for FORTRAN77 and INTERCAL. Please let me know if the issue is not fixed yet.

thedufer commented 11 years ago

Wow, quick work. Works fine now!

MalleswararaoMaguluri commented 9 years ago

Hi,

How did you resolve this error. I am also facing the same error while installing WRF.

Thanks & Regards, Mallesh