[petsc-dev] XXXGetContext() in Fortran

Jed Brown jedbrown at mcs.anl.gov
Tue Nov 8 20:57:05 CST 2011


We have bindings for this, but I can't find a way to make it work. I can
pass a context into a function, but I can't get one back out with a
subroutine call. F90 pointers are grotesque creatures that don't seem to be
up to this task either, at least not with any chance of portability.

Is there anything we can do to avoid common blocks without losing all hope
of portability? How does anyone use this sorry excuse for a language?

Note that having the context passed in as an argument isn't feasible for
PCShell and MatShell, so it's nigh impossible to use these objects with
multigrid (or any other case where you have multiple instances of shell
objects, breaking the common blocks.)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20111108/b3a7450d/attachment.html>


More information about the petsc-dev mailing list