[petsc-dev] problem with TSIRM in PETSc

Barry Smith bsmith at mcs.anl.gov
Mon Nov 14 13:33:25 CST 2016


> On Nov 14, 2016, at 10:53 AM, Raphaël Couturier <raphael.couturier at univ-fcomte.fr> wrote:
> 
> This version is the correct version 
> https://bitbucket.org/petsc/petsc/history-node/1f2c6fc4275e/src/ksp/ksp/impls/tsirm/tsirm.c?at=master
> 
> The petsc-3.7.4.tar.gz is different. Line 68 there is a, for example:
>   ierr = PetscMalloc(tsirm->Iend-tsirm->Istart,&ind_row);CHKERRQ(ierr);

   This is incorrect. And will result in memory corruption, the one below is correct.
> 
> 
> In the bitbucket version Line 64 it is 
>   ierr = PetscMalloc1(tsirm->Iend-tsirm->Istart,&ind_row);CHKERRQ(ierr);
> 
> 
> There are other differences

   Likely we found these bugs and fixed them in master but not in maint.

   Barry

> 
> So we wonder whether it is normal or not.
> Thank you
> 
> Raphaël
>> And you an see the history of the tsirm.c file (in the master branch)
>> on bitbucket, which might make that easier:
>> 
>> https://bitbucket.org/petsc/petsc/history-node/1f2c6fc4275e/src/ksp/ksp/impls/tsirm/tsirm.c?at=master
>> 
>> 
>> 
>> On Mon, Nov 14, 2016 at 5:31 PM, Matthew Knepley 
>> <knepley at gmail.com>
>>  wrote:
>> 
>>> On Mon, Nov 14, 2016 at 2:29 AM, Raphaël Couturier
>>> 
>>> <raphael.couturier at univ-fcomte.fr>
>>>  wrote:
>>> 
>>>> Hello all,
>>>> 
>>>> We have submitted a code for TSIRM a new method to solve linear systems in
>>>> PETSc, approximately one year ago, and we have a question. The code is
>>>> different between the petsc version in bitbucket and in the last PETSc
>>>> archive. In fact everything is working fine in the petsc version but not in
>>>> the petsc-3.7.4. When we submitted the first version, it seemed that
>>>> everything was fine for this part of the code. What could we do? Resubmit a
>>>> new version? Wait the next PETSc release?
>>>> 
>>> It would really help if you could give the SHA1 for the two versions you are
>>> talking about.
>>> 
>>>   Thanks,
>>> 
>>>      Matt
>>> 
>>>> Thank you in advance for your answer.
>>>> 
>>>> Raphaël
>>>> 
>>> 
>>> 
>>> 
>>> --
>>> 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
>>> 
> 




More information about the petsc-dev mailing list