← Back to team overview

yade-dev team mailing list archive

Re: shared_ptr<PhysicalAction>

 

>>> memset(action[0],0,sizeof(thisAction)) and perhaps would save some
>>> shared_ptr overhead we have currently. V.
>>>       
>> feel free to experiment.
>>     
>
> you could try memset(.....get(),0,sizeof(thisAction)); maybe?
>   
My mistake, I wanted to write
memset(action[0],0,sizeof(thisAction)*numberOfBodies), that would reset
the whole array at once, which was the point. What you suggest wouldn't
be any faster thatn the current was, I think, except the reset() call
overhead. V.




Follow ups

References