Segmetnation fault from example_v1 + Testing accelerated builds

22 views
Skip to first unread message

Wyatt Spear

unread,
Oct 8, 2021, 9:20:57 PM10/8/21
to MAGMA User
Greetings,

I'm running magma testing as part of the E4S spack deployment. The test just runs a few examples extracted from the MAGMA source tarball. example_sparse and example_sparse_operator work fine but example_v1 fails as shown below. Could I get some guidance on what might be wrong here, or if there is a different set of tests (ideally that work outside of the install source tree) that would be more appropriate for testing MAGMA deployment?

I also need to test builds of MAGMA that have been created with accelerator (cuda,rocm, etc) support. I assume the default tests make use of those features when they are available but if that is not the case I could use some direction finding some simple examples that exercise those features.

Regards,
Wyatt Spear

+ ./example_v1
Error in magma_getdevice_arch: MAGMA not initialized (call magma_init() first) or bad device
Error in magma_getdevice_arch: MAGMA not initialized (call magma_init() first) or bad device
Warning: magma_setmatrix_async_internal got NULL queue
./run.sh: line 6: 10722 Segmentation fault      ./example_v1

Mark Gates

unread,
Oct 9, 2021, 6:07:33 PM10/9/21
to Wyatt Spear, MAGMA User
We should probably remove example_v1, since that is for MAGMA v1.x, circa 2015.

I would just test that example_v2 works.

Mark

Wyatt Spear

unread,
Oct 11, 2021, 1:22:29 PM10/11/21
to Mark Gates, MAGMA User
Thanks! But I get the same error when I run example_v2:
+ ./example_v2
using MAGMA CPU interface

Error in magma_getdevice_arch: MAGMA not initialized (call magma_init() first) or bad device
Error in magma_getdevice_arch: MAGMA not initialized (call magma_init() first) or bad device
Warning: magma_setmatrix_async_internal got NULL queue
./run.sh: line 7: 53764 Segmentation fault      ./example_v2


I also get non-fatal 'Memory Free Error' messages from ./example_sparse and ./example_sparse_operator.

If there's a better external test code for general validation of magma I'm happy to swap to that instead.

Thanks,
Wyatt

Stanimire Tomov

unread,
Oct 14, 2021, 2:57:54 AM10/14/21
to MAGMA User, wjs...@gmail.com, MAGMA User, mga...@icl.utk.edu
These examples are simplified versions of
testing_zgesv_gpu -n 1000
and
testing_zgesv -n 1000
in the magma testing directory. There are many examples there. All can be generated with
make testing
or selected ones can be generated individually, e.g.,
make testing_zgesv_gpu
These testers can be used as an alternative. Moving to the example_v1 and example_v2, if they don't work most probably something is not matching of how magma was installed and what is in the header files.
Is it possible magma is installed twice and something gets mixed?
I just tried it and had a problem at the beginning with a previously installed version but after making sure I use only one installation version everything worked.
(On the system that I tested I installed magma in /home/tomov/magma/build/install and
 in order to use the makefile in examples I had to set where is magma.pc, e.g.,
 export PKG_CONFIG_PATH=${PKG_CONFIG_PATH}:/home/tomov/magma/build/install/lib/pkgconfig/
 and where the libraries are
 export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/home/tomov/magma/build/install/lib/
 If the library gets found automatically it  is possible it finds one from another installation).
Thanks,
Stan
Reply all
Reply to author
Forward
0 new messages