发明名称 Obtaining profile data for use in optimizing computer programming code
摘要 Program execution profile data is collected by direct measurement of some code paths, and by inferring data for unmeasured paths. The data collection process may cause errors, which are propagated by the inferencing process. The profile data thus constructed is further enhanced by detecting certain data mismatches, and adjusting inferred data to reduce the scope of errors propagated during the inferencing process. Preferably, a control flow graph of the program being measured is constructed. Mismatches in the total weights of input arcs versus output arcs are detected. For certain specific types of mismatches, it can be known or guessed which count is incorrect, and this count is accordingly corrected. Correction of arc counts proceeds recursively until it is no longer possible to correct mismatches. Additionally, certain other conditions are adjusted as presumed inaccuracies.
申请公布号 US9009681(B2) 申请公布日期 2015.04.14
申请号 US201213593248 申请日期 2012.08.23
申请人 International Business Machines Corporation 发明人 Schmidt William Jon
分类号 G06F9/44;G06F9/45 主分类号 G06F9/44
代理机构 代理人 Truelson Roy W.
主权项 1. A compiler for producing optimized computer programming code, said compiler embodied as a plurality of computer-executable instructions recorded on a non-transitory tangible computer-readable medium, said compiler comprising: an instrumentation function which places instrumentation hooks in a subset of respective paths in a first compiled version of a computer program, each instrumentation hook generating profile data during execution of said first compiled version of said computer program representing control flow in the respective path of the instrumentation hook to produce measured profile data, said subset of respective paths being fewer than all potential paths of said first compiled version of said computer program; an inferencing function, said inferencing function inferring profile data for control flow paths in said first compiled version of said computer program which are not in said subset to produce inferred profile data from said measured profile data; and a profile data adjustment function which uses at least one first heuristic to identify at least one error in profile data for at least one path in said first compiled version of said computer program inferred by said inferencing function and adjusts said error according to at least one second heuristic to produce adjusted inferred profile data from said measured profile data and said inferred profile data; wherein said compiler uses said measured profile data produced by said instrumentation hooks, said inferred profile data produced by said inferencing function, and said adjusted inferred profile data produced by said profile data adjustment function to generate an optimized version of said computer program.
地址 Armonk NY US