[petsc-users] Help with PETSc signal handling

Gard Spreemann gspr at nonempty.org
Tue Nov 7 06:47:54 CST 2017


On Tuesday 7 November 2017 07:35:36 CET Mark Adams wrote:
> PETSc's signal handler is for segvs, etc. I don't know the details but I
> don't think we care about external signals.

I see. I'll sketch what I'm trying to achieve in case someone can
think of another approach.

I have some long-running SLEPc eigenvalue computations, and I'd like
to have SLURM signal my program that its time limit is drawing
near. In that case, my problem would set a flag and before the next
iteration of the SLEPc eigenvalue solver it would give up and save the
eigenvalues it has so far managed to obtain.

The only workaround I can think of would be to let my program keep
track of its time limit on its own and check it at each iteration.

There is no intention for PETSc to have handling of user-defined
signals?


Thanks.

 -- Gard




More information about the petsc-users mailing list