RTL Design · Medium · SystemVerilog

Interrupt Controller

Combine UART, GPIO and timer interrupt requests into one CPU interrupt plus a cause code.

Task

Use fixed priority TIMER > UART > GPIO. Cause values are 3,2,1 respectively and zero when no interrupt is pending.

Examples

Constraints

What this problem is testing

A strong answer translates the requirement into synthesizable state and combinational logic, states reset and update semantics precisely, and handles boundary conditions rather than only the nominal case.

Interview habit: before coding, state reset behavior, the state that must be stored, and the conditions that update each output.

Verification plan

Common mistakes

Interview follow-up questions

Concepts to review

SoC, interrupts, priority encoder

Open Interrupt Controller in the HDLForge interactive editor.

Related problems

Explore the RTL Design Practice & Interview Preparation hub.

Continue practising