LOW POWER AND AREA CLOCK MONITORING CIRCUIT USING RING DELAY ARRANGEMENT

Circuitry and a method of operating a clock monitoring circuit for monitoring a clock signal is disclosed. The method comprises generating a train of pulses corresponding to a duration of respective phases of a clock signal, counting a number of pulses in respective generated pulse trains, determining (using the number of pulses) when durations of subsequent phases of the clock signal lengthen, determining (using the number of pulses) when durations of the subsequent phases of the clock signal shorten, and providing a clock abnormality detect (CAD) signal when the clock signal either lengthens or shortens. The number of pulses in each respective pulse train is indicative of the duration of the respective phases of the clock signal.

TECHNICAL FIELD

This application is directed, in general, to monitoring clock signals and, more specifically, to detecting abnormalities in those clock signals.

BACKGROUND

Most digital systems rely on a clock signal in order to function. For example, virtually all modern computing platforms-such as, e.g., mobile devices, desktop computers, and rack-mounted compute nodes in data centers-depend on a system clock signal to execute instructions that enable them to perform their intended functions.

A typical system clock signal can be generated by a circuit that includes a quartz crystal to ensure very accurate and stable oscillations. When properly functioning, the clock signal oscillates between two opposite state phases corresponding, respectively, to a “high” voltage level (e.g., a “high” state or a “high” phase) and a “low” voltage level (e.g., a “low” state or a “low” phase). Usually a clock signal oscillates at a fixed clock frequency, in which a single oscillation cycle corresponds to a fixed clock period having a duration that depends on the fixed clock frequency and includes both the high phase and low phase. In most digital systems, the clock signal is designed to oscillate with a 50% duty cycle. That is, during each clock cycle, the clock signal is designed to exhibit a stable high phase for one half of the clock period and a stable low phase for the other half of the clock period. These states repeat in a strictly alternating fashion from one clock cycle to the next. In some digital systems, the clock signal may be designed to oscillate with a duty cycle other than 50%.

In any such digital systems, one type of clock abnormality occurs when the clock stops oscillating entirely (e.g., a clock “stop”). Another type of clock abnormality occurs when the clock exhibits a duty cycle other than the expected duty cycle (e.g., a clock “glitch”). Other clock abnormalities occur, e.g., when a clock cycle is missed or when the clock frequency increases or decreases. Any of these clock abnormalities can be cause for concern in a digital system because their occurrence may cause the digital system to behave unexpectedly. These abnormalities can occur naturally, e.g., influenced by physical phenomena impingement on the clock signals. Additionally, these abnormalities can occur as a result of a malicious intended alteration of the clock signals which create vulnerabilities to security attacks that are designed to exploit the clock timing of the digital system.

It is desirable, therefore, to detect clock abnormalities if and when they occur and to respond to them quickly.

SUMMARY

In one aspect, a clock monitoring circuit for monitoring a clock signal is disclosed. In one embodiment, the clock monitoring circuit comprises two ring pulse generators, two n-bit counters each connected to a respective one of the two ring pulse generators, a clock slow detection (CSD) circuit, a clock fast detection (CFD) circuit, and a logic circuit. Each ring pulse generator is configured to generate a train of pulses corresponding to a duration of separate phases of a clock signal. Each of the two n-bit counters is configured to count a number of pulses in respective pulse trains generated by the two ring pulse generators where a count of the number of pulses in each respective pulse train is indicative of a duration of the respective phases of the clock signal. The CSD circuit is configured to assert a CSD signal when durations of subsequent phases of the clock signal lengthen. The CFD circuit is configured to assert a CFD signal when durations of subsequent phases of the clock signal shorten. The logic circuit is configured to provide a clock abnormality detect (CAD) signal when either the CSD signal or the CFD signal is asserted.

In another aspect, an integrated circuit (IC) is disclosed. The IC comprises at least one processing subsystem and at least one clock monitoring circuit for monitoring a clock signal coupled to the at least on processing subsystem and a clock signal externally generated from the IC or a plurality of clock signals generated internal to the IC. In one embodiment, the clock monitoring circuit comprises two ring pulse generators, two n-bit counters each connected to a respective one of the two ring pulse generators, a clock slow detection (CSD) circuit, a clock fast detection (CFD) circuit, and a logic circuit. Each ring pulse generator is configured to generate a train of pulses corresponding to a duration of respective phases of the clock signal. Each of the two n-bit counters is configured to count a number of pulses in respective pulse trains generated by the two ring pulse generators where a count of the number of pulses in each respective pulse train is indicative of a duration of the respective phases of the clock. The CSD circuit is configured to assert a CSD signal when durations of subsequent phases of the clock signal lengthen. The CFD circuit is configured to assert a CFD signal when durations of subsequent phases of the clock signal shorten. The logic circuit is configured to provide a clock abnormality detect (CAD) signal when either the CSD signal or the CFD signal is asserted.

In another aspect, a method of operating a clock monitoring circuit for monitoring a clock signal is disclosed. The method comprises generating a train of pulses corresponding to a duration of respective phases of a clock signal, counting a number of pulses in respective generated pulse trains, determining (using the number of pulses) when durations of subsequent phases of the clock signal lengthen, determining (using the number of pulses) when durations of the subsequent phases of the clock signal shorten, and providing a clock abnormality detect (CAD) signal when the clock signal either lengthens or shortens. The number of pulses in each respective pulse train is indicative of the duration of the respective phases of the clock signal.

In another aspect, a method of manufacturing an integrated circuit (IC) for monitoring a clock signal is disclosed. The method comprises forming two ring pulse generators, two n-bit counters, a clock slow detection (CSD) circuit, a clock fast detection (CFD) circuit, and a logic function. Each of the two ring pulse generators is configured to generate a train of pulses corresponding to a duration of respective phases of a clock signal. Each of the two n-bit counters is connected to a respective one of the two ring pulse generators and each is configured to count a number of pulses in respective pulse trains generated by the two ring pulse generators where a count of number of pulses in each respective pulse train is indicative of a duration of the respective phases of the clock signal. The CSD circuit is configured to assert a CSD signal when durations of subsequent phases of the clock signal lengthen. The CFD circuit is configured to assert a CFD signal when durations of subsequent phases of the clock signal shorten. The logic function is configured to provide a clock abnormality detect (CAD) signal when either the CSD signal or the CFD signal is asserted.

In another aspect, an autonomous machine is disclosed. The autonomous machine comprises at least one processing subsystem and at least one clock monitoring circuit for monitoring a clock signal coupled to the at least one processing subsystem and a clock signal externally generated from the IC or a plurality of clock signals generated internal to the IC In one embodiment, the clock monitoring circuit comprises two ring pulse generators, two n-bit counters, a clock slow detection (CSD) circuit, a clock fast detection (CFD) circuit, and a logic function. Each of the two ring pulse generators is configured to generate a train of pulses corresponding to a duration of respective phases of a clock signal. Each of the two n-bit counters is connected to a respective one of the two ring pulse generators and each is configured to count a number of pulses in respective pulse trains generated by the two ring pulse generators where a count of number of pulses in each respective pulse train is indicative of a duration of the respective phases of the clock signal. The CSD circuit is configured to assert a CSD signal when durations of subsequent phases of the clock signal lengthen. The CFD circuit is configured to assert a CFD signal when durations of subsequent phases of the clock signal shorten. The logic function is configured to provide a clock abnormality detect (CAD) signal when either the CSD signal or the CFD signal is asserted.

In another aspect, a clock monitoring circuit for monitoring a clock signal is disclosed. In one embodiment, the clock monitoring circuit comprises two ring pulse generators, separate n-bit counters, and a logic circuit. Each of the two ring pulse generators is configured to generate a train of pulses corresponding to a duration of respective phases of the clock signal. Each of the separate n-bit counters is connected to a respective one of the two ring pulse generators and each is configured to count a number of pulses in respective pulse trains generated by the two ring pulse generators, where a count of the number of pulses in each respective pulse train is indicative of a duration of the respective phases of the clock signal. The logic circuit is configured to provide a clock abnormality detect (CAD) signal when durations of subsequent phases of the clock signal lengthen or shorten according to the count of the number of the pulses.

DETAILED DESCRIPTION

As noted above, most digital systems rely on a clock to provide at least one clock signal so that the digital systems, e.g., mobile devices, desktop computers, and rack-mounted compute nodes in data centers, execute instructions that enable them to perform their intended functions. Typically this clock consists of a circuit including a quartz crystal external to processors of the digital system. Additionally, a clock signal generated by this external circuit employing the quartz crystal can be used to internally generate a number of other clock signals for use by the processors of the digital system, e.g., by using phase-locked loop (PLL) circuits to generate PLL clocks used by the processors of the digital system. In most instances, a plurality of clock signals must be generated for the digital system.

In some cases, the external clock circuit can be physically accessed, allowing for manipulation of the clock signal generated by the external clock circuit. An entity, e.g., a hacker, can maliciously alter the clock signal thereby causing the above-noted clock abnormalities. As a result, the hacker can access the digital system by this malicious manipulation of the clock signal thereby creating security concerns for the digital system.

In other scenarios, the clock signals generated by the external circuit utilizing the quartz crystal and/or the internal clock signals, e.g., the PLL clocks generated by the internal PLLs, can be influenced by physical phenomena, e.g., gamma rays impinging on the clock signals which can cause the above-noted clock abnormalities, much like the hacker can cause the clock abnormalities as described above. In digital systems where safety is significantly important, the clock signals, either the externally generated clocks signals or the internally generated clock signals, such as the PLL clock signals, or both, must be verified to be free of any influence from natural phenomena influences. Examples of such digital systems where safety is significantly important are autonomous driving computing platforms, robotic systems, and autonomous vision computing platforms. In some cases various industry standards for clock signal integrity need to be met. For example, in autonomous driving applications, conformance to the ISO 26262 standard is required in many instances.

In at least both cases above, i.e., the security concerns to avoid malicious influence on clock signals input to digital systems and the safety concerns to avoid natural phenomena influence on clock signals externally provided to or internally generated by digital systems, monitoring of the clock signals is desired to determine if the clock signal is as expected or not, i.e., to detect the above-noted clock abnormalities, where the monitoring of the clock signal can yield an alert if there is a difference between the received clock signal and an expected clock signal. Further, it is desired that no false positive alerts are generated by the monitoring of the clock signals and that the monitoring of the clock signals is reliable, detecting the clock abnormalities in every instance. Additionally, it is necessary that the monitoring of each of the clock signals can be implemented using a very small area of silicon with a very low consumption of power and works without post-silicon tuning. And lastly, it would be advantageous that a same design for monitoring the clock signals can be effective over a broad range of operating frequencies, e.g., from about 32 kHz to over 800 MHz without significant alteration.

This disclosure provides a low power and area clock monitoring circuit using a ring delay arrangement, a system employing the circuit, a method of operating the circuit, and a method of manufacturing the circuit to monitor a clock signal for the above-noted clock abnormalities. The disclosed clock monitoring circuit takes up very little area of silicon, e.g., in some embodiments an area savings of up to 96% as compared to conventional clock monitoring circuits can be achieved with similar quality metrics. The disclosed clock monitoring circuit consumes very little power, e.g., in some embodiments a power savings of up to 50% as compared to conventional clock monitoring circuits can be achieved with similar quality metrics.

The disclosed low power and area clock monitoring circuit includes at least a pair ring pulse generators. Each of the ring pulse generators include a plurality of edge detectors. The edge detectors can be, e.g., conventional edge detector circuits. A clock signal, e.g., the external clock signal or one of the internal PLL clock signals disclosed above, is input to a first of the plurality of edge detectors of a first of the at least two ring pulse generators. An inverse of the clock signal is input to a first of the edge detectors of the second of the at least two ring pulse generators. These clock signals oscillate between two opposite state phases corresponding, e.g., to the “high” phase and a “low” phase disclosed above at a fixed clock frequency, in which a single oscillation cycle corresponds to a fixed clock period having a duration that depends on the fixed clock frequency and is the sum of a duration of the high phase and low phase of the two opposite state phases of the clock signal. In the first ring pulse generator, the first of the edge detectors generates a first pulse with a unit pulse width of a first pulse train upon detecting an edge of the clock signal input to the ring pulse generator where the edge of the clock signal input to the ring pulse generator is a falling edge or rising edge. The output of the first edge detector of the ring pulse generator is fed to a second edge detector of the first ring pulse generator, much like the clock signal input to the first edge detector of the first ring pulse generator.

As with the first edge detector, the second edge detector generates a pulse with the unit pulse width of a second pulse train upon detecting an edge received from the first edge detector. In some embodiments, the second (and subsequent) edge detector generates a pulse of differing pulse widths rather than the unit pulse width. Moreover, as with the first edge detector, the second edge detector generates its pulse upon detecting either a falling or rising edge. As with the first edge detector of the ring pulse generator, the output of the second edge detector of the ring pulse generator is fed to a third edge detector of the first ring pulse generator. The third edge detector generates a pulse with the unit pulse width or, in some embodiments, with a differing pulse width, of a third pulse train upon detecting an edge of the pulse from the second edge detector where the edge can be either a falling or rising edge.

At this point, the pulse generated by the third edge detector is fed back to the first edge detector, thereby implementing the ring delay arrangement, whereupon the first edge detector generates a subsequent pulse of the unit pulse width of the first pulse train upon detecting an edge of the pulse generated by the third edge detector fed back to the first edge detector. In some embodiments, the width of the subsequent pulse of first pulse train generated by the first edge detector is of a same pulse width as the first generated pulse or, in other embodiments, the subsequent pulse generated by the first edge detector is of a different pulse width from the first generated pulse width. The output of the first edge detector is input to the second edge detector to generate in a similar manner a subsequent pulse of the second pulse train and the output of the second edge detector is input to the third edge detector to generate in a similar manner a subsequent pulse of the third pulse train. Of course, while this example describes three edge detectors in the first ring pulse generator generating three separate pulse trains, the first ring pulse generator may include any number of edge detectors generating any number of separate pulse trains. This process continues until the first ring pulse generator detects another edge of the clock signal input to the ring pulse generator.

A detection resolution of the duration of either of the low or high phases of the clock signal being monitored by the clock monitoring circuit is determined by both a width of the pulses in each of the pulse trains generated by edge detectors of either ring pulse generator, e.g., the unit pulse width, and a number of edge detectors in each of the ring pulse generators. For example, a shorter pulse width of the generated pulse trains and a larger number of edge detectors in the ring pulse generate will yield a greater resolution of the duration of either the low or high phases of the clock signal being monitored by the clock monitoring circuit. As there conventionally is some nominal variation of clock signals, care must be taken in considering the detection resolution and a corresponding design of the ring pulse generators in order to prevent false positive alerts.

The low power and area clock monitoring circuit further includes a counter circuit that comprises two n-bit counters. One of the pulse trains from the first ring pulse generator (e.g., for the low phase of the clock signal input to the clock monitoring circuit) is selected to be input to a first one of the two n-bit counters of the counter circuit and one of the pulse trains from second ring pulse generator (e.g., for the high phase of the clock signal input to the clock monitoring circuit) is selected to be input to a second one of the two n-bit counters of the counter circuit. The first n-bit counter counts a number of pulses for, e.g., the low phase of the clock signal input to the clock monitoring circuit, i.e., a low phase count (“LPC”). The second n-bit counter counts a number of pulses for, e.g., the high phase of the clock signal input to the clock monitoring circuit, i.e., a high phase count (“HPC”).

The LPC and HPC of the n-bit counters are employed to determine if the clock signal has slowed (i.e., the duration of a subsequent phase of the clock signal input to the clock monitoring circuit is longer) and if the clock signal has sped up (i.e., the duration of a subsequent phase of the clock signal input to the clock monitoring circuit is shorter). These detections are performed by circuits of the low power and area clock monitoring circuit. For example, a clock slow detect (“CSD”) circuit determines if the clock signal input to the clock monitoring circuit has slowed and, e.g., a clock fast detect (“CFD”) circuit determines if the clock signal input to the clock monitoring circuit has sped up.

The above-disclosed low power and area clock monitoring circuit detects the above-defined clock abnormalities, specifically, missed single clock pulses, shorter pulses, longer pulses, glitches, and, importantly, cycle to cycle variation of the clock signal. Moreover, the above-disclosed low power and area clock monitoring circuit does not generate false positive alerts and detects clock abnormalities for every clock cycle. The above-disclosed low power and area clock monitoring circuit requires significantly smaller area and has significantly smaller power consumption requirements than conventional clock monitoring circuits. As such, many of the above-disclosed low power and area clock monitoring circuits can be deployed on a single integrated circuit (IC) to monitor many different clock signals and, thus, clock signals at many different locations on the IC may be monitored at a same time as well. The above-disclosed low power and area clock monitoring circuit does not require silicon tuning after deployment. And the above-disclosed low power and area clock monitoring circuit can operate with very slow clocks, e.g., 32 kHz clocks and with very high clock frequencies, e.g., 800 MHz clocks in a small area with only a change in a width of the above-described counter/comparator circuits to account for the differing clock frequencies. Moreover, the above-disclosed low power and area clock monitoring circuit can also detect supply voltage glitches and over voltage supply voltage conditions.

Instances of the above-disclosed clock monitoring circuit can be deployed on an IC, each instance deployed to monitor one of a plurality of clocks used in the IC. The clock signal being monitored can be the above-described clock signal generated by clock circuit external to the IC that includes the quartz crystal. Or the clock signal being monitored can be clocks generated internally in the IC by, e.g., PLL generated PLL clocks. The externally generated clock signals and/or the internally generated clock signals are supplied to various processing subsystems of the IC. Examples of the subsystems of the IC can be one or more central processing units (“CPUs”), one or more graphics processing units (“GPUs”), one or more memory controllers, or any other subsystems that are typically present in a computing device. The CAD signal generated by the clock monitoring circuit on the IC can be input to the various processing subsystems of the IC where the various processing subsystems act on the CAD signal. For example, for the above-mentioned security concerns, some or all of the various processing subsystems could reset upon receipt of the CAD signal. And, e.g., for the above-mentioned safety concerns some or all of the various processing subsystems could log instances of the CAD signal and, in some instances, reset the various processing subsystems.

Referring to the drawings, specificallyFIG.1is a block diagram illustrating an example of a low power and area clock monitoring circuit using a ring delay arrangement100, otherwise termed as a clock abnormality detector (CAD). A clock signal110to be monitored by the CAD, e.g., the clock signal generated by an external circuit employing the quartz crystal or one of the clock signals internally generated by the PLL circuits as disclosed above, are input to the CAD100. When the CAD100detects one of the above-disclosed clock anomalies, e.g., missed single clock pulses, shorter pulses, longer pulses, glitches, and cycle to cycle variation of the clock signal, the CAD100outputs a clock abnormality detect signal (CAD signal)120. Typically, voltage supplied to CAD100is a VDD130voltage supply and, further, the CAD100is typically connected to ground (GND) return path140.

FIG.2illustrates a block diagram of an example system200utilizing the clock monitoring circuit100ofFIG.1. System200can be the above disclosed mobile devices, desktop computers, rack-mounted compute nodes in data centers, autonomous driving computing platforms, robotic systems, and autonomous vision computing platforms, etc. System200includes a clock circuit210which generates clock signal230. Clock signal230can be, e.g., the clock signal generated by an external circuit employing the quartz crystal or one of the clock signals internally generated by the PLL circuits as disclosed above, similar to clock110ofFIG.1. Clock signal230is fed to clock abnormality detector (CAD)220which is similar to CAD100ofFIG.1. System200also includes a plurality of subsystems such as subsystem1250, subsystem2260, through subsystem n270as depicted inFIG.2. Subsystems1-ncorrespond to, e.g., the various processing subsystems disclosed above, e.g., the one or more central processing units (“CPUs”), one or more graphics processing units (“GPUs”), one or more memory controllers, or any other subsystems that are typically present in a computing device. Clock signal230is also fed to subsystems1-n(e.g., subsystems250,260,270).

As with CAD100ofFIG.1, CAD220ofFIG.2detects clock abnormalities, e.g., one of the above-disclosed clock anomalies, e.g., missed single clock pulses, shorter pulses, longer pulses, glitches, and cycle to cycle variation of the clock signal. When CAD220detects one or more of these clock anomalies, CAD220generates CAD signal240which is fed back to subsystems1-n(e.g., subsystems250,260,270). When one or more of subsystems250,260,270receives CAD signal230from CAD220, the one or more subsystem can, e.g., reset the subsystem (typically, e.g., in the above-disclosed security concerns) or log instances of the CAD signal240(typically, e.g., in the above-disclosed safety concerns). Of course, the subsystems250,260,270, when receiving the CAD signal240from CAD220can perform other operations.

Clock signals such as those disclosed above may take a variety of forms.FIG.3illustrates an example clock signal300. Clock signal300exhibits a cycle305during normal operation. A clock cycle corresponds to one clock period. A duration of the clock period for a given clock signal depends on a frequency at which the clock signal oscillates. For example, a clock signal oscillating at a frequency of 1 GHz exhibits 109cycles per second and exhibits a clock period having a duration of 10−9seconds.

As disclosed above, each clock cycle305includes two opposite-state phases310/315in the sense that one of them corresponds to a clock state having a “high” voltage level (a “high phase” or “high clock state”) while the other corresponds to a clock state having a “low” voltage level (a “low phase” or “low clock state”). As used herein, “high” and “low” are relative terms. A high voltage level may be, but need not be, e.g., substantially equal to a voltage supply level, e.g., VDD. A low voltage level may be, but need not be, substantially equal to a ground voltage. A high voltage level may correspond to, e.g., a Boolean “true” value while a low voltage may correspond to, e.g., a Boolean “false” level or vice versa, depending on a design convention used for a given system.

Each phase of a clock signal has a start or a beginning and each phase has an end. For example, high phase310, as depicted inFIG.3has a start or beginning320and an end325. Similarly, low phase315has a start or beginning325and an end330. A clock “edge” as used herein refers to a transition from one clock state, or clock phase, to another in a clock cycle. A clock edge may have one of two directions depending on whether the corresponding transition is from a low state (or phase) to a high state (or phase), e.g., a “rising edge” or from a high state (or phase) to a low state (or phase), e.g., a “falling edge.” For example, the beginning320of clock phase310corresponds to a rising edge of clock signal300and the end325of clock phase310corresponds to a falling edge of clock signal300. In clock signals that oscillate between opposite-state phases, the end of a previous phase may be equivalent to the start or beginning of a subsequent phase that immediately follows the previous phase. In embodiments, the start or beginning of any clock phase may be detected using a variety of techniques such as by detecting a clock edge, or by sensing a high or a low voltage level in the clock signal, or both.

The phrase “duty cycle” as used herein refers to a ratio between a high phase duration for a clock signal and the cycle period for the clock signal. Clock signal300is an example of a clock signal having a 50% duty cycle since each of opposite-state phases310,315has the same duration. Thus, the duration of high phase310is half that of cycle period305. “Phase instance” as used herein refers to any one occurrence of any phase of a clock signal. For purposes of illustration, six phase instances of clock signal300are labeled inFIG.3. High phase310represents a first phase instance of clock signal300and low phase315represents a second phase instance of clock signal300. Similarly, phases335,340,345, and350represent third, fourth, fifth, and sixth phase instances of clock signal300, respectively. In this sense, clock signal300represents a series of clock phase instances. Moreover, phases310,335, and345correspond to first, second, and third instances of the high phase of clock signal300, while phases315,340, and350correspond to first, second, and third instances of the low phase of clock signal300.

FIG.4illustrates a block diagram of another example of the clock monitoring circuit ofFIG.1. Similar to the low power and area clock monitoring circuit with ring delay arrangement disclosed above (and similar to CAD100ofFIG.1and CAD220ofFIG.2), clock monitoring circuit400includes first ring pulse generator415, second ring pulse generator420, low phase count (LPC) counter425, high phase count (HPC) counter430, clock slow detect (CSD) circuit435, clock fast detect (CFD) circuit440, and logic function445. As disclosed above and detailed below, clock monitoring circuit400receives both a clock input signal (CLK)405and its inverse signal (CLK)410. This clock signal405(and its inverse410) is similar to that disclosed above, e.g., either a clock signal generated by an external circuit that includes a quartz crystal or an internally PLL generated clock signal. As disclosed below, clock monitoring circuit400outputs a clock abnormality signal450which indicates if there is an abnormality, e.g., one of the clock anomalies disclosed above, in the CLK signal405.

FIG.5illustrates a block diagram500of an example of first ring pulse generator415of the clock monitoring circuit400ofFIG.4. Block diagram500ofFIG.5also illustrates an example of second ring pulse generator420ofFIG.4(except that its input is the inverse of the CLK signal, e.g.,CLK). Of course, other circuit configurations could be used to implement the functionality of ring pulse generators415or420.

Clock signal (CLK)505is input to ring pulse generator500. Clock signal505is similar to CLK signal110ofFIG.1, CLK signal230ofFIG.2, CLK signal300ofFIG.3, and CLK signal405ofFIG.4(orCLK410). CLK signal505is input to a first logic function, e.g., first OR-gate510of ring pulse generator500. The output of first OR-gate510is fed to first edge detector (ED)515of ring pulse generator500. The output of first ED515is first pulse train520(ed<0>). Clock signal505is also fed to first high phase extender (HPE)525of ring pulse generator500. First pulse train520and an output of first HPE525are fed to a second logic function, e.g., second OR-gate530of ring pulse generator500. The output of second or-gate530is fed to second edge detector535of ring pulse generator500. The output of second ED535is second pulse train540(ed<1>). The output of second OR-gate530is also fed to second HPE545of ring pulse generator500. Second pulse train540and an output from second HPE545are fed to a third logic function, e.g., third OR-gate550of ring pulse detector500. The output of third OR-gate550is fed to third edge detector555of ring pulse generator500. The output of third ED555is third pulse train560(ed<2>). Third pulse train560is fed back as another input to first OR-gate510. Second pulse train540is output from ring pulse generator500.

Ring pulse generator500, as disclosed above, includes three edge detectors. In other embodiments, ring pulse generator could include 1, 2, 4, or more edge detectors. Furthermore, ring pulse generator500, as disclosed above, outputs second pulse train540. In other embodiments, ring pulse generator500outputs first pulse train520or third pulse train560rather than second pulse train540. Moreover, in other embodiments of ring pulse generator500with more than three edge detectors, a pulse train from any one of the more than three edge detectors are output from ring pulse generator500.

As disclosed above, a detection resolution of the duration of either a high phase or low phases of the clock signal being monitored by the clock monitoring circuit is determined by the number of edge detectors in the ring pulse generator and a larger number of edge detectors in the ring pulse generate will yield a greater resolution of the duration of either the low or high phases of the clock signal being monitored by the clock monitoring circuit.

FIG.6illustrates a block diagram600of, e.g., any of the edge detectors515,535,555ofFIG.5. Edge detector600is configured to detect a falling edge of a clock signal input to ED600. A block diagram for an edge detector detecting a rising edge of a clock signal input to the edge detector is of similar structure. Of course, other circuit configurations could be used to implement the functionality of edge detector600(to detect either a falling or rising edge of a clock signal input to the edge detector).

A signal input to edge detector600, e.g., input610, from, e.g., OR-gate510,530, or550ofFIG.5is fed to delay element620and an input of logic function640, e.g., NOR-gate640. The output of delay element620is fed to inverter630. The output of inverter630is fed to another input of logic function640, e.g., NOR-gate640. The output of logic function640, e.g., NOR-gate640is output650of edge detector600. As depicted in the associated timing diagram ofFIG.6, the structure of edge detector600disclosed above functions to assert a high signal on the output of edge detector600for a duration of ta upon detection of a falling edge of a signal input to edge detector600. The width of ta is based on the electrical characteristics of delay element620, inverter630, and logic function640, e.g., NOR-gate640.

FIG.7illustrates a block diagram700of an example of, e.g., either of HPE525or HPE545ofFIG.5. Of course other circuit configurations could be used to implement the functionality of HPE700. A signal input to HPE700, e.g., input710from, e.g., CLK505or second OR-gate530ofFIG.5is fed to delay element720and an input of logic function730, e.g., OR-gate730. The output of delay element720is fed to another input of OR-gate730. The output740of OR-gate730is the output of HPE700.

In an example of operation of the disclosed first ring pulse generator of the low power and area clock monitoring circuit, e.g., ring pulse generator415ofFIG.4or ring pulse generator500ofFIG.5as disclosed above, when the first ring pulse generator detects a falling edge (810) of the clock signal input thereto (depicted by arrow815), a first edge detector of the first ring pulse generator, e.g., edge detector515ofFIG.5, outputs a first pulse of a first pulse train, e.g., first pulse train520ofFIG.5or first pulse train820ofFIG.8(ed<0>), with a unit pulse width, e.g., unit pulse width825. A second edge detector of the first ring pulse generator, e.g., edge detector535ofFIG.5, outputs a first pulse of a second pulse train, e.g., second pulse train540ofFIG.5or second pulse train840ofFIG.8(ed<1>), with unit pulse width, e.g., unit pulse width825, upon detecting a falling edge of the first pulse of the first pulse train received from the first edge detector (depicted by arrow830). A third edge detector of the first ring pulse generator, e.g., edge detector555ofFIG.5, outputs a first pulse of a third pulse train, e.g., third pulse train560ofFIG.5or third pulse train860ofFIG.8(ed<2>), with a unit pulse width, e.g., unit pulse width825, upon detecting a falling edge of the first pulse second pulse train received from the second edge detector (depicted by arrow835).

Then, the first edge detector of the first ring pulse generator, e.g., edge detector515ofFIG.5, generates a subsequent pulse of the first pulse train with a unit pulse width, e.g., unit pulse width825, upon detecting a falling edge of the first pulse of the third pulse train received from the third edge detector (depicted by arrow845). The second edge detector of the first ring pulse generator, e.g., edge detector535ofFIG.5, then generates a subsequent pulse of the second pulse train with a unit pulse width, e.g., unit pulse width825, upon detecting a falling edge of the subsequent pulse of the first pulse train received from the first edge detector (depicted by arrow850). The third edge detector of the first ring pulse generator, e.g., edge detector555ofFIG.5, then generates a subsequent pulse of the third pulse train with a unit pulse width, e.g., unit pulse width825, upon detecting a falling edge of the subsequent pulse of the second pulse train received from the second edge detector (depicted by arrow855). This process continues (as depicted by arrows865,870, and875) until the first ring pulse generator detects a rising edge (880) of the clock signal input to the first ring pulse generator. In this example, the first, second and third pulse trains of the first ring pulse generator are generated for a low phase of the clock signal input to the first ring pulse generator.

In a similar manner, a first, second, and third pulse train is generated by the second ring pulse generator of the low power and area clock monitoring circuit, e.g., ring pulse generator420ofFIG.4or ring pulse generator500ofFIG.5as disclosed above. However, this second ring pulse generator generates its first, second, and third pulse trains based on detection by the second ring pulse generator of an edge of an inverse of the clock signal input to the first ring pulse generator, e.g.,CLK. In the example given above, the second ring pulse generator would generate its first, second, and third pulse trains based upon detection of a rising edge of the inverse clock signal input to the second ring pulse generator (inverse of the clock signal input to the first ring pulse generator) and this second ring pulse generator would generate its first, second, and third pulse trains until detection of a falling edge of the inverse clock signal input to the second ring pulse generator. In this example, the first, second and third pulse trains of the second ring pulse generator are generated for a high phase of the clock signal input to the first ring pulse generators.

In most instances, the clock signal input to the second ring pulse generator is the inverse of the clock signal input to the first ring pulse generator. As with the first ring pulse generator, while the above example discloses three edge detectors of the second ring pulse generator generating three separate pulse trains, the second ring pulse generator can include any number of edge detectors to generate any number of separate pulse trains. In some embodiments, the first and second ring pulse generators include a same number of edge detectors and in other embodiments the first and second ring pulse generators include a different number of edge detectors. As with the first ring pulse generator, the second ring pulse generator can generate pulse trains with a same unit pulse width in its respective pulse train or the second ring pulse generator can generate pulse trains with a different unit pulse width in its respective pulse train. And also as with the first ring pulse generator, the second pulse ring generator can generate pulse trains with a same pulse width in each pulse train or the second ring pulse generator can generate differing pulse widths in each pulse train.

FIG.9illustrates a block diagram of an embodiment of counter circuit900constructed according to principles of the disclosure. Counter circuit900includes, in one embodiment, at least two n-bit counters, e.g., counters910and920. A pulse train from a ring pulse generator, e.g., low clock phase ring pulse generator930is input into one of the two n-bit counters of counter circuit900, e.g., low clock phase counter910. Low clock phase ring pulse generator930is similar to first ring pulse generator415ofFIG.4and ring pulse generator500ofFIG.5as disclosed above. In one embodiment, the pulse train from low clock phase ring pulse generator930represents a duration of a low phase of a clock signal, e.g., CLK, input into low clock phase ring pulse generator930where a unit pulse width and a number of pulses of the pulse train from low clock phase ring pulse generator930are indicative of a duration of a low phase of clock signal CLK. As disclosed above, the pulse train from low clock phase ring pulse generator930can be generated by any number of edge detectors contained therein, e.g., pulse trains520,540, or560from edge detectors515,535, or555, respectively ofFIG.5. The output of low clock phase n-bit counter910, e.g., LPC <0:n>950, is a count of pulses for the low phase of clock signal CLK. Low clock phase n-bit counter910is reset at a beginning of the low phase of clock signal CLK. Resetting is delayed until after a last pulse has been counted for pulse train from low clock phase ring pulse generator930.

A pulse train from another ring pulse generator, e.g., high clock phase ring pulse generator940is input into another one of the two n-bit counters of counter circuit900, e.g., high clock phase counter920. Hight clock phase ring pulse generator940is similar to second ring pulse generator420ofFIG.4and ring pulse generator500ofFIG.5as disclosed above. In one embodiment, the pulse train from high clock phase ring pulse generator940represents a duration of a high phase of a clock signal, e.g.,CLK, input into high clock phase ring pulse generator940where a unit pulse width and a number of pulses of the pulse train from high clock phase ring pulse generator940are indicative of a duration of a high phase of clock signalCLK. As disclosed above, the pulse train from high clock phase ring pulse generator940can be generated by any number of edge detectors contained therein, e.g., pulse trains520,540, or560from edge detectors515,535, or555, respectively ofFIG.5. The output of high clock phase n-bit counter920, e.g., HPC <0:n>960, is a count of pulses for the low phase of clock signalCLK. High clock phase n-bit counter920is reset at a beginning of the high phase of clock signalCLK. Resetting is delayed until after a last pulse has been counted for pulse train from high clock phase ring pulse generator940.

Thus, the output from a counter circuit, e.g., counter circuit900, are counts, e.g., LPC<0:n>950and HPC<0:n>960, from two n-bit counters, e.g., low clock phase n-bit counter910and high clock phase n-bit counter920. The counts, e.g., LPC<0:n>950and HPC<0:n>960, each represents a duration of a low phase of a clock signal, e.g., CLK and a high phase of an inverse of clock signal CLK, e.g.,CLK, respectively.

FIG.10illustrates an embodiment of a block diagram for a clock slow detect (CSD) signal generator1000constructed according to principles of the disclosure. In one embodiment of CSD signal generation circuitry1000, a counter value, e.g., LPC<0:n>950ofFIG.9, representative of a count of pulses for a low phase of a clock signal, e.g., a low phase of clock signal CLK405ofFIG.4is input on input1010of CSD signal generator1000and a counter value, e.g., HPC<0:n>960ofFIG.9, representative of a count of pulses for a high phase of a clock signal, e.g., a high phase of clock signalCLK410ofFIG.4, is input on input1020of CSD signal generator1000. Low phase clock counter value, e.g., LPC<0:n>1010, and high phase clock counter value, e.g., HPC<0:n>1020, are input into n-bit comparator1030which compares the counter values. This pulse count value comparison is performed for each cycle of the clock signal. n-bit comparator1030outputs two signals.

One signal is indicative that the low phase clock pulse count is greater than the high phase clock pulse count, e.g., LPC<0:n> is greater than HPC<0:n> signal1040. The other signal output from n-bit comparator1030is indicative that the high phase clock pulse count is greater than the low phase clock pulse count, e.g., HPC<0:n> is greater than LPC<0:n> signal1050. The signal indicative that the low phase clock pulse count is greater than the high phase clock pulse count (i.e., a duration of a low phase of clock signal CLK is greater than a duration of high phase of clock signalCLK), e.g., LPC>HPC signal1040, is input to a first logic function, e.g., AND-gate1060as isCLKsignal. The signal indicative that the high phase clock pulse count is greater than the low phase clock pulse count (i.e., a duration of a high phase of clock signalCLKis greater than a duration of a low phase of clock signal CLK), e.g., HPC>LPC signal1050, is input to a second logic function, e.g., AND-gate1070. An output of the first logic function, e.g., AND-gate1060, and an output of the second logic function, e.g., AND-gate1070, is input into a third logic function, e.g., OR-gate1080. An output of the third logic function, e.g., OR-gate1080, is the above disclosed CSD signal which is indicative that a clock signal has slowed (i.e., the duration of a subsequent phase of the clock signal is longer than the previous phase).

FIG.11illustrates an embodiment of a block diagram for a clock fast detect (CFD) signal generator1100constructed according to principles of the disclosure. In one embodiment of CFD signal generator1100, two signals are input to CFD signal generator1100. One signal, e.g., signal1110, indicates that a high phase clock pulse count is greater than a low phase clock pulse count, e.g., similar to signal1050ofFIG.10(which is indicative that a duration of a low phase of a clock signal, e.g., clock signal CLK is greater than a duration of high phase of an inverse clock signal, e.g., clock signalCLK). Another signal input to clock fast detect (CFD) signal generator1100, e.g., signal1120indicates that a low phase clock pulse count is greater than a low phase clock pulse count, e.g., similar to signal1040ofFIG.1040ofFIG.10(which is indicative that a duration of a high phase of clock signalCLKis greater than a duration of a low phase of clock signal CLK). In one embodiment, these signals are generated by an n-bit comparator as disclosed above with regard toFIG.10.

Signal1110, indicative, e.g., that a high phase clock pulse count is greater than a low phase clock pulse count, is input to a first logic function, e.g., D-type flip-flop1130, as well as clock signal CLK. Signal1120, indicative, e.g., that a low phase clock pulse count is greater than a low phase clock pulse count, is input to a second logic function, e.g., D-type flip-flop1140, as well as clock signalCLK. The outputs of the first logic function, e.g., D-type flip-flop1130, and the second logic function, e.g., D-type flip-flop1140, are input to a third logic function, e.g., OR-gate1150. An output of the third logic function, e.g., OR-gate1150, is the above disclosed CFD signal which is indicative that a clock signal has sped up (i.e., the duration of a subsequent phase of the clock signal is shorter than the previous phase).

FIG.12illustrates an embodiment of a block diagram for a clock abnormality detect (CAD) signal generator1200constructed according to principles of the disclosure. In one embodiment of CAD signal generator1200, a clock slow detect signal, e.g., clock slow detect signal1210, and a clock fast detect signal, e.g., clock fast detect signal1220, are input to a logic function, e.g., OR-gate1230. Clock slow detect signal1210is similar to clock slow detect signal1090ofFIG.10and clock fast detect signal1220is similar to clock fast detect signal1160ofFIG.11. CAD signal generator is similar to logic function445ofFIG.4. CAD signal generator1200outputs a CAD signal, e.g., CAD signal1240, if either a clock slow detect signal (e.g., clock slow detect signal1210) or a clock fast detect signal (e.g., clock fast detect signal1220) is input to CAD signal generator1200. While the CSD and CFD generators1000and1100, respectively, detect when a frequency of the clock signal speeds up or slows down as disclosed above, the CSD and CFD generators1000and1100, respectively, will also detect other types of clock abnormalities, i.e., when clock stops oscillating altogether (a clock stop), when the clock exhibits a duty cycle other than that expected (a clock glitch), when a clock cycle is missed, and when there is a cycle to cycle variation of the clock as in each of these clock abnormalities the LPC will differ from the HPC.

FIG.13illustrates a flow diagram1300of an example method for monitoring a clock signal input to a clock monitoring circuit according to principles of the disclosure. In a step1310, a train of pulses corresponding to a duration of separate phases of a clock signal to be monitored are generated. In a step1320a number of pulses in respective generated pulse trains are counted where the count of the number of pulses in each respective pulse train is indicative of a duration of the separate phases of the clock signal to be monitored. In a step1330, a determination is made when durations of subsequent phases of the clock signal being monitored shorten. In a step1340, a determination if made when durations of subsequent phases of the clock signal being monitored lengthen. In a step1350, a clock abnormality signal is output when the determinations of durations of subsequent phases of the clock signal being monitored lengthen or shorten.