IP Library › Granted Patent US 11,579,960
Granted Patent B2
US 11,579,960 · App. 17/507,158 · Granted Feb 14, 2023

Chip fault diagnosis method, chip fault diagnosis device, computer-readable storage medium and electronic equipment

Inventor: Bin Zhang (Shanghai, CN)
Assignee: Horizon (Shanghai) Artificial Intelligence Technology Co., Ltd.
G06F11/079G06F11/0706G06F11/0751G06F11/0772
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 11,579,960
App. No.
17/507,158
Granted
Feb 14, 2023
Kind
B2
Abstract

The present disclosure provides a chip fault diagnosis method, which includes: determining an interrupt flag of an interrupt flag register based on first data identifying an interrupt state in the interrupt flag register; and determining a fault state of chip interrupt corresponding to the interrupt flag based on the interrupt flag. By adopting the technical solution provided by the present disclosure, a fault of the interrupt can be diagnosed in time, and the interrupt can be processed in time.

Claims (64)

1. A chip fault diagnosis method, including:

determining an interrupt flag of an interrupt flag register based on first data identifying an interrupt state in the interrupt flag register; and

determining a fault state of a chip interrupt corresponding to the interrupt flag based on the interrupt flag,

wherein the determining a fault state of a chip interrupt corresponding to the interrupt flag based on the interrupt flag includes:

determining a state type of the interrupt flag, wherein the state type of the interrupt flag includes a first state type identifying an interrupt occurrence state and a second state type identifying an interrupt enabling state; and

if the first state type indicates a set state type, querying the second state type;

if the second state type indicates an enabled state type, determining the fault state of the chip interrupt corresponding to the interrupt flag to be that the interrupt has not failed; and

if the second state type indicates a disenabled state type, determining the fault state of the chip interrupt corresponding to the interrupt flag to be that the interrupt has failed.

2. The method according to claim 1 ,

wherein the determining the fault state of the chip interrupt corresponding to the interrupt flag based on the state type of the interrupt flag further includes:

if the first state type indicates an unset state type, determining the fault state of the chip interrupt corresponding to the interrupt flag to be that the interrupt has failed.

3. The method according to claim 2 , wherein before the determining an interrupt flag of an interrupt flag register based on first data identifying an interrupt state in the interrupt flag register, the method includes: querying the first data identifying the interrupt state in the interrupt flag register based on a predetermined time interval;

the determining the fault state of the chip interrupt corresponding to the interrupt flag based on the first state type includes:

if the first state type indicates a set state type, querying the second state type; and

determining the fault state of the chip interrupt corresponding to the interrupt flag based on the second state type, and processing the interrupt by a non-interrupt program according to a predetermined processing mode.

4. The method according to claim 3 , wherein the determining the fault state of the chip interrupt corresponding to the interrupt flag based on the second state type, and processing the interrupt by a non-interrupt program according to a predetermined processing mode includes:

querying second data identifying a number of times for querying the second state type in the interrupt fault counter if the second state type indicates an enabled state type;

determining a number of times that the enabled state type has been continuously queried based on the second data;

determining the fault state of the chip interrupt corresponding to the interrupt flag based on a comparison result between the number of times that the enabled state type has been continuously queried and a predetermined threshold, and processing the interrupt by the non-interrupt program according to the predetermined processing mode.

5. The method according to claim 1 , wherein the first data refers to data set in a preset field in the interrupt flag register, which changes based on the chip interrupt; and

the interrupt flag is a flag corresponding to the first data, and indicates whether an interrupt has occurred at present.

6. A non-transitory computer-readable storage medium, which stores a computer program used for executing a chip fault diagnosis method including:

determining an interrupt flag of an interrupt flag register based on first data identifying an interrupt state in the interrupt flag register; and

determining a fault state of a chip interrupt corresponding to the interrupt flag based on the interrupt flag,

wherein the determining a fault state of a chip interrupt corresponding to the interrupt flag based on the interrupt flag includes:

determining a state type of the interrupt flag, wherein the state type of the interrupt flag includes a first state type identifying an interrupt occurrence state and a second state type identifying an interrupt enabling state; and

if the first state type indicates a set state type, querying the second state type;

if the second state type indicates an enabled state type, determining the fault state of the chip interrupt corresponding to the interrupt flag to be that the interrupt has not failed;

if the second state type indicates a disenabled state type, determining the fault state of the chip interrupt corresponding to the interrupt flag to be that the interrupt has failed.

7. The non-transitory computer-readable storage medium according to claim 6 , wherein

the determining the fault state of the chip interrupt corresponding to the interrupt flag based on the state type of the interrupt flag further includes:

if the first state type indicates an unset state type, determining the fault state of the chip interrupt corresponding to the interrupt flag to be that the interrupt has failed.

8. The non-transitory computer-readable storage medium according to claim 7 , wherein before the determining an interrupt flag of an interrupt flag register based on first data identifying an interrupt state in the interrupt flag register, the method includes: querying the first data identifying the interrupt state in the interrupt flag register based on a predetermined time interval;

the determining the fault state of the chip interrupt corresponding to the interrupt flag based on the first state type includes:

if the first state type indicates a set state type, querying the second state type; and

determining the fault state of the chip interrupt corresponding to the interrupt flag based on the second state type, and processing the interrupt by a non-interrupt program according to a predetermined processing mode.

9. The non-transitory computer-readable storage medium according to claim 8 , wherein the determining the fault state of the chip interrupt corresponding to the interrupt flag based on the second state type, and processing the interrupt by a non-interrupt program according to a predetermined processing mode includes:

querying second data identifying a number of times for querying the second state type in the interrupt fault counter if the second state type indicates an enabled state type;

determining a number of times that the enabled state type has been continuously queried based on the second data;

determining the fault state of the chip interrupt corresponding to the interrupt flag based on a comparison result between the number of times that the enabled state type has been continuously queried and a predetermined threshold, and processing the interrupt by the non-interrupt program according to the predetermined processing mode.

10. The non-transitory computer-readable storage medium according to claim 6 , wherein the first data refers to data set in a preset field in the interrupt flag register, which changes based on the chip interrupt; and

the interrupt flag is a flag corresponding to the first data, and it indicates whether an interrupt has occurred at present.

11. Electronic equipment, including:

a processor; and

a memory for storing a processor-executable instruction,

wherein the processor is used for reading the executable instruction from the memory and executing a chip fault diagnosis method including:

determining an interrupt flag of an interrupt flag register based on first data identifying an interrupt state in the interrupt flag register; and

determining a fault state of a chip interrupt corresponding to the interrupt flag based on the interrupt flag,

wherein the determining a fault state of a chip interrupt corresponding to the interrupt flag based on the interrupt flag includes:

determining a state type of the interrupt flag, wherein the state type of the interrupt flag includes a first state type identifying an interrupt occurrence state and a second state type identifying an interrupt enabling state; and

if the first state type indicates a set state type, querying the second state type;

if the second state type indicates an enabled state type, determining the fault state of the chip interrupt corresponding to the interrupt flag to be that the interrupt has not failed;

if the second state type indicates a disenabled state type, determining the fault state of the chip interrupt corresponding to the interrupt flag to be that the interrupt has failed.

12. The electronic equipment according to claim 11 , wherein

the determining the fault state of the chip interrupt corresponding to the interrupt flag based on the state type of the interrupt flag further includes:

if the first state type indicates an unset state type, determining the fault state of the chip interrupt corresponding to the interrupt flag to be that the interrupt has failed.

13. The electronic equipment according to claim 12 , wherein before the determining an interrupt flag of an interrupt flag register based on first data identifying an interrupt state in the interrupt flag register, the method includes: querying the first data identifying the interrupt state in the interrupt flag register based on a predetermined time interval;

the determining the fault state of the chip interrupt corresponding to the interrupt flag based on the first state type includes:

if the first state type indicates a set state type, querying the second state type; and

determining the fault state of the chip interrupt corresponding to the interrupt flag based on the second state type, and processing the interrupt by a non-interrupt program according to a predetermined processing mode.

14. The electronic equipment according to claim 13 , wherein the determining the fault state of the chip interrupt corresponding to the interrupt flag based on the second state type, and processing the interrupt by a non-interrupt program according to a predetermined processing mode includes:

querying second data identifying a number of times for querying the second state type in the interrupt fault counter if the second state type indicates an enabled state type;

determining a number of times that the enabled state type has been continuously queried based on the second data;

determining the fault state of the chip interrupt corresponding to the interrupt flag based on a comparison result between the number of times that the enabled state type has been continuously queried and a predetermined threshold, and processing the interrupt by the non-interrupt program according to the predetermined processing mode.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Oct 25, 2021
From: ZHANG, BIN
To: HORIZON (SHANGHAI) ARTIFICIAL INTELLIGENCE TECHNOLOGY CO., LTD.
Reel/Frame 057900/0949 →
Priority Claims (1)
CN 202011143874.4 · Oct 22, 2020 · national
Continuity (1)
Related Publication 20220129338A1 · Apr 28, 2022