Abstract:
Embodiments of the disclosure provide systems and methods for clock duty cycle measurement. A clock signal and a complement of the clock signal are provided to a charge pump during first and second predetermined timing windows. A charge pump is operable to generate first and second output voltages in response to the clock signal and the complement of the clock signal during the first and second timing windows, respectively. In addition a predetermined positive voltage and a ground voltage are applied to the charge pump during predetermined third and fourth timing windows, respectively. The charge pump is operable to generate third and fourth output voltage signals corresponding to the predetermined positive and ground voltages during the third and fourth timing windows, respectively. The first, second, third and fourth voltages are then used to calculate the duty cycle of the clock.

Description:
BACKGROUND OF THE INVENTION 
       [0001]    1. Field of the Invention 
         [0002]    The present invention relates in general to the field of computer circuitry. More specifically, embodiments of the invention are systems and methods for measuring a clock duty cycle without using a reference clock for calibration. 
         [0003]    2. Description of the Related Art 
         [0004]    The duty-cycle of a high-speed clock is a very important aspect of modern integrated circuits, such as high-performance microprocessors. For example, either the positive or the negative cycle of a clock can be used for memory access and the memory access speed is directly related to the duration of the clock pulse and thus the duty cycle. In theory, a fifty percent duty cycle clock is preferred from a phase-locked loop (PLL) and the clock distribution circuitry. However, the optimum duty cycle of a clock for maximum system performance will vary from one circuit to another due to process variation and model-to-hardware correlation. 
         [0005]    In general it is difficult to measure the duty cycle of a clock, since any logic that is used to extract the duty cycle of a clock will also lead to duty cycle degradation of the original clock. In addition, most prior techniques for measuring the duty cycle of a clock require an off-chip reference clock for calibration. 
         [0006]    To help optimize design, it is preferable to calculate the duty cycle of a clock using on-chip hardware. A clock duty cycle is sensitive to many different factors, including operating frequency, operating temperature, supply voltage, circuit design style, circuit loading, and process (e.g., variations in the doping, threshold voltage, mobility, gate oxide thickness, etc. across single and/or multiple wafers). Because so many different factors may affect duty cycle, it is important to be able to accurately measure clock duty cycle at the point of use on the chip under actual operating conditions. 
         [0007]    It is apparent, therefore, that there is a need for an improved system and method for measuring the duty cycle of a clock using on-chip hardware without a reference clock. 
       SUMMARY OF THE INVENTION 
       [0008]    Embodiments of the invention provide systems and methods for clock duty cycle measurement that are accurate, low cost and easily implemented on-chip. In embodiments of the invention, the duty-cycle of a clock is extracted from hardware without the need for a reference clock calibration. 
         [0009]    In various embodiments of the invention for measuring the duty cycle of a clock, a clock signal and a complement of the clock signal are provided to a charge pump during first and second predetermined timing windows. A charge pump is operable to generate first and second output voltages in response to the clock signal and the complement of the clock signal during the first and second timing windows, respectively. In addition a predetermined positive voltage and a ground voltage are applied to the charge pump during predetermined third and fourth timing windows, respectively. The charge pump is operable to generate third and fourth output voltage signals corresponding to the predetermined positive and ground voltages during the third and fourth timing windows, respectively. The first, second, third and fourth voltages are then used to calculate the duty cycle of the clock. 
     
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
         [0010]    The present invention may be better understood, and its numerous objects, features and advantages made apparent to those skilled in the art by referencing the accompanying drawings. The use of the same reference number throughout the several figures designates a like or similar element. 
           [0011]      FIG. 1  is a general illustration of an on-chip clock duty cycle measurement system in accordance with an illustrative embodiment of the invention; 
           [0012]      FIG. 2  is an exemplary circuit diagram of an on-chip duty cycle measurement system in accordance with one illustrative embodiment; 
           [0013]      FIG. 3  is a chart illustrating control signal settings for various operational modes in accordance with embodiments of the invention; and 
           [0014]      FIG. 4  is an illustrative process flowchart of steps for implementing embodiments of the on-chip clock duty cycle measurement system and method. 
       
    
    
     DETAILED DESCRIPTION 
       [0015]    Embodiments of systems and methods are disclosed for measuring a clock duty cycle without using a reference clock for calibration. Various illustrative embodiments of the present invention will now be described in detail with reference to the accompanying figures. While various details are set forth in the following description, it will be appreciated that the present invention may be practiced without these specific details, and that numerous implementation-specific decisions may be made to the invention described herein to achieve the device designer&#39;s specific goals, such as compliance with process technology or design-related constraints, which will vary from one implementation to another. While such a development effort might be complex and time-consuming, it would nevertheless be a routine undertaking for those of ordinary skill in the art having the benefit of this disclosure. For example, selected aspects are depicted with reference to simplified drawings in order to avoid limiting or obscuring the present invention. Such descriptions and representations are used by those skilled in the art to describe and convey the substance of their work to others skilled in the art. Various illustrative embodiments of the present invention will now be described in detail with reference to the figures. 
         [0016]      FIG. 1  is a general illustration of an on-chip clock duty cycle measurement system used to measure the clock duty cycle for an integrated circuit  102  in accordance with an illustrative embodiment of the invention. As will be understood by those of skill in the art, embodiments of the local clock duty cycle measurement circuitry described herein can be embedded in a plurality of data processing circuits in integrated circuits that are used to process data in an information handling system  101 , shown in  FIG. 1 , and in a wide range of other applications. 
         [0017]    A single-ended clock signal generated by clock generator  104  is provided to a clock splitter  106  that is operable to generate “true” and “complement” clock signals for processing by the duty cycle measurement system  108 , as described in greater detail hereinbelow. The output of the duty cycle measurement system is provided to an appropriate measurement device  110 , such as a high-impedance voltage meter. A test processor  112  is operable to execute appropriate computer code, stored in a computer-readable medium  114 , to provide the processing steps described in greater detail below, and to display the results of the processing steps on a user interface  116 . 
         [0018]      FIG. 2  is an exemplary circuit diagram of an on-chip duty cycle measurement system  108  in accordance with one illustrative embodiment of the invention. As discussed in greater detail hereinbelow, the duty cycle measurement system  108  comprises a two charge pumps, implemented with transistors  201  and  203 , that receive the true and complement clock signals and generate output voltages that can be used to calculate the duty cycle of the original clock signal. 
         [0019]    Prior to discussing operation of the various components shown in  FIG. 2 , the mathematical basis for calculating a clock duty cycle using the voltages generated by a charge pump in response to a clock signal will be discussed. The following equation provides the relationship between voltage and clock duty cycle when a clock signal is provided to a charge pump: 
         [0000]      δ V =( I/C )*(1−2* dcc )* T*N    (1) 
         [0000]    where, T is the period of the clock, dcc is the duty cycle of the clock, which is the high duration of the pulse divided by the period, N is the number of cycles for the clock, and “T*N” is the total time or “timing window.” C is the capacitance of the capacitor in the charge pump, I is the charge pump current, and δV is the voltage change on the capacitor C. 
         [0020]    For an ideal charge pump, a 50% duty cycle clock will result in no voltage change. Over 50% dcc clock will result in a negative δV while less than 50% dcc will result in positive dV. In practice, the up and dn currents cannot be fully matched and transient overshoot or undershoot can also occur. As a result, a 50% dcc clock can lead to change of voltage V at the capacitor and δV will not equal to zero. To account for the offset due to nonideal effects, prior techniques generally used a reference clock with known duty cycle for calibration. In real applications, the reference clocks for calibration might not be easily available. 
         [0021]    For a non-ideal charge pump, assume the dn current is I and up current is I+δI, then (1) can be rewritten as 
         [0000]      δ V =( T*N/C )*[ I+δI −(2 I+δI )* dcc]   (2) 
         [0000]      Or 
         [0000]        dcc =( I+δI )/(2 I+δI )−δ V*C /( T*N *(2 I+δI ))   (3) 
         [0022]    For a charge pump, I and δI are constant when the charge pump voltage is in the operation voltage range. C is fixed after manufacturing. T is known for the clock, and N can be set to be constant in the circuit configuration. Therefore, (3) can be rewritten as 
         [0000]    
       
      
       dcc=A+δV*B  
      
     
         [0000]      Here,  A =( I+δI )/(2 I+δI ), 
         [0000]        B=−C /( T*N *(2 I+δI ))   (4) 
         [0023]    Equations (2) to (4) apply to all dcc clock embodiments including dcc=1 where it is charge down mode and dcc=0 where it is charge up mode. The values for A and B can be obtained using the following procedure: First the original clock, with a duty cycle of dcc, is connected to the charge pump circuit and δV is measured as δVa. The same procedure is then followed using the complement clock and V is measured as δVb. From (4), the following relationships are obtained: 
         [0000]        dcc=A+δVa*B    (5) 
         [0000]      1− dcc=A+δVb*B    (6) 
         [0024]    Combining (5) and (6), the following relationship is obtained: 
         [0000]      2 A +(δ Va+δVb )* B= 1   (7) 
         [0025]    It is necessary to have another set of equations to determine A and B. To obtain the other two relationships, the charge up and charge down modes can be used. Since δV will be much higher if using the same timing window (T*N), it is possible that the charge pump will operate outside the voltage range. To avoid this problem, it is possible to used a small timing window (T*M) where M&lt;N. In practice, both M, and N can be configurable to obtain the best results. In this case, equation (4) will become the following 
         [0000]    
       
      
       dcc=A+δV*Bm  
      
     
         [0000]      Here,  A =( I+δI )/(2 I+δI ), 
         [0000]        Bm=−C /( T*M *(2 I+δI ))   (8) 
         [0026]    Equation (8) can be rewritten as: 
         [0000]    
       
      
       dcc=A+δV*B*N/M  
      
     
         [0027]    Next, a DC high and low is applied to the charge pump circuits with a timing window of (T*M) and the δ=V is measured as δVc and δVd, respectively. The following equations are measured from (8): 
         [0000]      1= A+δVc*B*N/M    (9) 
         [0000]      0= A+δVd*B*N/M    (10) 
         [0028]    From (9) and (10), the following relationship is obtained: 
         [0000]        B=M /( N *(δ Vc−δVd ))   (11) 
         [0029]    Substituting (11) into (7), the value for A can be obtained as: 
         [0000]        A= 0.5−( M/ 2 N )*(δ Va+δVb )/(δ Vc−δVd )   (12) 
         [0000]    Substituting (11) and (12) into (5), the dcc of the original clock is obtained as: 
         [0000]        dcc= 0.5−( M/ 2 N )*(δ Va+δVb )/(δ Vc−δVd )+ M/N*δVa /(δ Vc−δVd )   (13) 
         [0030]    Therefore, dcc of the clock can be simply extracted by measuring δVa, δVb, δVc, and δVd. M/N is a configurable constant. No reference clock is needed for calibration. 
         [0031]    Referring again to  FIG. 2 , the clock signal, clk, is provided to multiplexers  202  and  204  and to a control and clock counter module  206 . The clk signal is also provided to an inverter  208  that is operable to generate inverted clk signals as inputs to multiplexers  202  and  204 . In addition to the clk and inverted clk signals, the multiplexers  202  and  204  are also provide with vdd and gnd signals. The various output voltages obtained using the processing sequences discussed hereinabove are measured using the capacitor voltage at node  210 . 
         [0032]    The duty cycle measurement system  108  can be used to measure the clock duty cycle using the following sequence: First, Vc node  210  is initialized to “vdd/2” by activating transistor and allowing current, Iinit, to pass through the capacitor, C, thereby increasing the voltage, Vc, at node  210 . When the voltage at node  210  reaches Vdd/2, comparator  214  generates a “true” output signal and OR gate  216  then generates a “true” output signal that turns off transistor  212 . The initial Vc, equal to Vdd/2 is read from the output of the unity gain buffer  211 . Next, the test clock is applied to the charge pump with timing window of (T*N) and Vc node  210  is read to obtain δVa. Next, the complement of the test clock is applied to the charge pump with timing window of (T*N) and Vc is read at node  210  to obtain δVb. Next, Vdd is applied to the charge pump with timing window of (T*M) and Vc is read at node  210  to obtain δVc. Next, gnd is applied to the charge pump with timing window of (T*M) and Vc is read at node  210  to obtain δVd. The dcc of the clock is then calculated using the values of δVa, δVb, δVc, and δVd, in formula (13) discussed above. 
         [0033]    It should be noted that the non-zero term for (δVa+δVb) in step (2) and (3) is caused by the combination of current mismatch and transient current overshoot and undershoot, but the relative contribution of transient current mismatch is relatively small. For this reason, this dcc measurement method gives best results when transient current overshoot and undershoot are minimal. 
         [0034]    As an example, the operation of the duty cycle measurement system  108  was simulated using the following parameters:
       C=24 pF,   N=50,   M=5,   I=150 uA,   δI=−10 uA,       
 
         [0040]    Using the procedure discussed above, the following readings were obtained using the methodology discussed above for a 1 Ghz, 40% duty cycle clock:
       (1) Vc=752 mV   (2) Vc=789 mV and δVa=37 mV   (3) Vc=681 mV, and δVb=−71 mV   (4) Vc=721 mV, δVc=−31 mV   (5) Vc=772 mV and δVd=29 mV       
 
         [0046]    Substituting the above-referenced voltages into formula (13) provides a resulting dcc of 41%. 
         [0047]      FIG. 3  is a chart illustrating control signal settings for various operational modes of the duty cycle measurement system  108  in accordance with embodiments of the invention. 
         [0048]      FIG. 4  is an illustrative process flow chart of steps for implementing embodiments of the on-chip clock duty cycle measurement system and method. In step  402  the “init_ctl_b” signal is asserted from high to low to start initialization of Vc. In step  404  the counter is reset and the Iinit gate is turned off after Vc is charged to VDD/2. In step  406 , Vc is read and the clk mode is started. In step  408 , “Init_done” is signaled and “set_ctl” enables the counter and starts the timing window “N+T.” In step  410 , the “carry 1” signal is used to close the timing window and to set the charge pump to tristate. In step  412 , Vc is read and delta_Va is obtained therefrom. Steps  404 - 412  are then repeated to obtain the values for delta_Vb, delta_Vc, and delta_Vd. Processing then proceeds to step  418  where dcc is calculated using the formulas discussed hereinabove. 
         [0049]    The method to calculate dcc using the embodiments described herein is very simple to implement in a manufacturing environment. It only requires high impedance voltage meters and software programming can be used to make it entirely automatic. 
         [0050]    Although the described exemplary embodiments disclosed herein are directed to various examples of improved systems and methods for measuring a clock duty cycle without using a reference clock for calibration, the present invention is not necessarily limited to the example embodiments. Thus, the particular embodiments disclosed above are illustrative only and should not be taken as limitations upon the present invention, as the invention may be modified and practiced in different but equivalent manners apparent to those skilled in the art having the benefit of the teachings herein. Accordingly, the foregoing description is not intended to limit the invention to the particular form set forth, but on the contrary, is intended to cover such alternatives, modifications and equivalents as may be included within the spirit and scope of the invention as defined by the appended claims so that those skilled in the art should understand that they can make various changes, substitutions and alterations without departing from the spirit and scope of the invention in its broadest form. 
         [0051]    Benefits, other advantages, and solutions to problems have been described above with regard to specific embodiments. However, the benefits, advantages, solutions to problems, and any element(s) that may cause any benefit, advantage, or solution to occur or become more pronounced are not to be construed as a critical, required, or essential feature or element of any or all the claims. As used herein, the terms “comprises,” “comprising,” or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus.