[petsc-dev] VecGetArrayAndMemType

Matthew Knepley knepley at gmail.com
Wed Jun 23 09:47:07 CDT 2021


On Wed, Jun 23, 2021 at 10:44 AM Junchao Zhang <junchao.zhang at gmail.com>
wrote:

> Use VecGetArrayRead/Write() to get up-to-date host pointers to the vector
> array.
>

I think Mark is saying that those are not working. We do call
VecGetArrayRead() in the HDF5 code.

Mark, it seem like a small broken code is necessary.

  Thanks,

    Matt


> --Junchao Zhang
>
>
> On Wed, Jun 23, 2021 at 9:15 AM Mark Adams <mfadams at lbl.gov> wrote:
>
>> First, there seem to be two pages for VecGetArrayAndMemType (one has a
>> pointer to the other).
>>
>> So I need to get a CPU array for HDF5 viewing. Totally broken for devices.
>>
>> I don't find a VecGetArrayCpu[HOST] that does the right thing.
>>
>> Perhaps have VecGetArrayAndMemType return a valid CPU pointer when
>> "mtype==NULL"?
>>
>> Mark
>>
>

-- 
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener

https://www.cse.buffalo.edu/~knepley/ <http://www.cse.buffalo.edu/~knepley/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20210623/665402d4/attachment.html>


More information about the petsc-dev mailing list