On 2010-06-02 23:00-0700 Alan W. Irwin wrote:
> If you look at the attached simple.f90, you will see I have whittled the
> problem down to just two routines, plvectors_0 and plvectors_1. If I remove
> either of them or simply rename either of them, the Wine/MinGW/gfortran
> issue disappears. So it appears that somehow the plvectors_0 name is
> clashing with the plvectors_1 name for that platform.
Since these are private functions I thought I could work around the problem
by renaming one of them in our Fortran 95 interface, but it turns out there
is at least one other pair of function names (plcontour_2_all and
plcontour_tr_all) which clash with each other in our Fortran 95 interface,
and probably more. (It is labourous to find these pairs because you have to
eliminate functions one by one from the original until you find a pair that
cause the issue. There are something like 25 different functions involved
so there are a lot of different combinations.)
Clint, I need advice on not only how and where to report this bug, but even
what to call it. It is not a name clash since the names are obviously
distinct, but it must be a clash in how these different pairs of names are
represented. My best guess is MinGW gfortran hashes the names when reading in
the module file (that is when the error occurs, because I can avoid the
error altogether if I drop the "use plplotp" statement in simple.f90), and
that hash is very poorly implemented in Wine, but there may be other
possibilities.
Alan
__________________________
Alan W. Irwin
Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).
Programming affiliations with the FreeEOS equation-of-state implementation
for stellar interiors (freeeos.sf.net); PLplot scientific plotting software
package (plplot.org); the libLASi project (unifont.org/lasi); the Loads of
Linux Links project (loll.sf.net); and the Linux Brochure Project
(lbproject.sf.net).
__________________________
Linux-powered Science
__________________________

Thread view

To Hazen, Werner, and Arjen:
I am directing this mostly to you guys because you have access to pure Windows
systems, and I would appreciate it if one or all of you
try a simple MinGW test on that platform to confirm a MinGW gfortran
issue I am finding under Wine that is stopping builds of our Fortran 95
interface (although Fortran 77 is fine).
The issue has been reported at
http://sourceforge.net/tracker/?func=detail&aid=2981639&group_id=2435&atid=102435
including a tarball of a minimal test case made up of the configured
plflt.inc file and sfstubs.f90, sfstubs.h, and sfstubsf95.f90 which
should be familiar to you, but which make it very easy to run the test.
Those files give me the following compilation error:
wine@...> wine gfortran -o test.obj -c sfstubsf95.f90
Fatal Error: Reading module plplotp at line 491 column 35: Expected left
parenthesis
gfortran.exe: Internal error: Aborted (program f951)
Please submit a full bug report.
See <http://gcc.gnu.org/bugs.html&gt; for instructions.
I get this type of error for MinGW-4.4.0, a recent snapshot of
a pre-release version of MinGW-4.5.0, and now also for the final
release of MinGW-4.5.0 (using Wine 1.1.42 from winehq.com).
A complicating factor for my bug report is it is done under Wine. Could one
of you do the same simple compilation check for MinGW-4.4.0 on Windows and
report the results to me (and also at the URL for the bug report above). I
am pretty sure this is just a MinGW gfortran issue regardless of whether it
is run under Wine or native Windows, but if you can confirm that, this issue
will probably be taken more seriously by the MinGW developers.
MinGW-4.4.0 requires just one file download
from
https://sourceforge.net/downloads/mingw/MinGW/BaseSystem/GCC/Version4/Previous
Release gcc-4.4.0/
(note there are embedded blanks in "Previous Release gcc-4.4.0"). Also, note
that the prefix above is the only one that currently works. The more normal
SF download prefix of https://sourceforge.net/projects/mingw/files/MinGW...
just doesn't work for browsers right now although I can wget MinGW files
using that more standard prefix.)
There are a lot of different files in the above directory, but the one you
want is gcc-full-4.4.0-mingw32-bin-2.tar.lzma which is why the installation
of MinGW-4.4.0 is so easy. There is no equivalent "full" file for
MinGW=4.5.0 so you have to download a long list of individual files. (If
anybody is interested in that list, I have put together a shell script to
download and unpack everything needed for MinGW-4.5.0.)
Thanks in advance for your help with investigating whether this gfortran
Fortran 95 issue for MinGW occurs on Windows as well as on my Wine platform.
Alan
__________________________
Alan W. Irwin
Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).
Programming affiliations with the FreeEOS equation-of-state implementation
for stellar interiors (freeeos.sf.net); PLplot scientific plotting software
package (plplot.org); the libLASi project (unifont.org/lasi); the Loads of
Linux Links project (loll.sf.net); and the Linux Brochure Project
(lbproject.sf.net).
__________________________
Linux-powered Science
__________________________

On 2010-06-02 15:45-0700 Alan W. Irwin wrote:
> To Hazen, Werner, and Arjen:
> The issue has been reported at
> http://sourceforge.net/tracker/?func=detail&aid=2981639&group_id=2435&atid=102435
> including a tarball of a minimal test case made up of the configured
> plflt.inc file and sfstubs.f90, sfstubs.h, and sfstubsf95.f90 which
> should be familiar to you, but which make it very easy to run the test.
>
> Those files give me the following compilation error:
>
> wine@...> wine gfortran -o test.obj -c sfstubsf95.f90
> Fatal Error: Reading module plplotp at line 491 column 35: Expected left
> parenthesis
> gfortran.exe: Internal error: Aborted (program f951)
> Please submit a full bug report.
> See <http://gcc.gnu.org/bugs.html&gt; for instructions.
I have now greatly simplified the test case to one source file (see attached
simple.f90) with the following results:
wine@...> wine gfortran -o test.obj -c simple.f90
Fatal Error: Reading module plplotp at line 28 column 41: Expected left
parenthesis
gfortran.exe: Internal error: Aborted (program f951)
Please submit a full bug report.
See <http://gcc.gnu.org/bugs.html&gt; for instructions.
That same file compiles without errors under Linux gfortran.
If you look at the attached simple.f90, you will see I have whittled the
problem down to just two routines, plvectors_0 and plvectors_1. If I remove
either of them or simply rename either of them, the Wine/MinGW/gfortran
issue disappears. So it appears that somehow the plvectors_0 name is
clashing with the plvectors_1 name for that platform.
I have CC'd Clint Stimpson (who is not subscribed to the plplot-devel
mailing list) because he was so helpful previously when there was a CMake
filename issue under Wine. Of course, this might not be a name issue at all
under Wine, but the only way we can tell that is to run the above simple
test in a pure Windows environment.
Alan
__________________________
Alan W. Irwin
Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).
Programming affiliations with the FreeEOS equation-of-state implementation
for stellar interiors (freeeos.sf.net); PLplot scientific plotting software
package (plplot.org); the libLASi project (unifont.org/lasi); the Loads of
Linux Links project (loll.sf.net); and the Linux Brochure Project
(lbproject.sf.net).
__________________________
Linux-powered Science
__________________________

On 2010-06-02 23:00-0700 Alan W. Irwin wrote:
> If you look at the attached simple.f90, you will see I have whittled the
> problem down to just two routines, plvectors_0 and plvectors_1. If I remove
> either of them or simply rename either of them, the Wine/MinGW/gfortran
> issue disappears. So it appears that somehow the plvectors_0 name is
> clashing with the plvectors_1 name for that platform.
Since these are private functions I thought I could work around the problem
by renaming one of them in our Fortran 95 interface, but it turns out there
is at least one other pair of function names (plcontour_2_all and
plcontour_tr_all) which clash with each other in our Fortran 95 interface,
and probably more. (It is labourous to find these pairs because you have to
eliminate functions one by one from the original until you find a pair that
cause the issue. There are something like 25 different functions involved
so there are a lot of different combinations.)
Clint, I need advice on not only how and where to report this bug, but even
what to call it. It is not a name clash since the names are obviously
distinct, but it must be a clash in how these different pairs of names are
represented. My best guess is MinGW gfortran hashes the names when reading in
the module file (that is when the error occurs, because I can avoid the
error altogether if I drop the "use plplotp" statement in simple.f90), and
that hash is very poorly implemented in Wine, but there may be other
possibilities.
Alan
__________________________
Alan W. Irwin
Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).
Programming affiliations with the FreeEOS equation-of-state implementation
for stellar interiors (freeeos.sf.net); PLplot scientific plotting software
package (plplot.org); the libLASi project (unifont.org/lasi); the Loads of
Linux Links project (loll.sf.net); and the Linux Brochure Project
(lbproject.sf.net).
__________________________
Linux-powered Science
__________________________

Hi Alan,
I am unable to get the compiler to work properly - there is a reference
to a file "libgcj_s.dll" which is not included in the distribution.
(I tried both the .lzma archive and the separate archives).
I was able to compile the simple.f90 file without any problems using
gfortran 4.4.3 as it is supplied by Equation Solution
(www.equation.com). This does not really help of course ...
Regards,
Arjen
On 2010-06-03 08:06, Alan W. Irwin wrote:
> This time, actually attach simple.f90.
>
> Alan
> __________________________
> Alan W. Irwin
>
> Astronomical research affiliation with Department of Physics and Astronomy,
> University of Victoria (astrowww.phys.uvic.ca).
>
> Programming affiliations with the FreeEOS equation-of-state implementation
> for stellar interiors (freeeos.sf.net); PLplot scientific plotting software
> package (plplot.org); the libLASi project (unifont.org/lasi); the Loads of
> Linux Links project (loll.sf.net); and the Linux Brochure Project
> (lbproject.sf.net).
> __________________________
>
> Linux-powered Science
> __________________________
>

On 2010-06-04 08:53+0200 Davide Cesari wrote:
> Il 03/06/2010 08:00, Alan W. Irwin ha scritto:
>> On 2010-06-02 15:45-0700 Alan W. Irwin wrote:
>>
>> I have now greatly simplified the test case to one source file (see attached
>> simple.f90) with the following results:
>>
>> wine@...> wine gfortran -o test.obj -c simple.f90
>> Fatal Error: Reading module plplotp at line 28 column 41: Expected left
>> parenthesis
>> gfortran.exe: Internal error: Aborted (program f951)
>> Please submit a full bug report.
>> See<http://gcc.gnu.org/bugs.html&gt; for instructions.
>>
>> That same file compiles without errors under Linux gfortran.
>
> I cannot test on Windows/Wine too, so mine is just a conjecture:
> couldn't it be a problem connected to the use of a variable named
> "scale" wich is also a f90 intrinsic function? This should not be a
> problem in principle if scale is redefined, but some buggy compilers may
> crash in such cases, I suggest to try changing scale to something else
> and see what happens.
Hi Davide:
Thanks for that alternative interesting explanation. However, I changed
scale ==> xx_scale throughout the file, and got identical results;
identically bad on wine, and good on Linux. Therefore, I am still leaning
toward some sort of hash collision under Wine as an explanation, but
I am open to other explanations as well.
Alan
__________________________
Alan W. Irwin
Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).
Programming affiliations with the FreeEOS equation-of-state implementation
for stellar interiors (freeeos.sf.net); PLplot scientific plotting software
package (plplot.org); the libLASi project (unifont.org/lasi); the Loads of
Linux Links project (loll.sf.net); and the Linux Brochure Project
(lbproject.sf.net).
__________________________
Linux-powered Science
__________________________