IP Library Granted Patent US 9,760,351
Granted Patent B2
US 9,760,351 · App. 13/855,557 · Granted Sep 12, 2017

Framework for user-directed profile-driven optimizations

Inventors: Teresa Louise Johnson (Los Gatos, CA); Xinliang David Li (Palo Alto, CA)
Assignee: Google Inc.
G06F8/443G06F8/4434G06F8/4441
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 9,760,351
App. No.
13/855,557
Granted
Sep 12, 2017
Kind
B2
Abstract

A method for using profiling to obtain application-specific, preferred parameter values for an application is disclosed. First, a parameter for which to obtain an application-specific value is identified. Code is then augmented for application-specific profiling of the parameter. The parameter is profiled and profile data is collected. The profile data is then analyzed to determine the application's preferred parameter value for the profile parameter.

Claims (27)

1. A method for using profiling to obtain application-specific, preferred parameter values for an application, the method comprising:

receiving identification of an application-specific parameter for which to obtain an application-specific value;

receiving augmented code for profiling the application-specific parameter;

profiling the parameter and collecting profile data by:

generating an instrumentation binary from an instrumentation build, the instrumentation binary containing at least one user-defined callback routine registered by the user in a profile initialization function;

executing a training run with one or more representative workloads using the instrumentation binary, the execution invoking the at least one user-defined callback routine to record at least one application-specific preferred parameter value for the application in the collected profile data;

analyzing the collected profile data using the at least one user-defined callback routine; and

generating a feedback-directed optimization (FDO) build using the collected profile data, the FDO build utilizing the at least one application-specific preferred parameter value recorded in the collected profile data for the profiled application-specific parameter.

2. The method of claim 1 wherein profiling is user-directed per-class global value profiling.

3. The method of claim 1 wherein profiling is user-directed per-site value profiling.

4. The method of claim 1 wherein profiling is user-directed per-site object value profiling.

5. The method of claim 1 wherein generating the FDO build, further comprises:

transforming, based on the profile data, an application-specific parameter value to a preferred value using a set of standard value profile transformations.

6. A method for user-directed per-class global value profiling, the method comprising:

receiving a user-defined profile instrumentation initialization routine, the profile instrumentation initialization routine initializing a counter to profile a parameter and registering a user-defined analysis call back routine, containing custom processing for profile data;

generating an instrumentation binary from an instrumentation build, the instrumentation binary containing at least one user-defined analysis callback routine registered by the user in a profile initialization function;

executing a training run with one or more representative workloads using the instrumentation binary, wherein the execution of the training run includes:

running a profile update function in a code location where the counter's value should be updated; and

executing a profile handler method, registered in the user-defined analysis callback routine, to process counter data and record a preferred parameter value for the profiled parameter; and

generating a feedback-directed optimization (FDO) build using profile data collected during execution of the training run.

7. The method of claim 1 further comprising defining a profile counter for the application-specific parameter to be profiled.

8. The method of claim 7 further comprising allocating one entry in the static counter array for the counter.

9. The method of claim 8 wherein allocation is done by calling a compiler extension for counter allocation.

10. The method of claim 1 further comprising allowing for profile counter address tracking by providing a special purpose declaration attribute for the profile counter.

11. The method of claim 1 further comprising allowing for profile initialization by providing a special purpose declaration attribute to designate a profile initialization function.

12. The method of claim 6 further comprising registering a user-defined analysis call back routine by using a GCC interface.

13. The method of claim 6 further comprising recording the preferred parameter value by using a GCC interface.

Assignments (2)
CHANGE OF NAME Recorded Oct 2, 2017
From: GOOGLE INC.
To: GOOGLE LLC
Reel/Frame 044097/0658 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Apr 5, 2013
From: JOHNSON, TERESA LOUISE; LI, XINLIANG DAVID
To: GOOGLE INC.
Reel/Frame 030162/0195 →
Continuity (1)
Related Publication 20140298307A1 · Oct 2, 2014