Search found 1012 matches

by Andreas Suurkuusk
Wed Jan 16, 2019 6:08 pm
Forum: Using .NET Memory Profiler
Topic: Can't do the same operation when opened with .NET Memory Profiler.
Replies: 1
Views: 70

Re: Can't do the same operation when opened with .NET Memory Profiler.

Running an application under the profiler will increase the memory usage of the application and affect the performance. Other than that the application should function the same as when running without the profiler. What options are enabled when you profile the application? Did you enable the native ...
by Andreas Suurkuusk
Thu Dec 20, 2018 5:38 pm
Forum: Using .NET Memory Profiler
Topic: API: write dump/session to disk?
Replies: 4
Views: 647

Re: API: write dump/session to disk?

Yes, it is normally recommended to collect more than one snapshot. This way you can more easily identify memory usage trends, e.g. see if there are types with additional instances in each new snapshot. With instance tracking enabled, you will also see the specific instances that are new in each snap...
by Andreas Suurkuusk
Mon Oct 15, 2018 9:48 am
Forum: Using .NET Memory Profiler
Topic: API: write dump/session to disk?
Replies: 4
Views: 647

Re: API: write dump/session to disk?

Yes, you are correct. The profiler API is intended to control the profiler from within the profiled process, it cannot be used to initiate profiling by itself. There's an external API that can be used, but this API requires the full profiler to be installed on the machine which I assume will not wor...
by Andreas Suurkuusk
Fri Oct 05, 2018 2:22 pm
Forum: Using .NET Memory Profiler
Topic: No .NET runtime found in the process
Replies: 3
Views: 648

Re: No .NET runtime found in the process

Thanks for the update. It is true that you get a 64-bit memory dump of a 32-bit process if you use the Task manager. However, this is something that should be handled correctly by .NET Memory Profiler. We will look into this and see if we can find some problems with the detection of 32-bit processes.
by Andreas Suurkuusk
Fri Oct 05, 2018 12:37 pm
Forum: Using .NET Memory Profiler
Topic: No .NET runtime found in the process
Replies: 3
Views: 648

Re: No .NET runtime found in the process

Is the memory dump file you try to import a full memory dump file? (I.e. including all user mode data?) .NET Memory Profiler cannot include a memory dump that only includes partial information, e.g. call stacks. If you have a full memory dump, then this is something we would like to investigate furt...
by Andreas Suurkuusk
Thu Sep 20, 2018 8:38 pm
Forum: Using .NET Memory Profiler
Topic: Waiting for .Net runtime to be loaded
Replies: 1
Views: 578

Re: Waiting for .Net runtime to be loaded

The "Waiting for .NET runtime to be loaded' message should disappear as soon as the profiler has detected any .NET runtime in the profiled process. If a .NET runtime cannot be detected, then either the process has not loaded a runtime, there's a problem with the installation, or there's a problem/bu...
by Andreas Suurkuusk
Wed Aug 22, 2018 10:53 am
Forum: General
Topic: I cannot install the memory profiler
Replies: 1
Views: 11004

Re: I cannot install the memory profiler

The error code 0x80070652 is defined as ERROR_INSTALL_ALREADY_RUNNING, which indicate that your failed installation is caused by another installation somehow. I recommend that you restart your computer and check that you don't have any pending Windows Update installs, or some other pending installs....
by Andreas Suurkuusk
Thu Aug 09, 2018 2:30 pm
Forum: Using .NET Memory Profiler
Topic: Help on duplicate instances
Replies: 1
Views: 780

Re: Help on duplicate instances

Two instances are duplicates if the data reachable from each instance is identical. For double arrays, this means that they are the same length and contain exactly the sames values. If you create two arrays using the code below, then you will have two separate double array instances, but they will c...
by Andreas Suurkuusk
Mon Aug 06, 2018 3:02 pm
Forum: Using .NET Memory Profiler
Topic: Value types memory summary
Replies: 5
Views: 1193

Re: Value types memory summary

Now I have written an example that extracts value type usage information from a session. It was a little bit more complicated than I expected. You will find the sample code below. To compile the code, you need to add a reference to the "SciTech.NetMemProfiler.Core" assembly, which you will find in t...
by Andreas Suurkuusk
Wed Aug 01, 2018 6:42 am
Forum: Using .NET Memory Profiler
Topic: Value types memory summary
Replies: 5
Views: 1193

Re: Value types memory summary

OK, now I understand this requirement better. I will write an example program that extracts this information from a session file. I will post it as a reply to this topic, but it may be a few days before I get the time to write the program.
by Andreas Suurkuusk
Thu Jul 26, 2018 3:51 pm
Forum: Using .NET Memory Profiler
Topic: Garbage Collection in Memory Profiler ?
Replies: 3
Views: 1056

Re: Garbage Collection in Memory Profiler ?

You can use the "Collect gen #0" command when you use the wizard, but I would not recommend it. Since the wizard is used to find memory leaks and help you identify instances that should have been GCed, it makes sense to allow the profiler to clean up as many instances as possible (to avoid false pos...
by Andreas Suurkuusk
Mon Jul 23, 2018 11:57 am
Forum: Using .NET Memory Profiler
Topic: Value types memory summary
Replies: 5
Views: 1193

Re: Value types memory summary

No, there's no functionality to present the number of bytes used by value types within other classes. The profiler will only present information about boxed value type instances. It would be fairly easy to retrieve this information from a snapshot, but I don't know how it would be presented in a goo...
by Andreas Suurkuusk
Tue Jun 12, 2018 11:52 am
Forum: Using .NET Memory Profiler
Topic: Memory Profiler API
Replies: 5
Views: 1176

Re: Memory Profiler API

It is not possible to retrieve the process id when starting the profiler as a separate process, but another option is to use the external profiler API to start the profiled process. Unfortunately, this API is the same API as the profiler itself uses and it may not be stable between versions. In part...
by Andreas Suurkuusk
Mon Jun 11, 2018 12:31 pm
Forum: Using .NET Memory Profiler
Topic: Memory Profiler API
Replies: 5
Views: 1176

Re: Memory Profiler API

What process id are you looking for? The API is used within the profiled process, so the process id of this process can be retrieved using Process.GetCurrentProcess().Id. Are you profiling multiple processes? There are some minor differences between NmpCore and NetMemProfiler(Console),e..g. WPF clea...
by Andreas Suurkuusk
Thu Jun 07, 2018 8:36 pm
Forum: Using .NET Memory Profiler
Topic: Memory Profiler API
Replies: 5
Views: 1176

Re: Memory Profiler API

Currently the .NET Memory Profiler API is not available when you attach to a process (the MemProfiler.IsProfiling property will return false as you noticed). When attaching to a process, the profiler will not get notifications about allocations and can therefore not provide information about the nu...