Re: memory leak reported by totalview on some platforms



Arjen Markus wrote:
On 26 mrt, 02:02, Fei Liu <fei....@xxxxxxxxx> wrote:
In this case, it's a fresh automatic object as in the case of the
original code.

Fei- Tekst uit oorspronkelijk bericht niet weergeven -

- Tekst uit oorspronkelijk bericht weergeven -

I am not familiar with Totalview (I know of it, that is
all), but could it be that you are using a F90 compiler
rather than a F95 compiler, as the status of an
uninitialised pointer in F90 is undefined. Totalview
could then see some random memory being associated with
the basep pointer.

One solution you might try: initialise the basep component
in the type definition.

type compos
type(base), pointer :: basep => null()
integer :: id
end type

and similarly in type base.

Regards,

Arjen

I think this is a reasonable solution. Thanks,

Fei
.



Relevant Pages

  • Re: Jump ends nowhere?!
    ... it would load al sectors of this code... ... it jumps to is more than 2048 bytes away. ... information from 001.- Tekst uit oorspronkelijk bericht niet weergeven - ...
    (alt.lang.asm)
  • Re: Jump ends nowhere?!
    ... it jumps to is more than 2048 bytes away. ... information from 001.- Tekst uit oorspronkelijk bericht niet weergeven - ...
    (alt.lang.asm)
  • Re: Building my own class library framework
    ... visual studio solution file; then it finds out the visual studio ... Pascal- Tekst uit oorspronkelijk bericht niet weergeven - ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Jump ends nowhere?!
    ... it jumps to is more than 2048 bytes away. ... information from 001.- Tekst uit oorspronkelijk bericht niet weergeven - ...
    (alt.lang.asm)
  • Re: O.T. Bigfoot corpse to be shown friday
    ... Bigfoot corpse, to be shown, and to the newsmedia, tomm. ... So logically their bodies dissipate on death.Common sense.- Tekst uit oorspronkelijk bericht niet weergeven - ...
    (rec.martial-arts)