Method and apparatus for determining memory leakage position

A memory leak and dynamic memory technology, applied in the computer field, can solve problems such as low code location efficiency

Active Publication Date: 2017-07-07
HUAWEI TECH CO LTD
View PDF4 Cites 21 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0005] Based on the above processing method, the recorded function may appear multiple times in the entire program, and technicians need to search for many code locations, so the efficiency of finding memory leak code locations is low

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method and apparatus for determining memory leakage position
  • Method and apparatus for determining memory leakage position
  • Method and apparatus for determining memory leakage position

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0107] In order to make the object, technical solution and advantages of the present invention clearer, the implementation manner of the present invention will be further described in detail below in conjunction with the accompanying drawings.

[0108] An embodiment of the present invention provides a method for determining the location of a memory leak, and the execution subject of the method is a computing device. Wherein, the computing device may be a personal computer (personal computer, PC), or a server.

[0109] The computing device may include a processor 110 and a memory 120, and the processor 110 may be connected to the memory 120, such as figure 1 shown. The processor 110 may be the control center of the computing device, connect various parts of the computing device with various interfaces and lines, run or execute software programs and / or modules stored in the memory 120, and call data stored in the memory 120 , execute various functions of the computing device a...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention discloses a method and an apparatus for determining a memory leakage position, and belongs to the technical field of computers. The method comprises the steps of obtaining a memory address applied through a dynamic memory application function when it is detected that the dynamic memory application function is called in a process of executing a target program, obtaining a call relation of current upper call functions of the dynamic memory application function, and in a memory occupation database, recording a corresponding relationship between the memory address and the call relation; and according to the recorded call relation, determining the memory leakage position. By adopting the method and the apparatus, the efficiency of searching for code positions of memory leakage can be improved.

Description

technical field [0001] The invention relates to the technical field of computers, in particular to a method and a device for determining the location of a memory leak. Background technique [0002] For applications that do not know how much memory space to apply for in advance, they will dynamically apply for memory at runtime. When the memory is used up, the dynamically applied memory should be released. The application memory is not released in time after the memory is used up, resulting in the memory being occupied all the time. [0003] Technicians can instrument applications. In the prior art, the method for detecting whether the application program has a memory leak is to record the function that calls the dynamic memory application function during the running of the application program. For example, when the function a calls the dynamic memory application function, the application program will record a Functions and their corresponding requested memory. After the a...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): G06F11/36
CPCG06F11/3636
Inventor 刘剑青张林邱亚平朱宏泽
Owner HUAWEI TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products