Using the Find Function dialog below, you can search for allocations occurring in certain functions.
The functions can be the allocating function or anywhere in the allocation callstack
This feature is very similar in behaviour to finding objects.
To show the Find Function dialog, choose the menu option below:
Or use the following icon on the Query Toolbar.
Enter a function name, and optionally any other search characteristics to find objects allocated in matching functions
•Function enter full or partial function name
•Match case tick to do a case-sensitive match
•Complete function name tick to only match the whole name
For C++ methods, complete names must be of the form classname::methodname.
•Trace locations matches only the function containing the allocation
•Callstacks matches any function in the allocation callstack
As well as allocations you can search for reallocation and/or deallocation events:
•Allocated search for allocations
•Reallocated search for reallocations
•Deallocated search for deallocation events
•Find performs the search displaying results in the list
Results replace any previous search, unlike querying addresses or objects where the results are added to the list.
You can expand the search results, and double click the data items to edit source code in your preferred editor.
Memory Validator has an example program you can use to safely explore features.
In the example program, the Allocation menu has an option Test Many Hooks at once.
After doing that, the example searches can be made below.
Searching only within matching functions
Searching for allocations only in functions that have ontest as part of their name finds these results in CTeststakView::OnTestManyHooks
Searching anywhere in the callstack
Keeping the same function name but now searching in any part of the callstack additionally finds two more allocations in functions underneath CTeststakView::OnTestManyHooks