[petsc-users] Using ViennaCL without recompiling

Karl Rupp rupp at iue.tuwien.ac.at
Sat Apr 29 14:44:27 CDT 2017


Hi Franco,

yes, in principle you can substitute your current PETSc build with your 
custom PETSc build (with ViennaCL enabled) at link time, provided that 
the version numbers match.

Just to be clear: There is no way around recompiling PETSc, though; 
there's no mechanism for dynamically loading some other shared library 
to enable ViennaCL bindings in PETSc.

Best regards,
Karli


On 04/29/2017 08:14 AM, Franco Milicchio wrote:
>
>> On Apr 28, 2017, at 4:46pm, Satish Balay <balay at mcs.anl.gov
>> <mailto:balay at mcs.anl.gov>> wrote:
>>
>> On Fri, 28 Apr 2017, Franco Milicchio wrote:
>>
>>>
>>>> Not recompiling your own project is fine. PETSc has an ABI. You just
>>>> reconfigure/recompile PETSc with
>>>> ViennaCL support. Then you can use -mat_type viennacl etc.
>>>
>>> Thanks for your answer, Matt, but I expressed myself in an ambiguous way.
>>>
>>> I cannot recompile PETSc, I can do whatever I want with my code.
>>
>> You can always install PETSc.
>>
>> If you don't have write permission to the install you are currently
>> using - you can start with a fresh tarball [of the same version], use
>> reconfigure*.py from the current install to configure - and install
>> your own copy [obviously at a different location.
>
> Thanks, Satish.
>
> As I understand, you are suggesting to just substitute PETSc at linking
> level with my ViennaCL-enabled library, and it should work “flawlessly”?
> (the milage may vary, obviously)
>
> This would be a huge gain to the project.
>
> Thanks,
> Franco
> /fm
>
> --
> Franco Milicchio <fmilicchio at me.com <mailto:fmilicchio at me.com>>
>
> Department of Engineering
> University Roma Tre
> https://fmilicchio.bitbucket.io/
>


More information about the petsc-users mailing list