# US 2016/0261257 A1 · Timing Prediction Circuit and Method

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2016/0261257 A1
- Document ID: US20160261257A1
- Status: Published application
- Kind: A1
- Application number: 15/057,509
- Filed: 2016-03-01
- Published: 2016-09-08
- Earliest claimed: 2015-03-02
- Assignees: Huawei Technologies Co., Ltd.
- Applicants: Huawei Technologies Co., Ltd.
- Inventors: Tao Huang
- Web page: https://patentgrep.com/patent/US20160261257A1

## CPC

- H03K 5/24: the characteristic being amplitude
- H03K 3/0375: {provided with means for increasing reliability; for protection; for ensuring a predetermined initial state when the supply voltage has been applied; for storing the actual state when the supply voltage fails (digital storage cells each combining volatile and non-volatile storage properties G11C14/00)}
- H03K: PULSE TECHNIQUE (measuring pulse characteristics G01R; modulating sinusoidal oscillations with pulses H03C; transmission of digital information H04L; discriminator circuits detecting phase difference between two signals by counting or integrating cycles of oscillation H03D3/04; automatic control, starting, synchronisation or stabilisation of generators of electronic oscillations or pulses where the type of generator is irrelevant or unspecified H03L; coding, decoding or code conversion, in general H03M)

## Abstract

A timing prediction circuit and method which relate to the field of circuit technologies and may be used to predict a timing margin of a to-be-predicted digital circuit, which are used to resolve a problem that a large quantity of devices are used to predict a probability that a timing error occurs in a to-be-predicted digital circuit. The timing prediction circuit includes a combinational logic circuit, a delay circuit, a sampling circuit, and a control circuit, where the sampling circuit includes N samplers, and an input end of each sampler is separately connected to an output end of the combinational logic circuit using the delay circuit, and an output end of each sampler is connected to an input end of the control circuit, where N is an integer equal, and N≧2. The present invention can be used to predict a timing margin of a to-be-predicted digital circuit.

## Claims

### Claim 1

A timing prediction circuit, comprising:
a combinational logic circuit;
a delay circuit;
a sampling circuit; and
a control circuit,
wherein the sampling circuit comprises N samplers,
wherein an input end of each sampler is separately connected to an output end of the combinational logic circuit using the delay circuit,
wherein an output end of each sampler is connected to an input end of the control circuit,
wherein N is an integer equal, and N≧2,
wherein an input end of the combinational logic circuit is configured to input a prediction signal, wherein the prediction signal is transmitted to the delay circuit using the combinational logic circuit,
wherein the delay circuit is configured to delay the prediction signal transmitted to the delay circuit such that compared with a prediction signal input to another sampler in the N samplers, prediction signals input to N−1 samplers in the N samplers each have a different degree of delay,
wherein the sampler is configured to perform, at a sampling moment, sampling on the prediction signal input to the sampler, to obtain a sampling result, and
wherein the control circuit is configured to determine, according to results of comparison between sampling results of the N samplers and a reference sampling result, whether a timing margin of a to-be-predicted digital circuit needs to be adjusted.

### Claim 2 (depends on 1)

The prediction circuit according to claim 1, wherein the control circuit is further configured to:
determine that the timing margin of the to-be-predicted digital circuit needs to be adjusted when in one working clock cycle, a quantity of sampling results that are same as the reference sampling result in the sampling results of the N samplers are less than or equal to a threshold, and wherein the working clock cycle refers to a working clock cycle of the sampling circuit; and
determine that the timing margin of the to-be-predicted digital circuit needs to be adjusted when in each working clock cycle of multiple working clock cycles that are arranged in chronological order, the quantity of sampling results that are same as the reference sampling result in the sampling results of the N samplers decreases progressively, and wherein the working clock cycle refers to the working clock cycle of the sampling circuit.

### Claim 3 (depends on 1)

The prediction circuit according to claim 1, further comprising a source signal generator, wherein an output end of the source signal generator is connected to the input end of the combinational logic circuit, wherein the source signal generator is configured to generate a periodically flipped prediction signal, and wherein a cycle of the periodically flipped prediction signal is a working clock cycle.

### Claim 4 (depends on 1)

The prediction circuit according to claim 1, wherein compared with a prediction signal input to an (n−1)th sampler in the N samplers, a prediction signal input to an nth sampler in the N samplers has a delay in a preset time period, wherein 2≦n≦N, and wherein n is an integer.

### Claim 5 (depends on 1)

The prediction circuit according to claim 1, further comprising N logical operators connected to the N samplers, wherein one sampler corresponds to one logical operator, wherein the logical operator comprises a first input end, a second input end, and an output end, wherein each first input end is configured to input the reference sampling result, wherein each second input end is connected to the output end of one sampler, wherein the output end of each logical operator is connected to the input end of the control circuit, and wherein the logical operator is configured to compare the sampling result input by the second input of the logical operator and the reference sampling result, to obtain a result of the comparison.

### Claim 6 (depends on 1)

The prediction circuit according to claim 1, wherein the to-be-predicted digital circuit further comprises an internal memory, and wherein the prediction circuit further comprises a second internal memory, wherein a working clock of the second internal memory is synchronized with a working clock of the to-be-predicted digital circuit, wherein a timing margin of a timing path of the second internal memory is less than a timing margin of a timing path of the internal memory, wherein the second internal memory comprises an input end and an output end, wherein the input end of the second internal memory is configured to input to-be-written data, wherein the output end of the second internal memory is connected to the input end of the control circuit, and wherein the control circuit is further configured to determine that the timing margin of the to-be-predicted digital circuit needs to be adjusted when data output by the output end of the second internal memory is different from the to-be-written data.

### Claim 7

A timing prediction method, comprising:
acquiring results of comparison between M sampling results and a reference sampling result, wherein the M sampling results are sampling results obtained by performing, at a sampling moment, sampling on prediction signals having different delays; and
determining, according to the results of comparison, whether a timing margin of a to-be-predicted digital circuit needs to be adjusted.

### Claim 8 (depends on 7)

The method according to claim 7, wherein determining, according to the results of comparison, whether the timing margin of the to-be-predicted digital circuit needs to be adjusted comprises:
determining that the timing margin of the to-be-predicted digital circuit needs to be adjusted when in one working clock cycle, a quantity of sampling results that are the same as the reference sampling result in the M sampling results is less than or equal to a threshold, wherein the working clock cycle refers to the working clock cycle to which the sampling moment belongs; and
determining that the timing margin of the to-be-predicted digital circuit needs to be adjusted when in each working clock cycle of multiple working clock cycles that are arranged in chronological order, the quantity of sampling results that are same as the reference sampling result in the M sampling results decreases progressively, wherein the working clock cycle refers to the working clock cycle to which the sampling moment belongs.

### Claim 9 (depends on 7)

The method according to claim 7, further comprising:
acquiring to-be-written data in a second internal memory and data output by the second internal memory, wherein a working clock of the second internal memory is synchronized with a working clock of the to-be-predicted digital circuit, and wherein a timing margin of a timing path of the second internal memory is less than a timing margin of a timing path of an internal memory; and
determining that the timing margin of the to-be-predicted digital circuit needs to be adjusted when the data output by the second internal memory is different from the to-be-written data.

### Claim 10 (depends on 8)

The method according to claim 8, wherein after determining that the timing margin of the to-be-predicted digital circuit needs to be adjusted, the method further comprises decreasing a working clock frequency of the to-be-predicted digital circuit and/or increasing a working voltage of the to-be-predicted digital circuit.

### Claim 11 (depends on 10)

The method according to claim 10, wherein after decreasing the working clock frequency of the to-be-predicted digital circuit and/or increasing the working voltage of the to-be-predicted digital circuit, the method further comprises:
continuing to decrease the working clock frequency of the to-be-predicted digital circuit and/or increase the working voltage of the to-be-predicted digital circuit when it is determined that the timing margin of the to-be-predicted digital circuit needs to be adjusted; and
increasing the working clock frequency of the to-be-predicted digital circuit and/or decreasing the working voltage of the to-be-predicted digital circuit when it is determined that the timing margin of the to-be-predicted digital circuit does not need to be adjusted.
