sourceryinstitute / OpenCoarrays

A parallel application binary interface for Fortran 2018 compilers.
http://www.opencoarrays.org
BSD 3-Clause "New" or "Revised" License
245 stars 58 forks source link

OpenCoarrays on Microsoft WSL2 Linux Ubuntu 20.0 #726

Closed shahmoradi closed 3 years ago

shahmoradi commented 3 years ago

Please note we will close your issue without comment if you delete, do not read or do not fill out the issue checklist below and provide ALL the requested information.

The title of the issue should start with Question: followed by a succinct title.

Please be descriptive, precise and concise. Thanks!

Good day OpenCoarrays developers, First, thanks for all your hard work to develop this fantastic library. I have recently installed OC on WSL1 and WSL2. The installation on WSL1 was unsuccessful and the installation on WSL2 finished properly, after a few tries. However, a fully-deterministic Coarray code that I am compiling and running crashes in an unpredictable way on WSL2. On a genuine Linux, the same code works perfectly fine using the same version of OpenCoarrays and passes all tests. So, this obviously points to some potential incompatibilities between WSL2 and OpenCoarrays. I am compiling OpenCoarrays 2.9.0 from the source on WSL2 Linux Ubuntu 20.0.

Are there any known issues with considerations with using OC on WSL2? Thank you.

shahmoradi commented 3 years ago

UPDATE

This issue turned out to be an extremely subtle bug that showed up when the load on individual processors was highly unbalanced, which is often the case on Windows systems, including WSL. Conversely, it would not show up on supercomputers. I flag this as resolved, but for future reference, won't delete it. Thanks for your lack of interest in responding, which forced me to further investigate this by myself, ultimately leading to the discovery of the bug, but more importantly, for the great so-far bug-free OpenCoarray package.

jerryd commented 3 years ago

Well, glad you sorted it out. I am sure someone would have replied, weekends are weekends. My experience with WSL has not been good. A parallel build of gcc/gfortran fails often depending on how many threads I launch. At the very core of it windows does not handle threading of a linux world very well at all. If I do a single thread build of gcc/gfortran it will complete fine, however, running the gcc/gfortran testsuite results in numerous "subtle" failures. WSL should have been named JNL, Just Not Linux. It serves a purpose I suppose, but if you are serious about computing and absolutely have to be in Windows (I prefer to dual boot so I do not go there), you might have better luck with a VM environment such as VirtualBox. (No guarantees),

Cheers

shahmoradi commented 3 years ago

I have realized that much of the problems are resolved in WSL2. WSL1 does not even compile some valid Fortran 2008 codes. But again, even WSL2 occasionally crashes the entire PC for no clear reason, with no prior warning. So, I have learned the hard way to close WSL sessions when not in use.