MPIX_Delete_error_class(3)

πŸ“¦
version 4.0.2 Β· 2 versions
, in debian bookworm

πŸ’– MPIX_Delete_error_class πŸ’–

okay bestie, welcome to the MPI manual, section 3, and today's main character is MPIX_Delete_error_class β€” she deletes an MPI error class from the known classes. that's it, that's the gig. ✨


🌸 NAME 🌸

MPIX_Delete_error_class β€” delete an MPI error class from the known classes πŸ—‘οΈπŸ’…


πŸŽ€ SYNOPSIS πŸŽ€

int MPIX_Delete_error_class(int errorclass)

πŸ¦‹ INPUT PARAMETERS πŸ¦‹

  • errorclass β€” the value of the error class to be remoed (integer). yes girl, "remoed" β€” that's literally what the manpage says, i'm not fixing it, it's canon now πŸ™ˆ. it's an integer, that's the important part.

πŸ”₯ THREAD AND INTERRUPT SAFETY πŸ”₯

this routine is thread-safe, no cap. that means multiple threads can use it at the same time and nobody has to bring their own user-provided thread locks. she's secure, she's independent, she doesn't need you 🫢

but β€” and this is the plot twist β€” the routine is not interrupt safe. typically this is because of memory allocation routines like malloc or other non-MPICH runtime routines that are themselves not interrupt-safe. so like, thread-safe yes, interrupt-safe no. it's giving "i can multitask but do NOT jump-scare me" 😭


🌈 NOTES FOR FORTRAN 🌈

so every single MPI routine in Fortran (except MPI_WTIME and MPI_WTICK, the two little rebels) gets an extra argument called ierr tacked onto the end of the argument list. ierr is an integer and it means exactly the same thing as the return value of the routine in C. periodt.

in Fortran, MPI routines are subroutines, and you invoke them with the call statement.

also, all MPI objects (like MPI_Datatype, MPI_Comm) are of type INTEGER in Fortran. yes, all of them. that's just the vibe over there πŸ’œ


πŸ‘‘ ERRORS πŸ‘‘

okay so literally all MPI routines (except MPI_Wtime and MPI_Wtick) return an error value. C routines hand it back as the value of the function, and Fortran routines put it in that last argument we just talked about.

before that value comes back to you, the current MPI error handler gets called. and by default? bestie, the default error handler aborts the MPI job. like, full shutdown, everybody out πŸ’€.

the error handler can be changed with:

  • MPI_Comm_set_errhandler β€” for communicators
  • MPI_File_set_errhandler β€” for files
  • MPI_Win_set_errhandler β€” for RMA windows

and there's the MPI-1 routine MPI_Errhandler_set, which you may use, but heads up β€” its use is deprecated. don't be that girl.

the predefined error handler MPI_ERRORS_RETURN may be used to cause error values to be returned instead of the whole thing going boom.

note that MPI does not guarantee that an MPI program can continue past an error. however, MPI implementations will attempt to continue whenever possible. so like, sometimes you survive, sometimes you don't, and that's just the risk you take πŸ’…

now, the actual error values:

  • MPI_SUCCESS β€” no error; MPI routine completed successfully. ate. πŸŽ‰
  • MPI_ERR_OTHER β€” other error; use MPI_Error_string to get more information about this error code. go ask her, she knows πŸ™

and that's the whole page, bestie β€” this was MPIX_Delete_error_class(3) from the MPI manual, dated 2/22/2022. she said delete that error class and slay, and honestly? iconic behavior. bye bye, error class πŸ’–βœ¨πŸ¦‹

πŸ“¦ where this page comes from