CN108763050A - A kind of detection method and device of application memory leakage - Google Patents
A kind of detection method and device of application memory leakage Download PDFInfo
- Publication number
- CN108763050A CN108763050A CN201810289407.9A CN201810289407A CN108763050A CN 108763050 A CN108763050 A CN 108763050A CN 201810289407 A CN201810289407 A CN 201810289407A CN 108763050 A CN108763050 A CN 108763050A
- Authority
- CN
- China
- Prior art keywords
- field data
- application
- terminal
- memory
- leakage
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/362—Software debugging
- G06F11/366—Software debugging using diagnostics
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/0703—Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
- G06F11/0706—Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation the processing taking place on a specific hardware platform or in a specific software environment
- G06F11/073—Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation the processing taking place on a specific hardware platform or in a specific software environment in a memory management context, e.g. virtual memory or cache management
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Computer Hardware Design (AREA)
- Storage Device Security (AREA)
Abstract
The present invention provides the detection methods and device of a kind of leakage of application memory.Wherein, the method includes:Obtain the field data of first terminal record;Wherein, the field data is that the first terminal detects the field data recorded when the leakage of the first application memory;According to the field data, the second application is operated in detection terminal, obtains memory stack information;Wherein, first application is identical as second application;According to the memory stack information, to causing first application memory to be revealed the reason of is analyzed.In the present invention, it distributes to different terminals with analysis RAM leakage by the way that RAM leakage will be detected and operates, analytic process the reason of RAM leakage is deferred in another terminal and is executed, it can avoid user terminal that interim card occurs, while improving the experience of user, the reason of capable of also analyzing using RAM leakage occurs.
Description
Technical field
The detection method and device revealed the present invention relates to field of computer technology more particularly to a kind of application memory.
Background technology
RAM leakage refers to that certain life cycles are not retracted when end, still committed memory.RAM leakage is
Common problem in application development process, serious leakage can largely consume memory, to will also result in pole using the experience of itself
It is big to influence, or even the abnormal behaviours such as triggering memory spilling.
Traditional application memory detection method, usually exports memory stack information immediately when detecting RAM leakage
It is analyzed, it is computationally intensive, the duration is long.Therefore inefficiency, while very big influence, nothing are caused on mobile terminal performance
Method efficiently detects RAM leakage on a large scale.
Invention content
The present invention provides the detection methods and device of a kind of leakage of application memory, when solving to detect RAM leakage,
Directly export memory stack information is analyzed the problem of being impacted to mobile terminal performance.
An embodiment of the present invention provides a kind of detection method of application memory leakage, this method includes:
Obtain the field data of first terminal record;Wherein, the field data is that the first terminal detects first
The field data that application memory records when revealing;
According to the field data, the second application is operated in detection terminal, obtains memory stack information;Wherein, described
First application is identical as second application;
According to the memory stack information, to causing first application memory to be revealed the reason of is analyzed.
Preferably, the field data for obtaining first terminal record, including:
The field data of the first terminal record is obtained from server;Wherein, the field data is in network sky
Idle, the first terminal are uploaded to the field data in the server.
Preferably, the field data includes:The title and trace information of RAM leakage process occurs;It is then described according to institute
Field data is stated, the second application is operated in detection terminal, obtains memory stack information, including:
According to the trace information, second application is operated in detection terminal, to reappear the RAM leakage;
When reappearing the RAM leakage, according to the title of the process, memory stack information is obtained.
Preferably, the field data further includes:The title of RAM leakage object;It is described to be believed according to the memory storehouse
Breath, to causing first application memory to be revealed the reason of, are analyzed, including:
The detection terminal is obtained and is corresponded in the memory stack information according to the title of the RAM leakage object
RAM leakage object;
According to the object of the RAM leakage, the strongly reference for being directed toward the object is obtained, the strongly reference is to lead to institute
The reason of stating the leakage of the first application memory.
Other side according to the present invention provides a kind of detection device of application memory leakage, including:
Detection module carries out real-time leak detection for first terminal to the first application of first terminal;
Logging modle, for when detecting the first application memory leakage, first terminal to record field data;
Field data acquisition module obtains the field data of first terminal record;Wherein, the field data is described the
One terminal detects the field data recorded when the leakage of the first application memory;
Memory storehouse data obtaining module, for according to the field data, the second application being operated in detection terminal, is obtained
Take memory stack information;Wherein, first application is identical as second application;
Analysis module, for according to the memory stack information, the reason of to causing first application memory to be revealed into
Row analysis.
Preferably, the field data acquisition module further includes:
Field data acquiring unit, the field data for obtaining the first terminal record from server;Wherein, institute
It is in network idle to state field data, and the first terminal is uploaded to the field data in the server.
Preferably, the field data includes:The title and trace information of RAM leakage process occurs;The then heap
Stack data obtaining module, including:
Operating unit, for according to the trace information, operating second application in detection terminal, described in reproduction
RAM leakage;
Memory storehouse information acquisition unit, for when reappearing the RAM leakage, according to the title of the process, obtaining
Memory stack information.
Preferably, the field data further includes:The title of RAM leakage object;The analysis module, including:
Object acquisition unit, for the detection terminal according to the title of the RAM leakage object, in the heap
In stack information, the object of corresponding RAM leakage is obtained;
Analysis of causes unit obtains the strongly reference for being directed toward the object for the object according to the RAM leakage, described
Strongly reference is the reason of causing first application memory to be revealed.
Other side according to the present invention provides a kind of computer program, including computer-readable code, when described
When computer-readable code is run on the terminal device, the terminal device is caused to execute any application memory leakage
Detection method.
Other side according to the present invention provides a kind of computer-readable medium, wherein stores as described above
Computer program.
The embodiment of the present invention includes following advantages:
In embodiments of the present invention, the field data recorded by obtaining first terminal;Wherein, the field data is institute
It states first terminal and detects the field data recorded when the leakage of the first application memory;According to the field data, in detection terminal
The second application of middle operation, obtains memory stack information;Wherein, first application is identical as second application;According to described
Memory stack information, to causing first application memory to be revealed the reason of, are analyzed.In the present invention, in by that will detect
It deposits leakage to distribute to different terminals with analysis RAM leakage and operated, analytic process the reason of RAM leakage is deferred to another
It is executed in terminal, can avoid user terminal that interim card occurs, while improving the experience of user, can also analyzed using hair
The reason of raw RAM leakage.
Description of the drawings
In order to illustrate the technical solution of the embodiments of the present invention more clearly, below by institute in the description to the embodiment of the present invention
Attached drawing to be used is needed to be briefly described, it should be apparent that, the accompanying drawings in the following description is only some implementations of the present invention
Example, for those of ordinary skill in the art, without having to pay creative labor, can also be according to these attached drawings
Obtain other attached drawings.
Fig. 1 shows a kind of flow chart of the detection method of the leakage of application memory in the embodiment of the present invention one;
Fig. 2 shows a kind of flow charts of the detection method of application memory leakage in the embodiment of the present invention two;
Fig. 3 shows a kind of structure diagram of the detection device of the leakage of application memory in the embodiment of the present invention three.
Specific implementation mode
Exemplary embodiment of the present invention is more fully described below with reference to accompanying drawings.Although showing the present invention in attached drawing
Exemplary embodiment, it being understood, however, that may be realized in various forms the present invention without should be by embodiments set forth here
It is limited.It is to be able to be best understood from the present invention on the contrary, providing these embodiments, and can be by the scope of the present invention
Completely it is communicated to those skilled in the art.
Embodiment one
Referring to Fig.1, the detection method flow chart for showing a kind of application memory leakage of the embodiment of the present invention one, specifically may be used
To include the following steps:
Step 101, the field data of first terminal record is obtained;Wherein, the field data is examined for the first terminal
Measure the field data recorded when the leakage of the first application memory.
In embodiments of the present invention, detection terminal is independently of another terminal of first terminal, is mainly used for first eventually
The reason of end generation RAM leakage, is analyzed, and in embodiments of the present invention, first terminal can be user terminal.
In embodiments of the present invention, RAM leakage occurs when using application in first terminal for user, and first terminal will
Field data is recorded, and in network idle, field data directly can be sent to detection terminal by first terminal, can also
It is sent to detection terminal by other means, the present invention does not limit this, when detection terminal receives field data, you can
The reason of RAM leakage, is analyzed according to field data.
In the concrete realization, the embodiment of the present invention can apply in the terminal, the terminal can be mobile phone, tablet computer,
Personal digital assistant, wearable device, desktop computer etc..
In embodiments of the present invention, the operating system of first terminal may include the operating systems such as Android (Android).This
A little operating systems can support that various systems are applied and third-party application operation, for example, shopping client, payment client terminal, logical
News tool etc..
In embodiments of the present invention, the first application is installed, memory can occur in use for the first application in first terminal
Leakage.
In embodiments of the present invention, the application for memory detection, the first application of detection can be installed in first terminal
RAM leakage whether occurs, or corresponding detection components are set in the first application, whether the first application of detection occurs memory
Leakage.The mode that RAM leakage occurs to detecting application for the embodiment of the present invention does not limit.
In the concrete realization, the embodiment of the present invention when detecting the leakage of the first application memory, timely remember by first terminal
Record field data.
In embodiments of the present invention, application program is typically by JAVA language or the language that can be run in JAVA virtual machine
Speech is write, and the object of the embodiment of the present invention refers to the example for the class that JAVA etc. writes in face of object language.
In embodiments of the present invention, the program applied when first at runtime, can open one or more processes operation phases
Pass task.It is that RAM leakage has occurred in which process to distinguish, it is therefore desirable to which the title of RAM leakage process occurs for record.
Such as when wechat is in unlatching, can there are com.tencent.mm and com.tencent.mm:The processes such as push, so needing to remember
Record is specifically that RAM leakage occurs for which process.
In embodiments of the present invention, for example, user is after opening using A, which operation has been carried out respectively, and the present invention is real
Example is applied to record these trace informations.
In embodiments of the present invention, field data is directly recorded by text mode in daily record, for example, RAM leakage pair
The title of elephant and the title of process can be recorded as:2018-03-07_13:23:
07android.arch.lifecycle.ReportFragment com.qiyi.video.Trace information is recorded as:2018-
03-07_13:21:24onPause org.qiyi.android.video.MainActivity。2018-03-07_13:21:
24onResume com.iqiyi.pay.vip.activity.PhonePayActivity。2018-03-07_13:21:
30onPause com.iqiyi.pay.vip.activity.PhonePayActivity。2018-03-07_13:22:
56onResume org.qiyi.android.video.MainActivity.The embodiment of the present invention records these field datas
In daily record, for subsequent calls.
Step 102, according to the field data, the second application is operated in detection terminal, obtains memory stack information;Its
In, first application is identical as second application.
In embodiments of the present invention, it needs to be equipped in detection terminal and be applied with the first application identical second, for example, first
Wechat client is installed in terminal, then needs the wechat client for being equipped with same version in detection terminal.
In embodiments of the present invention, detection terminal is according to field data, i.e. scene of the first terminal in raw RAM leakage
State is re-operated and is applied with the first application identical second.For example, the operation of user is to open application in the first application
A, click, which is swept, sweeps function, after barcode scanning, clicks payment, typing fingerprint is paid successfully;Then application A is carried out in detection terminal
Same operation.
In embodiments of the present invention, after to the second application similarly operate, when detecting that it is same that the second application occurs
When the RAM leakage of sample, you can obtain memory stack information in detection terminal.
Step 103, according to the memory stack information, to causing first application memory to be revealed the reason of divides
Analysis.
In embodiments of the present invention, after getting memory stack information, you can search memory in heap stack information
The object of leakage, i.e. this object have not used, but still there are GC (Garbage Collector) root nodes in stack information
The reason of to the reference chain of this object, causing object that can not withdraw, sending RAM leakage, as RAM leakage.
In embodiments of the present invention, the field data recorded by obtaining first terminal;Wherein, the field data is institute
It states first terminal and detects the field data recorded when the leakage of the first application memory;According to the field data, in detection terminal
The second application of middle operation, obtains memory stack information;Wherein, first application is identical as second application;According to described
Memory stack information, to causing first application memory to be revealed the reason of, are analyzed.In the present invention, in by that will detect
It deposits leakage to distribute to different terminals with analysis RAM leakage and operated, analytic process the reason of RAM leakage is deferred to another
It is executed in terminal, can avoid user terminal that interim card occurs, while improving the experience of user, can also analyzed using hair
The reason of raw RAM leakage.
Embodiment two
With reference to Fig. 2, shows a kind of detection method flow chart of application memory leakage of the embodiment of the present invention two, specifically may be used
To include the following steps:
Step 201, the field data of the first terminal record is obtained from server;Wherein, the field data is
In network idle, the first terminal is uploaded to the field data in the server.
In embodiments of the present invention, when being applied using first RAM leakage occurs for first terminal, but if at this time the
One terminal directly analyzes the reason of RAM leakage, and computationally intensive when due to analysis, the duration is long, must can be to user
The use of first terminal is impacted, user experience is influenced, so in the embodiment of the present invention, it, will be live in network idle
Information is uploaded in server automatically, can be avoided to user's use and the influence of first terminal performance.
In embodiments of the present invention, there can be multiple first terminals, for example, first terminal A is when using the first application
RAM leakage occurs, then the field data of itself is sent to server by first terminal A, and first terminal B is using the first application
Shi Fasheng RAM leakages, then first terminal B the field data of itself is sent to server.Server can be by all first eventually
The field data that RAM leakage occurs when being applied using first is held to carry out summarizing storage.
In embodiments of the present invention, all users can become the finder of the first application memory leakage, contribute to pair
The reason of RAM leakage occurs is analyzed, and realizes extensive detection, improves the efficiency of detection.
In embodiments of the present invention, detection terminal obtains first terminal from server and believes about the phenomenon that the first application
The reason of breath, scene leakage occurs for the first application of first terminal, is analyzed, and can also obtain, the first of multiple first terminals
The field data of application, the whole cause for the first application occurring scene leakage are analyzed, and the embodiment of the present invention is not added with this
With limitation.
Step 202, according to the trace information, second application is operated in detection terminal.
In embodiments of the present invention, field data includes the title and trace information that RAM leakage process occurs;
In embodiments of the present invention, trace information is to occur to occur when RAM leakage when being applied according to user's operation first
, according to the second application of trace information operation, such as:Trace information is:User uses first terminal, opens and applies A, point
It hits to sweep and sweeps function, after barcode scanning, click payment, typing fingerprint is paid successfully;Then application A is carried out in detection terminal same
Operation, due to second application and first application it is identical, then to second application similarly operated when, operation first can be reappeared
Using when the RAM leakage that occurs.
Step 203, when reappearing the RAM leakage, according to the title of the process, memory stack information is obtained.
In embodiments of the present invention, field data includes the title of process, then reappears RAM leakage in detection terminal
It is, according to the title of process, this process to be searched in detection terminal, since each process has the memory stack information of oneself,
Then according to the process found, the corresponding memory stack information of this process is exported.
In embodiments of the present invention, can RAM leakage be transferred to detection terminal to analyze, reducing multi-user makes
With the influence of first terminal, the efficiency of detection is improved.
Step 204, the detection terminal is according to the title of the RAM leakage object, in the memory stack information,
Obtain the object of corresponding RAM leakage.
In embodiments of the present invention, the field data further includes:The title of RAM leakage object;When export memory storehouse
Information then finds corresponding object according to the title of RAM leakage object in heap stack information.
Step 205, according to the object of the RAM leakage, the strongly reference for being directed toward the object is obtained, the strongly reference is
The reason of to cause first application memory to be revealed.
In embodiments of the present invention, after finding the object that RAM leakage occurs, which is analyzed and is directed to the object
Strongly reference.Just because of these strongly references, make object not when in use, however it remains drawing from GC root nodes to this object
With chain, this object can not be recycled by causing the rubbish of JAVA virtual machine to withdraw mechanism, and RAM leakage occurs.The embodiment of the present invention exists
After finding these strongly references, it can subsequently eliminate these strongly references in time by changing code, repair RAM leakage.
In embodiments of the present invention, by obtaining the field data of first terminal record from server, field data is
In network idle, first terminal is uploaded to the field data in server.According to the trace information, grasped in detection terminal
Make second application.When reappearing the RAM leakage, according to the title of the process, memory stack information is obtained, it is described
Detection terminal obtains corresponding RAM leakage according to the title of the RAM leakage object in the memory stack information
Object.According to the object of the RAM leakage, the strongly reference for being directed toward the object is obtained, the strongly reference is to lead to described the
The reason of one application memory is revealed.In embodiments of the present invention, multiple terminals using first in application, different operations can be sent out
Raw different RAM leakage.Each terminal records the field data of itself, is uploaded in server, server will be live
Information, which arrange, is sent to detection terminal, then detection terminal can analyze which RAM leakage can occur for the first application.And then it can
With improve first application, improve first application performance, meanwhile, the detection of RAM leakage and analytic process can't shadow
User is rung using first terminal and the first application, improves user experience.
Embodiment three
With reference to Fig. 3, a kind of flow diagram of the detection device of application memory leakage of the embodiment of the present invention three, tool are shown
Body may include following module:
Field data acquisition module 301 obtains the field data of first terminal record;Wherein, the field data is institute
It states first terminal and detects the field data recorded when the leakage of the first application memory;
Memory storehouse data obtaining module 302, is used for according to the field data, and second is operated in detection terminal and is answered
With acquisition memory stack information;Wherein, first application is identical as second application;
Analysis module 303, for according to the memory stack information, the reason of to causing first application memory to be revealed
It is analyzed.
Optionally, the field data acquisition module further includes:
Field data acquiring unit, the field data for obtaining the first terminal record from server;Wherein, institute
It is in network idle to state field data, and the first terminal is uploaded to the field data in the server.
Optionally, the field data includes:The title and trace information of RAM leakage process occurs;The then heap
Stack data obtaining module, including:
Operating unit, for according to the trace information, operating second application in detection terminal, described in reproduction
RAM leakage;
Memory storehouse information acquisition unit, for when reappearing the RAM leakage, according to the title of the process, obtaining
Memory stack information.
Optionally, the field data further includes:The title of RAM leakage object;The then analysis module, including:
Object acquisition unit, for the detection terminal according to the title of the RAM leakage object, in the heap
In stack information, the object of corresponding RAM leakage is obtained;
Analysis of causes unit obtains the strongly reference for being directed toward the object for the object according to the RAM leakage, described
Strongly reference is the reason of causing first application memory to be revealed.
In embodiments of the present invention, the field data recorded by obtaining first terminal;Wherein, the field data is institute
It states first terminal and detects the field data recorded when the leakage of the first application memory;According to the field data, in detection terminal
The second application of middle operation, obtains memory stack information;Wherein, first application is identical as second application;According to described
Memory stack information, to causing first application memory to be revealed the reason of, are analyzed.In the present invention, in by that will detect
It deposits leakage to distribute to different terminals with analysis RAM leakage and operated, analytic process the reason of RAM leakage is deferred to another
It is executed in terminal, can avoid user terminal that interim card occurs, while improving the experience of user, can also analyzed using hair
The reason of raw RAM leakage.
For device embodiments, since it is basically similar to the method embodiment, so fairly simple, the correlation of description
Place illustrates referring to the part of embodiment of the method.
Each embodiment in this specification is described in a progressive manner, the highlights of each of the examples are with
The difference of other embodiment, the same or similar parts between the embodiments can be referred to each other.
It should be understood by those skilled in the art that, the embodiment of the embodiment of the present invention can be provided as method, apparatus or calculate
Machine program product.Therefore, the embodiment of the present invention can be used complete hardware embodiment, complete software embodiment or combine software and
The form of the embodiment of hardware aspect.Moreover, the embodiment of the present invention can be used one or more wherein include computer can
With in the computer-usable storage medium (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.) of program code
The form of the computer program product of implementation.
The embodiment of the present invention be with reference to according to the method for the embodiment of the present invention, terminal device (system) and computer program
The flowchart and/or the block diagram of product describes.It should be understood that flowchart and/or the block diagram can be realized by computer program instructions
In each flow and/or block and flowchart and/or the block diagram in flow and/or box combination.These can be provided
Computer program instructions are set to all-purpose computer, special purpose computer, Embedded Processor or other programmable data processing terminals
Standby processor is to generate a machine so that is held by the processor of computer or other programmable data processing terminal equipments
Capable instruction generates for realizing in one flow of flow chart or multiple flows and/or one box of block diagram or multiple boxes
The device of specified function.
These computer program instructions, which may also be stored in, can guide computer or other programmable data processing terminal equipments
In computer-readable memory operate in a specific manner so that instruction stored in the computer readable memory generates packet
The manufacture of command device is included, which realizes in one flow of flow chart or multiple flows and/or one side of block diagram
The function of being specified in frame or multiple boxes.
These computer program instructions can be also loaded into computer or other programmable data processing terminal equipments so that
Series of operation steps are executed on computer or other programmable terminal equipments to generate computer implemented processing, thus
The instruction executed on computer or other programmable terminal equipments is provided for realizing in one flow of flow chart or multiple flows
And/or in one box of block diagram or multiple boxes specify function the step of.
Although the preferred embodiment of the embodiment of the present invention has been described, once a person skilled in the art knows bases
This creative concept, then additional changes and modifications can be made to these embodiments.So the following claims are intended to be interpreted as
Including preferred embodiment and fall into all change and modification of range of embodiment of the invention.
Finally, it is to be noted that, herein, relational terms such as first and second and the like be used merely to by
One entity or operation are distinguished with another entity or operation, without necessarily requiring or implying these entities or operation
Between there are any actual relationship or orders.Moreover, the terms "include", "comprise" or its any other variant meaning
Covering non-exclusive inclusion, so that process, method, article or terminal device including a series of elements not only wrap
Those elements are included, but also include other elements that are not explicitly listed, or further include for this process, method, article
Or the element that terminal device is intrinsic.In the absence of more restrictions, being wanted by what sentence "including a ..." limited
Element, it is not excluded that there is also other identical elements in process, method, article or the terminal device including the element.
Above to a kind of detection method and device of application memory leakage provided by the present invention, it is described in detail,
Principle and implementation of the present invention are described for specific case used herein, and the explanation of above example is only used
In facilitating the understanding of the method and its core concept of the invention;Meanwhile for those of ordinary skill in the art, according to the present invention
Thought, there will be changes in the specific implementation manner and application range, in conclusion the content of the present specification should not be construed as
Limitation of the present invention.
Claims (10)
1. a kind of detection method of application memory leakage, which is characterized in that the method includes:
Obtain the field data of first terminal record;Wherein, the field data is that the first terminal detects the first application
The field data recorded when RAM leakage;
According to the field data, the second application is operated in detection terminal, obtains memory stack information;Wherein, described first
Using identical as second application;
According to the memory stack information, to causing first application memory to be revealed the reason of is analyzed.
2. according to the method described in claim 1, it is characterized in that, it is described obtain first terminal record field data, including:
The field data of the first terminal record is obtained from server;Wherein, the field data be in network idle,
The first terminal is uploaded to the field data in the server.
3. according to the method described in claim 2, it is characterized in that, the field data includes:RAM leakage process occurs
Title and trace information;It is then described according to the field data, the second application is operated in detection terminal, obtains memory storehouse letter
Breath, including:
According to the trace information, second application is operated in detection terminal;
When reappearing the RAM leakage, according to the title of the process, memory stack information is obtained.
4. according to the method described in claim 3, it is characterized in that, the field data further includes:The name of RAM leakage object
Claim;Then described according to the memory stack information, to causing first application memory to be revealed the reason of is analyzed, including:
According to the title of the RAM leakage object object of corresponding RAM leakage is obtained in the memory stack information;
According to the object of the RAM leakage, the strongly reference for being directed toward the object is obtained, the strongly reference is to lead to described the
The reason of one application memory is revealed.
5. a kind of detection device of application memory leakage, which is characterized in that described device includes:
Field data acquisition module obtains the field data of first terminal record;Wherein, the field data is described first whole
End detects the field data recorded when the leakage of the first application memory;
Memory storehouse data obtaining module, is used for according to the field data, and second is operated in detection terminal and is applied, in acquisition
Deposit stack information;Wherein, first application is identical as second application;
Analysis module, for according to the memory stack information, to causing first application memory to be revealed the reason of divides
Analysis.
6. device according to claim 5, which is characterized in that the field data acquisition module further includes:
Field data acquiring unit, the field data for obtaining the first terminal record from server;Wherein, described existing
Field information is in network idle, and the first terminal is uploaded to the field data in the server.
7. device according to claim 6, which is characterized in that the field data includes:RAM leakage process occurs
Title and trace information;The then memory storehouse data obtaining module, including:
Operating unit, for according to the trace information, operating second application in detection terminal, to reappear the memory
Leakage;
Memory storehouse information acquisition unit, for when reappearing the RAM leakage, according to the title of the process, obtaining memory
Stack information.
8. device according to claim 7, which is characterized in that the field data further includes:The name of RAM leakage object
Claim;The analysis module, including:
Object acquisition unit is believed for the detection terminal according to the title of the RAM leakage object in the memory storehouse
In breath, the object of corresponding RAM leakage is obtained;
Analysis of causes unit obtains the strongly reference for being directed toward the object for the object according to the RAM leakage, described to draw by force
The reason of with as first application memory being caused to be revealed.
9. a kind of computer program, including computer-readable code, when the computer-readable code is run on the terminal device
When, cause the terminal device to execute the detection method that the application memory according to any one of claim 1-4 is revealed.
10. a kind of computer-readable medium, wherein store the computer program as described in claim 1-4.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810289407.9A CN108763050A (en) | 2018-04-03 | 2018-04-03 | A kind of detection method and device of application memory leakage |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810289407.9A CN108763050A (en) | 2018-04-03 | 2018-04-03 | A kind of detection method and device of application memory leakage |
Publications (1)
Publication Number | Publication Date |
---|---|
CN108763050A true CN108763050A (en) | 2018-11-06 |
Family
ID=63980841
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810289407.9A Pending CN108763050A (en) | 2018-04-03 | 2018-04-03 | A kind of detection method and device of application memory leakage |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108763050A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111090536A (en) * | 2019-11-19 | 2020-05-01 | 北京字节跳动网络技术有限公司 | Method, device, medium and electronic equipment for acquiring memory leakage information |
CN113722142A (en) * | 2021-09-02 | 2021-11-30 | 北京天融信网络安全技术有限公司 | Method and device for analyzing reasons of insufficient memory, electronic equipment and storage medium |
CN114546693A (en) * | 2022-01-19 | 2022-05-27 | 北京字节跳动网络技术有限公司 | Memory leak detection method and device, readable medium and electronic equipment |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107391360A (en) * | 2016-11-16 | 2017-11-24 | 广州爱九游信息技术有限公司 | Application exception information processing method, device, server and user terminal |
CN107391357A (en) * | 2017-08-17 | 2017-11-24 | 杭州师范大学 | Application crashes replay method, device and mobile terminal |
-
2018
- 2018-04-03 CN CN201810289407.9A patent/CN108763050A/en active Pending
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107391360A (en) * | 2016-11-16 | 2017-11-24 | 广州爱九游信息技术有限公司 | Application exception information processing method, device, server and user terminal |
CN107391357A (en) * | 2017-08-17 | 2017-11-24 | 杭州师范大学 | Application crashes replay method, device and mobile terminal |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111090536A (en) * | 2019-11-19 | 2020-05-01 | 北京字节跳动网络技术有限公司 | Method, device, medium and electronic equipment for acquiring memory leakage information |
CN111090536B (en) * | 2019-11-19 | 2021-11-16 | 北京字节跳动网络技术有限公司 | Method, device, medium and electronic equipment for acquiring memory leakage information |
CN113722142A (en) * | 2021-09-02 | 2021-11-30 | 北京天融信网络安全技术有限公司 | Method and device for analyzing reasons of insufficient memory, electronic equipment and storage medium |
CN113722142B (en) * | 2021-09-02 | 2023-08-25 | 北京天融信网络安全技术有限公司 | Method and device for analyzing reasons of insufficient memory, electronic equipment and storage medium |
CN114546693A (en) * | 2022-01-19 | 2022-05-27 | 北京字节跳动网络技术有限公司 | Memory leak detection method and device, readable medium and electronic equipment |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US9590880B2 (en) | Dynamic collection analysis and reporting of telemetry data | |
US9612791B2 (en) | Method, system and storage medium for monitoring audio streaming media | |
US20160349928A1 (en) | Generating summary of activity on computer gui | |
US9870303B2 (en) | Monitoring and correlating a binary process in a distributed business transaction | |
CN102323873B (en) | In order to trigger the method and system that icon is replied in instant messaging | |
CN111552633A (en) | Interface abnormal call testing method and device, computer equipment and storage medium | |
WO2020253066A1 (en) | Page management method and apparatus, and computer device and storage medium | |
US11108787B1 (en) | Securing a network device by forecasting an attack event using a recurrent neural network | |
US20170251072A1 (en) | System and method for annotating client-server transactions | |
KR20160125401A (en) | Inline and context aware query box | |
CN108763050A (en) | A kind of detection method and device of application memory leakage | |
US20170103400A1 (en) | Capturing and identifying important steps during the ticket resolution process | |
EP3058481A1 (en) | Acceleration based on cached flows | |
US10067862B2 (en) | Tracking asynchronous entry points for an application | |
US11550688B2 (en) | User interaction logic classification | |
KR20230007268A (en) | Task processing method, task processing device, electronic device, storage media and computer program | |
CN104580109B (en) | Generation clicks the method and device of identifying code | |
US9823998B2 (en) | Trace recovery via statistical reasoning | |
US20150106522A1 (en) | Selecting a target server for a workload with a lowest adjusted cost based on component values | |
US10803861B2 (en) | Method and apparatus for identifying information | |
CN114817590A (en) | Path storage method, path query method and device, medium and electronic equipment | |
US11151309B1 (en) | Screenshot-based memos | |
CN114595391A (en) | Data processing method and device based on information search and electronic equipment | |
US20180052696A1 (en) | Providing teaching user interface activated by user action | |
CN110085237B (en) | Recovery method, device and equipment of interactive process |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20181106 |