发明名称 Debugging system using static analysis
摘要 A debugging system for compiled code may include static analysis of the compiled code to determine current values for variables at a paused location within the compiled code. The static analysis may consist of liveness analysis to determine which variables are ‘live’ and in which memory locations those variables are stored. The variables and their values may be presented to a user. The debugging system may include mechanisms for setting stop points, for pausing and continuing execution, as well as stepping through a step or group of steps. Other static analysis may include unwind information that may determine a point in the code from where the current function was called, as well as partial decompilation of the source code to produce a representation of the compiled code that is closer to that of the source code.
申请公布号 US9274930(B2) 申请公布日期 2016.03.01
申请号 US200812340797 申请日期 2008.12.22
申请人 Microsoft Technology Licensing, LLC 发明人 Morrison Vance P.
分类号 G06F9/44;G06F11/36 主分类号 G06F9/44
代理机构 代理人 Sullivan Kevin;Drakos Kate;Minhas Micky
主权项 1. At a computer system, the computer system having a plurality of hardware memory storage locations used for storing values for variables during the execution of binary code, a method for debugging binary code, the method comprising: executing a compiled binary code to a first breakpoint, the compiled binary code having been created from source code using a compiler, the binary code optimized to reuse the plurality of hardware memory storage locations for storing values for different variables used within the binary code at different times during execution; identifying a variable used within binary code, the variable having a variable name defined in the source code; at the first breakpoint, performing a static analysis on the compiled binary code, including: performing a liveness analysis to determine that the identified variable is currently live, even when the variable is no longer used, the liveness analysis including: determining that the identified variable has been set;determining a hardware memory storage location for the identified variable, from among the plurality of hardware memory storage locations, that stores a value for the identified variable, the hardware memory storage location configured to store values for different variables, from among a plurality of different variables including the identified variable, at different times during execution of the binary code; andchecking if the identified variable is live at the determined hardware memory storage location by determining that the stored value is current, including ensuring that the determined hardware memory storage location has not been overwritten with a value for another variable included in the plurality of different variables; retrieving the value from the hardware memory storage location in response to determining that the identified variable is live; and presenting the identified variable and the value on a user interface.
地址 Redmond WA US