Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Method and device for parsing and processing call stack

A technology for parsing and processing call stacks, which is applied in the field of call stack parsing and can solve problems such as inability to obtain call stacks

Inactive Publication Date: 2016-01-27
HUAWEI TECH CO LTD
View PDF3 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0005] The embodiment of the present invention provides a method and device for parsing and processing the call stack to solve the problem that the call stack cannot be obtained when the register field in the call stack is missing or destroyed

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 device for parsing and processing call stack
  • Method and device for parsing and processing call stack
  • Method and device for parsing and processing call stack

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0045] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments It is a part of embodiments of the present invention, but not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without creative efforts fall within the protection scope of the present invention.

[0046] figure 1 The flow chart of an embodiment of the method for parsing and processing the call stack provided by the present invention, as shown in the figure, the method includes:

[0047] S101. After aligning the start address of the stack according to the preset number of bytes, perform a layer-by-layer search according to the preset number...

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 embodiment of the invention provides a call stack analyzing and processing method and device. The method comprises the following steps: searching layer by layer according to a preset byte number, judging if the search value of a current position is a valid return address value, if yes, then obtaining the valid return address value and the stack pointer of the current position; obtaining the size of the open stack and the storage offset of the valid return address value in the layer; connecting each valid return address value in series according to the corresponding stack pointer and the size of the open stack and the storage offset in the layer, and obtaining a candidate call stack; and screening out an objective call stack from at least one candidate call stack according to a preset screening rule. According to the embodiment of the invention, a plurality of valid RA (return address) values are obtained, the valid RA values and the excitation functions of the valid RA values are judged, and then the valid RA values are connected in series to get at least one candidate call stack from which the objective call stack is screened out, so that a preferred call stack analysis result is obtained.

Description

technical field [0001] The embodiment of the present invention relates to a call stack analysis technology, in particular to a call stack analysis processing method and device. Background technique [0002] Usually, when debugging software, you need to view the call stack of the current function, which is a function call chain that reflects the function call relationship. For example, function f1 calls function f2, and function f2 calls function f3, then f1→f2→f3 is a call stack. Specifically, there may be multiple calling situations between one function and another function. For example, the call stack of function f1 to function f3 can be f1→f2→f3, or f1→f4→f5→f3. Therefore, when When an exception occurs in the program, an error is detected, or a breakpoint is interrupted, it is necessary to view the current call stack of the current function. [0003] In the prior art, the common way to view the call stack of the current function is the X86 call stack parsing method. In ...

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 Patents(China)
IPC IPC(8): G06F9/44G06F11/36
Inventor 雷镇
Owner HUAWEI TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products