Re: [petsc-dev] HYPRE setup for GPU and CPU solves and other GPU solver questions

2023-05-01 Thread Junchao Zhang
On Mon, May 1, 2023 at 8:14 AM Andrew Ho wrote: > Hi, > > I noticed that when I compile PETSc/HYPRE with GPU support, it demands > that I use GPU vectors/matrices (in the form of either > VECCUDA/MATMPIAIJCUSPARSE, VECHIP/MATMPIAIJHIPSPARSE, or > VECKOKKOS/MATMPIAIJKOKKOS). However, I would like

Re: [petsc-dev] I will be converting .rst files to .md; let me know if you have any outstanding MR with changes

2023-03-24 Thread Junchao Zhang
I have https://gitlab.com/petsc/petsc/-/merge_requests/6225, but my change is tiny so that you can go ahead, and I will revise it later. --Junchao Zhang On Fri, Mar 24, 2023 at 7:08 AM Barry Smith wrote: > > I will be converting .rst files to .md; please let me know if you ha

Re: [petsc-dev] Apply for Google Summer of Code 2023?

2023-02-23 Thread Junchao Zhang
Karl, Thanks for the effort. I feel we should have had less projects and instead gave a good introduction to one or two. Lessons for next year. --Junchao Zhang On Wed, Feb 22, 2023 at 10:48 PM Karl Rupp wrote: > Dear all, > > unfortunately our application for the Google Summer of

Re: [petsc-dev] Apply for Google Summer of Code 2023?

2023-02-04 Thread Junchao Zhang
to the project] > > I applied for the SRP (Sustainable Research Pathways) program. It incurs no cost. If it goes well, I will have a student this summer. > Satish > > > On Fri, 3 Feb 2023, Junchao Zhang wrote: > > > On Fri, Feb 3, 2023 at 1:31 PM Karl Rupp wrote: >

Re: [petsc-dev] Apply for Google Summer of Code 2023?

2023-02-03 Thread Junchao Zhang
On Fri, Feb 3, 2023 at 1:31 PM Karl Rupp wrote: > Dear PETSc developers, > > in order to attract students to PETSc development, I'm thinking about a > PETSc application for Google Summer of Code (GSoC) 2023: > https://summerofcode.withgoogle.com/programs/2023 > > The org application deadline is

Re: [petsc-dev] Swarm tag error

2022-11-23 Thread Junchao Zhang
de->send_tags[i], de->comm, &de-> _requests[i])); 542 for (i = 0; i < np; ++i) PetscCallMPI(MPI_Irecv(&de-> messages_to_be_recvieved[i], 1, MPIU_INT, de->neighbour_procs[i], de-> recv_tags[i], de->comm, &de->_requests[np + i])); --Junchao Zhang On Tue, Nov

Re: [petsc-dev] Swarm tag error

2022-11-22 Thread Junchao Zhang
I don't understand why you need so many tags. Is the communication pattern actually MPI_Alltoallv, but you implemented it in MPI_Send/Recv? --Junchao Zhang On Mon, Nov 21, 2022 at 2:37 PM Matthew Knepley wrote: > In data_ex.c, Swarm uses a distinct tag for each pair of processes

Re: [petsc-dev] [petsc-users] Regarding the status of MatSolve on GPUs

2022-10-19 Thread Junchao Zhang
Sherry, sorry to ping you again for this issue. --Junchao Zhang On Tue, Oct 11, 2022 at 11:04 AM Junchao Zhang wrote: > Hi, Sherry, > A petsc user wants to call MatSolve(mat, b, x) multiple times with > different b on GPUs. In petsc, the code is like > > PetscScal

Re: [petsc-dev] [petsc-users] Regarding the status of MatSolve on GPUs

2022-10-11 Thread Junchao Zhang
Hi, Sherry, A petsc user wants to call MatSolve(mat, b, x) multiple times with different b on GPUs. In petsc, the code is like PetscScalar *bptr = NULL; VecGetArray(b, &bptr) pdgssvx3d(.., bptr, ..); Note VecGetArray() returns a host pointer. If vector b's latest data is on GPU, PETSc needs to

Re: [petsc-dev] PetscSFCount is not compatible with MPI_Count

2022-03-29 Thread Junchao Zhang
' to parameter of type 'long long *' [-Wincompatible-pointer-types] void bar() {long a = 0; foo(&a);} ^~ test.c:1:27: note: passing argument to parameter here extern int foo(long long *); ^ 1 warning generated. I would just use MPI types for MPI

Re: [petsc-dev] PetscSFCount is not compatible with MPI_Count

2022-03-29 Thread Junchao Zhang
On Tue, Mar 29, 2022 at 5:25 PM Satish Balay via petsc-dev < petsc-dev@mcs.anl.gov> wrote: > I'm not sure why we have PetscSFCount - and not always use MPI_Count. > > Maybe this would work? > > Perhaps Junchao can clarify > I used MPIU_Ineighbor_alltoallv() to wrap MPI_Ineighbor_alltoallv() or MPI

Re: [petsc-dev] PetscSFCount is not compatible with MPI_Count

2022-03-29 Thread Junchao Zhang
On Tue, Mar 29, 2022 at 4:59 PM Satish Balay via petsc-dev < petsc-dev@mcs.anl.gov> wrote: > We do have such builds in CI - don't know why CI didn't catch it. > > $ grep with-64-bit-indices=1 *.py > arch-ci-freebsd-cxx-cmplx-64idx-dbg.py: '--with-64-bit-indices=1', > arch-ci-linux-cuda-double-64i

Re: [petsc-dev] MatSetPreallocationCOO remove attached objects?

2022-03-01 Thread Junchao Zhang
ll be kept and what will be discarded. --Junchao Zhang On Tue, Mar 1, 2022 at 3:00 PM Mark Adams wrote: > I can attach my containers (3!) after this call. > Actually better structure in my code but this should be fixed. > Thanks > > On Tue, Mar 1, 2022 at 3:06 PM Barry Smith wr

Re: [petsc-dev] MatSetPreallocationCOO remove attached objects?

2022-03-01 Thread Junchao Zhang
I realized this problem but did not expect someone would run into it :) Let me think again. --Junchao Zhang On Tue, Mar 1, 2022 at 1:33 PM Mark Adams wrote: > I have a container attached to my matrix and it seems to go away after a > call to MatSetPreallocationCOO. > Does that sound plausible? >

Re: [petsc-dev] Current status of using streams within PETSc

2022-02-15 Thread Junchao Zhang
Besides the MPI synchronization issue, we need new async APIs like VecAXPYAsync() to pass scalars produced on device. --Junchao Zhang On Tue, Feb 15, 2022 at 10:11 AM Jed Brown wrote: > Note that operations that don't have communication (like VecAXPY and > VecPointwiseMult) are

Re: [petsc-dev] Kokkos/Crusher perforance

2022-01-26 Thread Junchao Zhang
I don't know if this is due to bugs in petsc/kokkos backend. See if you can run 6 nodes (48 mpi ranks). If it fails, then run the same problem on Summit with 8 nodes to see if it still fails. If yes, it is likely a bug of our own. --Junchao Zhang On Wed, Jan 26, 2022 at 8:44 AM Mark

Re: [petsc-dev] Kokkos/Crusher perforance

2022-01-24 Thread Junchao Zhang
On Mon, Jan 24, 2022 at 12:55 PM Mark Adams wrote: > > > On Mon, Jan 24, 2022 at 1:38 PM Junchao Zhang > wrote: > >> Mark, I think you can benchmark individual vector operations, and once we >> get reasonable profiling results, we can move to solvers etc. >> >

Re: [petsc-dev] Kokkos/Crusher perforance

2022-01-24 Thread Junchao Zhang
Mark, I think you can benchmark individual vector operations, and once we get reasonable profiling results, we can move to solvers etc. --Junchao Zhang On Mon, Jan 24, 2022 at 12:09 PM Mark Adams wrote: > > > On Mon, Jan 24, 2022 at 12:44 PM Barry Smith wrote: > >> &g

Re: [petsc-dev] Kokkos/Crusher perforance

2022-01-23 Thread Junchao Zhang
On Sun, Jan 23, 2022 at 11:22 PM Barry Smith wrote: > > > On Jan 24, 2022, at 12:16 AM, Junchao Zhang > wrote: > > > > On Sun, Jan 23, 2022 at 10:44 PM Barry Smith wrote: > >> >> Junchao, >> >> Without GPU aware MPI, is it moving the en

Re: [petsc-dev] Kokkos/Crusher perforance

2022-01-23 Thread Junchao Zhang
On Sun, Jan 23, 2022 at 10:44 PM Barry Smith wrote: > > Junchao, > > Without GPU aware MPI, is it moving the entire vector to the CPU and > doing the scatter and moving everything back or does it just move up > exactly what needs to be sent to the other ranks and move back exactly what > i

Re: [petsc-dev] Kokkos/Crusher perforance

2022-01-23 Thread Junchao Zhang
On Sat, Jan 22, 2022 at 9:00 PM Junchao Zhang wrote: > > > > On Sat, Jan 22, 2022 at 5:00 PM Barry Smith wrote: > >> >> The GPU flop rate (when 100 percent flops on the GPU) should always be >> higher than the overall flop rate (the previous column). For

Re: [petsc-dev] Kokkos/Crusher perforance

2022-01-22 Thread Junchao Zhang
+00 0.0e+00 > 0.0e+00 0 0 0 0 0 10 0 0 0 0 0 0 0 0.00e+000 > 0.00e+00 0 > PCApply 402 1.0 3.8758e-01 9.3 8.43e+08 1.0 0.0e+00 0.0e+00 > 0.0e+00 0 0 0 0 0 2 1 0 0 0 138396 262413 0 0.00e+000 > 0.00e+00 100 > > --

Re: [petsc-dev] Kokkos/Crusher perforance

2022-01-22 Thread Junchao Zhang
On Sat, Jan 22, 2022 at 10:04 AM Mark Adams wrote: > Logging GPU flops should be inside of PetscLogGpuTimeBegin()/End() right? > No, PetscLogGpuTime() does not know the flops of the caller. > > On Fri, Jan 21, 2022 at 9:47 PM Barry Smith wrote: > >> >> Mark, >> >> Fix the logging before y

Re: [petsc-dev] Kokkos/Crusher perforance

2022-01-21 Thread Junchao Zhang
On Fri, Jan 21, 2022 at 8:08 PM Barry Smith wrote: > > Junchao, Mark, > > Some of the logging information is non-sensible, MatMult says all > flops are done on the GPU (last column) but the GPU flop rate is zero. > > It looks like MatMult_SeqAIJKokkos() is missing > PetscLogGpuTimeBe

Re: [petsc-dev] Gitlab workflow discussion with GitLab developers

2022-01-20 Thread Junchao Zhang
* Easily retarget a branch, e.g., from main to release (currently I have to checkout to local machine, do rebase, then push) --Junchao Zhang On Thu, Jan 20, 2022 at 7:05 PM Barry Smith wrote: > > I got asked to go over some of my Gitlab workflow uses next week with > some Gitlab developers

Re: [petsc-dev] cuda with kokkos-cuda build fail

2022-01-07 Thread Junchao Zhang
zed on MPI ranks, then each rank will consume resources on GPU. > > I will try it again. > > Thanks, > > > On Fri, Jan 7, 2022 at 12:06 PM Junchao Zhang > wrote: > >> It failed when you did not even pass any vec/mat kokkos options? It does >> not make sense

Re: [petsc-dev] cuda with kokkos-cuda build fail

2022-01-07 Thread Junchao Zhang
It failed when you did not even pass any vec/mat kokkos options? It does not make sense and you need to double check that. --Junchao Zhang On Thu, Jan 6, 2022 at 9:33 PM Mark Adams wrote: > I seem to have a regression with using aijcusprase in a kokkos build. It's > OK with a st

Re: [petsc-dev] Questions around benchmarking and data loading with PETSc

2021-12-11 Thread Junchao Zhang
I expected TACO was better since its website says "It uses novel compiler techniques to get performance competitive with hand-optimized kernels" --Junchao Zhang On Sat, Dec 11, 2021 at 5:56 PM Rohan Yadav wrote: > Sorry, what’s surprising about this? 40 mpi ranks on a single nod

Re: [petsc-dev] Questions around benchmarking and data loading with PETSc

2021-12-11 Thread Junchao Zhang
> Interesting. TACO is supposed to give an optimized SpMV. > > Rohan > > On Sat, Dec 11, 2021 at 6:07 PM Junchao Zhang > wrote: > >> >> >> On Sat, Dec 11, 2021, 4:22 PM Rohan Yadav wrote: >> >>> Thanks all for the help, the main problem was the

Re: [petsc-dev] Questions around benchmarking and data loading with PETSc

2021-12-11 Thread Junchao Zhang
his is what I expected. Given that PETSc uses high-performance >> kernels for for the sparse matrix operation itself, I was surprised to see >> that the single-thread performance of PETSc to be closer to a baseline like >> TACO. This performance will likely improve when I compile

Re: [petsc-dev] Questions around benchmarking and data loading with PETSc

2021-12-11 Thread Junchao Zhang
implementation of SpMV. As a baseline, one can apply optimizations to it. PETSc does not do sophisticated sparse matrix optimization itself, instead it relies on third-party libraries. I remember we had OSKI from Berkeley for CPU, and on GPU we use cuSparse, hipSparse, MKLSparse or Kokkos-Kernels.

Re: [petsc-dev] Questions around benchmarking and data loading with PETSc

2021-12-10 Thread Junchao Zhang
On Fri, Dec 10, 2021 at 8:05 PM Rohan Yadav wrote: > Hi, I’m Rohan, a student working on compilation techniques for distributed > tensor computations. I’m looking at using PETSc as a baseline for > experiments I’m running, and want to understand if I’m using PETSc as it > was intended to achieve

Re: [petsc-dev] kokkos error

2021-11-21 Thread Junchao Zhang
You can add -v to the offending command line to see what happened, i.e., how nvcc_wrapper passed options to g++. --Junchao Zhang On Sun, Nov 21, 2021 at 12:05 PM Mark Adams wrote: > Any idea what is going wrong with this? > > Using PETSC_DIR=/global/homes/m/madams/petsc and > PET

Re: [petsc-dev] CUDA + OpenMP on Summit with Hypre

2021-11-13 Thread Junchao Zhang
On Sat, Nov 13, 2021 at 2:24 PM Mark Adams wrote: > I have a user that wants CUDA + Hypre on Sumit and they want to use OpenMP > in their code. I configured with openmp but without thread safety and got > this error. > > Maybe there is no need for us to do anything with omp in our > configuration

Re: [petsc-dev] HIP / hypre

2021-11-10 Thread Junchao Zhang
Justin, We like to have a wrapper over CUDA/HIP since with that we only need to maintain one code base. Scott (Cc'ed) may introduce his work/thoughts along this line and coordinate with Jacob and your team. --Junchao Zhang On Wed, Nov 10, 2021 at 12:50 PM Jacob Faibussowitsch

Re: [petsc-dev] OpenMP

2021-11-06 Thread Junchao Zhang
on */ > > And I see _OPENMP is a macro for the release date (mm) of the OMP > version. It's not clear what the v5.0 is ( > https://www.openmp.org/specifications/) > {200505,"2.5"},{200805,"3.0"},{201107,"3.1"},{201307,"4.0"},{201511,&

Re: [petsc-dev] OpenMP

2021-11-06 Thread Junchao Zhang
On Sat, Nov 6, 2021 at 5:51 AM Mark Adams wrote: > Two questions on OMP: > > * Can I test for the version of OMP? I want >= 5 and I see this, which > looks promising: > include/petscsys.h:#elif defined(_OPENMP) && *_OPENMP >= 201307* && > !defined(_WIN32) > > * What is the difference between HAVE

Re: [petsc-dev] cuda-memcheck finds an error on Summit

2021-09-26 Thread Junchao Zhang
Mark, without cuda-memcheck, did the test run? --Junchao Zhang On Sun, Sep 26, 2021 at 12:38 PM Mark Adams wrote: > FYI, I am getting this with cuda-memcheck on Summit with CUDA 11.0.3: > > jsrun -n 48 -a 6 -c 6 -g 1 -r 6 --smpiargs -gpu cuda-memcheck ../ex13-cu > -dm_plex_box_

Re: [petsc-dev] cuSparse vector performance issue

2021-09-25 Thread Junchao Zhang
On Sat, Sep 25, 2021 at 4:45 PM Mark Adams wrote: > I am testing my Landau code, which is MPI serial, but with many > independent MPI processes driving each GPU, in an MPI parallel harness code > (Landau ex2). > > Vector operations with Kokkos Kernels and cuSparse are about the same (KK > is fast

Re: [petsc-dev] Cannot locate file: share/petsc/datafiles/matrices/small

2021-09-14 Thread Junchao Zhang
Yes, we can turn it off. The code without real use is just a maintenance burden. --Junchao Zhang On Tue, Sep 14, 2021 at 10:45 AM Barry Smith wrote: > > Ok, so it could be a bug in PETSc, but if it appears with particular MPI > implementations shouldn't we turn off the su

Re: [petsc-dev] Cannot locate file: share/petsc/datafiles/matrices/small

2021-09-14 Thread Junchao Zhang
MPI one-sided is tricky and needs careful synchronization (like OpenMP). An incorrect code could work in one interface but fail in another. --Junchao Zhang On Tue, Sep 14, 2021 at 10:01 AM Barry Smith wrote: > >It sounds reproducible and related to using a particular versions of >

Re: [petsc-dev] Cannot locate file: share/petsc/datafiles/matrices/small

2021-09-14 Thread Junchao Zhang
Without a standalone & valid mpi example to reproduce the error, we are not assured to say it is an OpenMPI bug. --Junchao Zhang On Tue, Sep 14, 2021 at 6:17 AM Matthew Knepley wrote: > Okay, we have to send this to OpenMPI. Volunteers? > > Maybe we should note this i

Re: [petsc-dev] Cannot locate file: share/petsc/datafiles/matrices/small

2021-09-13 Thread Junchao Zhang
Hi, Stefano, Ping you again to see if you want to resolve this problem before petsc-3.16 --Junchao Zhang On Sun, Sep 12, 2021 at 3:06 PM Antonio T. sagitter < sagit...@fedoraproject.org> wrote: > Unfortunately, it's not possible. I must use the OpenMPI provided by > Fe

Re: [petsc-dev] Cannot locate file: share/petsc/datafiles/matrices/small

2021-09-12 Thread Junchao Zhang
An old issue with SF_Window is at https://gitlab.com/petsc/petsc/-/issues/555, though which is a different error. --Junchao Zhang On Sun, Sep 12, 2021 at 2:20 PM Junchao Zhang wrote: > We met SF + Windows errors before. Stefano wrote the code, which I don't > think was worth doi

Re: [petsc-dev] Cannot locate file: share/petsc/datafiles/matrices/small

2021-09-12 Thread Junchao Zhang
o you think? --Junchao Zhang On Sun, Sep 12, 2021 at 2:10 PM Pierre Jolivet wrote: > > On 12 Sep 2021, at 8:56 PM, Matthew Knepley wrote: > > On Sun, Sep 12, 2021 at 2:49 PM Antonio T. sagitter < > sagit...@fedoraproject.org> wrote: > >> Those attached are configu

Re: [petsc-dev] help on Summit

2021-08-30 Thread Junchao Zhang
Can you use less fancy 'static const int'? --Junchao Zhang On Mon, Aug 30, 2021 at 1:02 PM Jacob Faibussowitsch wrote: > No luck with C++14 > > > TL;DR: you need to have host and device compiler either both using c++17 > or neither using c++17. > > Long vers

Re: [petsc-dev] help on Summit

2021-08-30 Thread Junchao Zhang
Petsc::CUPMInterface @Jacob Faibussowitsch --Junchao Zhang On Mon, Aug 30, 2021 at 9:35 AM Mark Adams wrote: > I was running fine this AM and am bouncing between modules to help two > apps (ECP milestone season) at the same time and something broke. I did > update main and I get

Re: [petsc-dev] PETSC_COMM_WORLD not a PETSc communicator

2021-08-16 Thread Junchao Zhang
Barry, Thanks for the PetscRegisterFinalize() suggestion. I made an MR at https://gitlab.com/petsc/petsc/-/merge_requests/4238 In rare cases, if I do need to duplicate communicators, I now free them through PetscRegisterFinalize(). --Junchao Zhang On Sun, Aug 15, 2021 at 12:50 PM Barry

Re: [petsc-dev] PETSC_COMM_WORLD not a PETSc communicator

2021-08-14 Thread Junchao Zhang
On Thu, Aug 12, 2021 at 11:22 AM Barry Smith wrote: > > User visible communicators generally do not have a keyval attached. > Rather the keyval is attached to the inner communicator; because we don't > want both PETSc and the user doing MPI operations on the same communicator > (to prevent mixin

Re: [petsc-dev] building on Spock

2021-08-13 Thread Junchao Zhang
Yes, the two files are just petsc headers. --Junchao Zhang On Fri, Aug 13, 2021 at 5:17 PM Mark Adams wrote: > I seem to be getting Kokkos includes in my install but there is no kokkos > in the configure and I started with a clean PETSc arch directory and > install directory. Does

Re: [petsc-dev] Kokkos make error on Spock

2021-07-17 Thread Junchao Zhang
Mark, I can reproduce this error with PrgEnv-cray, i.e., using the Cray compiler (clang-11). Previously I used PrgEnv-gnu, which did not have this error. Probably it is a problem of Spock. But I am not sure. --Junchao Zhang On Sat, Jul 17, 2021 at 10:17 AM Mark Adams wrote: > And I can

Re: [petsc-dev] Kokkos make error on Spock

2021-07-16 Thread Junchao Zhang
zhang/petsc and PETSC_ARCH=arch-spock-cray-kokkos-dbg C/C++ example src/snes/tutorials/ex19 run successfully with 1 MPI process C/C++ example src/snes/tutorials/ex19 run successfully with 2 MPI processes C/C++ example src/snes/tutorials/ex3k run successfully with kokkos-kernels Fortran examp

Re: [petsc-dev] Kokkos make error on Spock

2021-07-16 Thread Junchao Zhang
is a makefile problem (I am fixing). If you do not directly build an executable from *.kokkos.cxx, then you can avoid this problem. For example, snes/tests/ex13 works with kokkos options on Spock. --Junchao Zhang On Fri, Jul 16, 2021 at 2:53 PM Mark Adams wrote: > Not complex. THis has some

Re: [petsc-dev] Kokkos make error on Spock

2021-07-16 Thread Junchao Zhang
Do you use complex? post your configure.log. --Junchao Zhang On Fri, Jul 16, 2021 at 9:47 AM Mark Adams wrote: > The simple Kokkos example is failing for me on Spock. > Any ideas? > Thanks, > > 10:44 main *= /gpfs/alpine/csc314/scratch/adams/petsc/src/snes/tutorials$ > ma

Re: [petsc-dev] VecGetArrayAndMemType

2021-06-23 Thread Junchao Zhang
Mark, I am not sure what your problem is. If it is a regression, can you bisect it? --Junchao Zhang On Wed, Jun 23, 2021 at 4:04 PM Mark Adams wrote: > I also tried commenting out the second VecView, so there is just one step > in the file, and the .h5 file is only 8 bytes smaller a

Re: [petsc-dev] VecGetArrayAndMemType

2021-06-23 Thread Junchao Zhang
Use VecGetArrayRead/Write() to get up-to-date host pointers to the vector array. --Junchao Zhang On Wed, Jun 23, 2021 at 9:15 AM Mark Adams wrote: > First, there seem to be two pages for VecGetArrayAndMemType (one has a > pointer to the other). > > So I need to get a CPU ar

Re: [petsc-dev] kokkos test fail in branch

2021-06-05 Thread Junchao Zhang
This problem was fixed in https://gitlab.com/petsc/petsc/-/merge_requests/4056, and is waiting for !3411 <https://gitlab.com/petsc/petsc/-/merge_requests/3411> :) --Junchao Zhang On Sat, Jun 5, 2021 at 9:42 PM Barry Smith wrote: > > Looks like the MPI libraries are not being p

Re: [petsc-dev] kokkos test fail in branch

2021-06-05 Thread Junchao Zhang
$rm ex3k $make ex3k and run again? --Junchao Zhang On Sat, Jun 5, 2021 at 10:25 AM Mark Adams wrote: > This is posted in Barry's MR, but I get this error with Kokkos-cuda on > Summit. Failing to open a shared lib. > Thoughts? > Mark > > 11:15 barry/2020-11-11/cle

Re: [petsc-dev] [petsc-users] ex5k.kokkos compile error

2021-06-03 Thread Junchao Zhang
-o ex5k --Junchao Zhang On Thu, Jun 3, 2021 at 8:32 AM Mark Adams wrote: > I am getting this error: > > 09:22 adams/landau-mass-opt= > /gpfs/alpine/csc314/scratch/adams/petsc/src/mat/tutorials$ make > PETSC_DIR=/gpfs/alpine/csc314/scratch/adams/petsc > PETSC_ARCH=arch-sum

Re: [petsc-dev] [petsc-users] strange segv

2021-05-29 Thread Junchao Zhang
try gcc/6.4.0 --Junchao Zhang On Sat, May 29, 2021 at 9:50 PM Mark Adams wrote: > And I grief using gcc-8.1.1 and get this error: > > /autofs/nccs-svm1_sw/summit/gcc/8.1.1/include/c++/8.1.1/type_traits(347): > error: identifier "__ieee128" is undefined > > Any ide

Re: [petsc-dev] VS Code debugger and PETSc

2021-05-29 Thread Junchao Zhang
I don't have. I think the main problem with petsc is one usually needs to debug with multiple MPI ranks. For light debug, I use gdb or tmpi <https://github.com/Azrael3000/tmpi>; for heavy debug, I use ddt on servers (need license). --Junchao Zhang On Fri, May 28, 2021 at 3:14 PM Aa

Re: [petsc-dev] Problem with the reorganization of complex with clang

2021-05-16 Thread Junchao Zhang
es of *constexpr.* Workarounds include: - define PETSC_SKIP_CXX_COMPLEX_FIX in the offending *.cxx file. - add CXXOPTFLAGS=-std=c++11 - update clang-6.o or gcc-4.8.5 (of 2015) on that machine. --Junchao Zhang On Fri, May 14, 2021 at 10:42 AM Satish Balay wrote: > You can login to:

Re: [petsc-dev] Problem with the reorganization of complex with clang

2021-05-14 Thread Junchao Zhang
Satish, how to access this machine? I want to know why complex is screwed up. --Junchao Zhang On Thu, May 13, 2021 at 7:08 PM Matthew Knepley wrote: > Nope. I will use your fix. > > Thanks, > > Matt > > On Thu, May 13, 2021 at 7:55 PM Matthew Knepley wrote: > &

Re: [petsc-dev] Compilation errors with kokkos and --with-scalar-type complex

2021-04-21 Thread Junchao Zhang
On Wed, Apr 21, 2021 at 5:23 AM Stefano Zampini wrote: > Incidentally, I found PETSc does not compile when configured using > > --with-scalar-type=complex --with-kokkos-dir= > --with-kokkos_kernels-dir=... > With cuda or not? > > Some fixes are trivial, others require some more thought. > >

Re: [petsc-dev] -with-kokkos-cuda-arch=AMPERE80 nonsense

2021-04-05 Thread Junchao Zhang
On Mon, Apr 5, 2021 at 7:33 PM Jeff Hammond wrote: > NVCC has supported multi-versioned "fat" binaries since I worked for > Argonne. Libraries should figure out what the oldest hardware they are > about is and then compile for everything from that point forward. Kepler > (3.5) is oldest version

Re: [petsc-dev] Possible SF bug

2021-04-01 Thread Junchao Zhang
get different SFs. The crashed one did 1) first and then 2). The 'good' one did 2) and then 1). But even the good one is wrong, since it gives an empty SF (thus not crashing the code). --Junchao Zhang On Tue, Mar 30, 2021 at 5:44 AM Matthew Knepley wrote: > On Mon, Mar 29, 2021

Re: [petsc-dev] Possible SF bug

2021-03-29 Thread Junchao Zhang
Matt, I can reproduce the error. Let me see what is wrong. Thanks. --Junchao Zhang On Mon, Mar 29, 2021 at 2:16 PM Matthew Knepley wrote: > Junchao, > > I have an SF problem, which I think is a caching bug, but it is hard to > see what is happening in the internals. I have

Re: [petsc-dev] configureLibrary fails for c++11 projects

2021-03-23 Thread Junchao Zhang
Can we combine CXXPPFLAGS and CXXFLAGS into one CXXFLAGS? --Junchao Zhang On Tue, Mar 23, 2021 at 11:38 AM Patrick Sanan wrote: > I had a related (I think) issue trying to build with Kokkos. Those headers > throw an #error if they're expecting OpenMP and the compiler doesn't h

Re: [petsc-dev] configureLibrary fails for c++11 projects

2021-03-23 Thread Junchao Zhang
I would rather directly change the project to use CXXFLAGS instead of CXXPPFLAGS. --Junchao Zhang On Tue, Mar 23, 2021 at 10:01 AM Satish Balay via petsc-dev < petsc-dev@mcs.anl.gov> wrote: > On Tue, 23 Mar 2021, Stefano Zampini wrote: > > > Just tried out of main, and and th

Re: [petsc-dev] Commit squashing in MR

2021-03-03 Thread Junchao Zhang
Oh, graph is an alias in my .gitconfig [alias] graph = log --graph --decorate --abbrev-commit --pretty=oneline --Junchao Zhang On Wed, Mar 3, 2021 at 1:51 PM Mark Adams wrote: > > > On Tue, Mar 2, 2021 at 10:02 PM Junchao Zhang > wrote: > >> I am a nai

Re: [petsc-dev] Commit squashing in MR

2021-03-02 Thread Junchao Zhang
y message aborts the commit. 4) Edit the commit message as you want, save and exit, done! --Junchao Zhang On Tue, Mar 2, 2021 at 6:19 PM Blaise A Bourdin wrote: > Hi, > > This is not technically a petsc question. > It would be great to have a short section in the PETSc integration

Re: [petsc-dev] Understanding Vecscatter with Kokkos Vecs

2021-02-19 Thread Junchao Zhang
. So, copying the indices from device to host and build a VecScatter there seems the easiest approach. The Kokkos-related functions are experimental. We need to decide whether they are good or not. --Junchao Zhang On Fri, Feb 19, 2021 at 4:32 AM Patrick Sanan wrote: > Thanks! That helps a

Re: [petsc-dev] Understanding Vecscatter with Kokkos Vecs

2021-02-18 Thread Junchao Zhang
On Thu, Feb 18, 2021 at 4:04 PM Fande Kong wrote: > > > On Thu, Feb 18, 2021 at 1:55 PM Junchao Zhang > wrote: > >> VecScatter (i.e., SF, the two are the same thing) setup (building various >> index lists, rank lists) is done on the CPU. is1, is2 must be host data. &

Re: [petsc-dev] Understanding Vecscatter with Kokkos Vecs

2021-02-18 Thread Junchao Zhang
VecScatter (i.e., SF, the two are the same thing) setup (building various index lists, rank lists) is done on the CPU. is1, is2 must be host data. When the SF is used to communicate device data, indices are copied to the device.. --Junchao Zhang On Thu, Feb 18, 2021 at 11:50 AM Patrick Sanan

Re: [petsc-dev] aijkokkos solvers

2020-12-24 Thread Junchao Zhang
When is the deadline of your SC paper? --Junchao Zhang On Thu, Dec 24, 2020 at 6:44 PM Mark Adams wrote: > It does not look like aijkokkos is equipped with solves the way > aijcusparse is. > > I would like to get a GPU direct solver for an SC paper on the Landau > stuff with

Re: [petsc-dev] Building PETSc on LLNL Lassen

2020-12-13 Thread Junchao Zhang
ng thrust complex (see MR 2822) self.setCompilers.CUDAFLAGS += ' -std=' + self.compilers.cxxdialect.lower() In your configure.log, there are #define PETSC_HAVE_CXX_DIALECT_CXX11 1 #define PETSC_HAVE_CXX_DIALECT_CXX14 1 I guess without -ccbin, nvcc uses gcc by default and your gcc does not suppo

Re: [petsc-dev] cusparse error

2020-12-09 Thread Junchao Zhang
Could be GPU resource competition. Note this test uses nsize=8. --Junchao Zhang On Wed, Dec 9, 2020 at 7:15 PM Mark Adams wrote: > And this is a Cuda 11 complex build: > https://gitlab.com/petsc/petsc/-/jobs/901108135 > > On Wed, Dec 9, 2020 at 8:11 PM Mark Adams wrote: &

Re: [petsc-dev] Job openings

2020-11-20 Thread Junchao Zhang
I think we can just send to both petsc-announce and petsc-users. First there are not many such emails. Second, if there are, users should be happy to see that. I receive 10+ ad emails daily and I don't mind receiving extra 5 emails monthly :) --Junchao Zhang On Fri, Nov 20, 2020 at 7:

Re: [petsc-dev] Job openings

2020-11-20 Thread Junchao Zhang
website later when they are finding jobs. --Junchao Zhang On Fri, Nov 20, 2020 at 1:04 PM Matthew Knepley wrote: > That is a good idea. Anyone against this? > > Thanks, > > Matt > > On Fri, Nov 20, 2020 at 1:26 PM Barry Smith wrote: > >> >> Maybe so

Re: [petsc-dev] [petsc-users] new book introducing PETSc for PDEs

2020-10-30 Thread Junchao Zhang
Ed, I agree with all what you said. My thought is we don't need to add each of your examples into corresponding src/XX/tutorials/. Your repo can be a standalone directory and we just need PETSc CI to be able to run them. --Junchao Zhang On Fri, Oct 30, 2020 at 9:00 PM Ed Bueler

Re: [petsc-dev] [petsc-users] new book introducing PETSc for PDEs

2020-10-30 Thread Junchao Zhang
Prof. Ed Bueler, Congratulations on your book. I am eager to read it. I was wondering if it is feasible to add your example programs to PETSc tests so that readers will always be able to run your code. --Junchao Zhang On Thu, Oct 29, 2020 at 8:29 PM Ed Bueler wrote: > All -- >

Re: [petsc-dev] Kokkos initialize

2020-10-16 Thread Junchao Zhang
Let me have a look. cupminit.inc is a template for CUDA and HIP. It is OK if you see some symbols twice. --Junchao Zhang On Fri, Oct 16, 2020 at 8:22 AM Mark Adams wrote: > Junchao, I see this in cupminit.inc (twice) > > #if defined(PETSC_HAVE_KOKKOS) &

Re: [petsc-dev] Kokkos error on SUMMIT

2020-10-02 Thread Junchao Zhang
On Fri, Oct 2, 2020 at 3:02 PM Junchao Zhang wrote: > > > On Fri, Oct 2, 2020 at 2:59 PM Mark Adams wrote: > >> >> >> On Fri, Oct 2, 2020 at 3:15 PM Barry Smith wrote: >> >>> >>> Mark, >>> >>> Looks like you are b

Re: [petsc-dev] Kokkos error on SUMMIT

2020-10-02 Thread Junchao Zhang
On Fri, Oct 2, 2020 at 2:59 PM Mark Adams wrote: > > > On Fri, Oct 2, 2020 at 3:15 PM Barry Smith wrote: > >> >> Mark, >> >> Looks like you are building Kokkos without CUDA. > > > Yes. This is a CPU build of Kokkos. > > >> You don't have --with-cuda on configure line that is used by Kokkos t

Re: [petsc-dev] CI format failure

2020-09-24 Thread Junchao Zhang
It is better the tool can also print out line and column numbers and reasons why it is wrong. --Junchao Zhang On Thu, Sep 24, 2020 at 11:16 AM Satish Balay via petsc-dev < petsc-dev@mcs.anl.gov> wrote: > The relevant part: > > No space after i

Re: [petsc-dev] MPI derived datatype use in PETSc

2020-09-23 Thread Junchao Zhang
can benefit from derived data types is in DMDA. The ghost points can be described with MPI_Type_vector(). We can save the packing/unpacking and associated buffers. --Junchao Zhang On Wed, Sep 23, 2020 at 12:30 PM Victor Eijkhout wrote: > The Ohio mvapich people are working on getting bet

Re: [petsc-dev] Question about MPICH device we use

2020-07-23 Thread Junchao Zhang
On Thu, Jul 23, 2020 at 11:35 PM Satish Balay via petsc-dev < petsc-dev@mcs.anl.gov> wrote: > On Thu, 23 Jul 2020, Jeff Hammond wrote: > > > Open-MPI refuses to let users over subscribe without an extra flag to > > mpirun. > > Yes - and when using this flag - it lets the run through - but there is

Re: [petsc-dev] How do I see the gcov results?

2020-06-25 Thread Junchao Zhang
No. That is the plan. Petsc's script gcov.py works correctly and we need to move it to codecov.io. --Junchao Zhang On Thu, Jun 25, 2020 at 9:34 AM Aagaard, Brad T via petsc-dev < petsc-dev@mcs.anl.gov> wrote: > Are you opposed to using codecov.io to compile the results and ge

Re: [petsc-dev] Prediscusion of appropriate communication tool for discussion of PETSc 4 aka the Grand Refactorization

2020-06-18 Thread Junchao Zhang
A dedicated mailing list has all these functionalities and is easier to see discussion threads. --Junchao Zhang On Thu, Jun 18, 2020 at 9:27 PM Barry Smith wrote: > >I'd like to start a discussion of PETSc 4.0 aka the Grand > Refactorization but to have that discussion we n

Re: [petsc-dev] https://developer.nvidia.com/nccl

2020-06-16 Thread Junchao Zhang
It should be renamed as NCL (NVIDIA Communications Library) as it adds point-to-point, in addition to collectives. I am not sure whether to implement it in petsc as none exscale machine uses nvidia GPUs. --Junchao Zhang On Tue, Jun 16, 2020 at 6:44 PM Matthew Knepley wrote: > It would seem

Re: [petsc-dev] Preferred Windows Installation

2020-06-15 Thread Junchao Zhang
On Mon, Jun 15, 2020 at 8:33 PM Jacob Faibussowitsch wrote: > And if one needs windows native/libraries - then dealing with windows and > its quirks is unavoidable. > > WSL2 allows you to run windows binaries natively inside WSL I believe > https://docs.microsoft.com/en-us/windows/wsl/interop#run

Re: [petsc-dev] Configure Downloads Wrong MUMPS

2020-06-06 Thread Junchao Zhang
In mumps.py, change self.version = '5.3.1' to self.minversion = '5.2.1' If we support older mumps, we can even lower the minverison. --Junchao Zhang On Sat, Jun 6, 2020 at 3:16 PM Jacob Faibussowitsch wrote: > Hello All, > > As the title suggest configure downloa

Re: [petsc-dev] Valgrind MPI-Related Errors

2020-06-02 Thread Junchao Zhang
I guess Jacob already used MPICH, since MPIDI_CH3_EagerContigShortSend() is from MPICH. --Junchao Zhang On Tue, Jun 2, 2020 at 9:38 AM Satish Balay via petsc-dev < petsc-dev@mcs.anl.gov> wrote: > use --download-mpich for valgrind. > > https://www.mcs.anl.gov/petsc/documen

Re: [petsc-dev] Should PetscSignalHandlerDefault avoid calling MPI_Abort?

2020-05-06 Thread Junchao Zhang
it can solve the problem you reported (actually happened). --Junchao Zhang On Wed, May 6, 2020 at 10:22 AM John Peterson wrote: > Hi Junchao, > > I was just wondering if there was any update on this? I saw your question > on the discuss@mpich thread, but I gather you have no

Re: [petsc-dev] Should PetscSignalHandlerDefault avoid calling MPI_Abort?

2020-04-21 Thread Junchao Zhang
I don't see problems calling _exit in PetscSignalHandlerDefault. Let me try it first. --Junchao Zhang On Tue, Apr 21, 2020 at 3:17 PM John Peterson wrote: > Hi, > > I started a thread on disc...@mpich.org regarding some hanging canceled > jobs that we were seeing: > >

Re: [petsc-dev] CUDA + OMP make error

2020-04-13 Thread Junchao Zhang
Probably matrix assembly on GPU is more important. Do you have an example for me to play to see what GPU interface we should have? --Junchao Zhang On Mon, Apr 13, 2020 at 5:44 PM Mark Adams wrote: > I was looking into assembling matrices with threads. I have a coloring to > avoid con

Re: [petsc-dev] CUDA + OMP make error

2020-04-13 Thread Junchao Zhang
e_requests/2714 that should fix your original compilation errors. --Junchao Zhang On Mon, Apr 13, 2020 at 2:07 PM Mark Adams wrote: > https://www.mcs.anl.gov/petsc/miscellaneous/petscthreads.html > > and I see this on my Mac: > > 14:23 1 mark/feature-xgc-interface-rebase *= ~/Code

Re: [petsc-dev] CUDA + OMP make error

2020-04-13 Thread Junchao Zhang
ts on the idea of letting users keep logging with openmp? >> >> On Mon, Apr 13, 2020 at 11:40 AM Junchao Zhang >> wrote: >> >>> Yes. Looks we need to include petsclog.h. Don't know why OMP >>> triggered the error. >>> --Junchao Zhang >>> >>> >>> On Mon, Apr 13, 2020 at 9:59 AM Mark Adams wrote: >>> >>>> Should I do an MR to fix this? >>>> >>>

Re: [petsc-dev] CUDA + OMP make error

2020-04-13 Thread Junchao Zhang
Yes. Looks we need to include petsclog.h. Don't know why OMP triggered the error. --Junchao Zhang On Mon, Apr 13, 2020 at 9:59 AM Mark Adams wrote: > Should I do an MR to fix this? >

Re: [petsc-dev] Thank you!

2020-04-10 Thread Junchao Zhang
Ali, Congratulations to your paper, thanks to Barry's PCVPBJACOBI. --Junchao Zhang On Thu, Apr 9, 2020 at 6:12 PM Ali Reza Khaz'ali wrote: > Dear PETSc team, > > > > I just want to thank you for implementing the PCVPBJACOBI into the PETSc > library, which I use

  1   2   >