Application memory leakage detection method and device, electronic equipment and storage medium

An application and memory leak technology, applied in the field of memory management, can solve problems such as unusable areas, system freezes, application crashes, etc., to reduce memory consumption, improve experience, and improve efficiency and accuracy.

Pending Publication Date: 2019-04-02
CHINA PING AN LIFE INSURANCE CO LTD
View PDF8 Cites 20 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

Memory leak refers to those resources that have been used but are no longer used, but this part of memory has not been released in time, and this part of resources has always existed in memory, and this area can neither be used nor released
Since this piece of memory has been occupied and ca

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
  • Application memory leakage detection method and device, electronic equipment and storage medium
  • Application memory leakage detection method and device, electronic equipment and storage medium
  • Application memory leakage detection method and device, electronic equipment and storage medium

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0054] figure 1 It is a flow chart of the application program memory leak detection method provided by Embodiment 1 of the present invention.

[0055] In this embodiment, the application program memory leak detection method can be applied to electronic devices with display functions or fixed electronic devices, and the electronic devices are not limited to personal computers, smart phones, tablet computers, cameras installed with desktop or all-in-one, etc.

[0056] The application program memory leak detection method can also be applied to a hardware environment composed of electronic equipment and a server connected to the electronic equipment through a network. Networks include, but are not limited to: Wide Area Networks, Metropolitan Area Networks, or Local Area Networks. The application program memory leak detection method in the embodiment of the present invention may be executed by a server, may also be executed by an electronic device, and may also be executed jointl...

Embodiment 2

[0115] refer to figure 2 Shown is a functional block diagram of a preferred embodiment of the application program memory leak detection device of the present invention.

[0116] In some embodiments, the application program memory leak detection apparatus 20 runs in an electronic device. The application program memory leak detection device 20 may include a plurality of functional modules composed of program code segments. The program codes of each program segment in the application program memory leak detection device 20 can be stored in the memory of the electronic device, and executed by the at least one processor to execute (see for details figure 1 Description) detection of application memory leaks.

[0117] In this embodiment, the application program memory leak detection device 20 can be divided into multiple functional modules according to the functions it performs. The functional modules may include: a creation module 201 , a monitoring module 202 , an encap...

Embodiment 3

[0168] refer to image 3 As shown in , it is a schematic structural diagram of an electronic device provided by an embodiment of the present invention. In a preferred embodiment of the present invention, the electronic device 3 includes a memory 31 , at least one processor 32 , at least one communication bus 33 and a display screen 34 .

[0169] Those skilled in the art should understand that, image 3 The structure of the electronic device shown does not constitute a limitation of the embodiment of the present invention, it can be a bus structure or a star structure, and the electronic device 3 can also include more or less other hardware than shown in the figure Or software, or a different arrangement of components.

[0170] In some embodiments, the electronic device 3 includes an electronic device that can automatically perform numerical calculation and / or information processing according to preset or stored instructions, and its hardware includes but not limited ...

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 an application program memory leakage detection method. The method comprises the following steps of creating a weak reference monitor for each application program; when an application program runs, monitoring an Activity object of the corresponding application program through the weak reference monitor; packaging the Activity object as a weak reference object; detecting whether the weak reference of the Activity object exists or not; when it is determined that the weak reference of the Activity object exists, triggering a garbage collection mechanism, and marking the Activity object; detecting whether the Activity object is recovered or not; when it is detected that the Activity object is not recovered, obtaining a memory snapshot file of the application program; and analyzing memory leakage according to the memory snapshot file, generating an analysis report and reporting the analysis report. The invention further provides an application program memory leak detection device, electronic equipment and a storage medium. The invention belongs to the technical field of security monitoring, can accurately and quickly locate the memory leakage problem of an application program, and improves the efficiency and accuracy of application program memory optimization.

Description

technical field [0001] The present invention relates to the technical field of memory management, in particular to a method, device, electronic equipment and storage medium for detecting application program memory leaks. Background technique [0002] With the increasing demand for computer applications, the design and development of application programs have also become increasingly complex. After the application programs in electronic devices run for a period of time, the memory of electronic devices will become less and less. caused by a memory leak. Memory leak refers to those resources that have been used but are no longer used, but this part of memory has not been released in time, and this part of resources has always existed in memory, and this area can neither be used nor released. Since this piece of memory has been occupied and cannot be released in time, in other cases, when it is necessary to apply for memory again, but cannot apply for enough memory space, the ...

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
IPC IPC(8): G06F11/36G06F9/50
CPCG06F9/5016G06F9/5022G06F11/3636
Inventor 黄小婷
Owner CHINA PING AN LIFE INSURANCE 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