Skip to question
asic.fyi
DesignVerificationSystemVerilogFirmwareArchitectureInterviews
asic.fyi/Interview questions/Packages

Hardware interview practice

Packages

EasySystemVerilogSystemVerilog

Which statement about word_t is correct?

Try it in the question bankReason first. Then compare.

Keep this exact question selected while you check your answer and review the full solution.

Practice this question →
Starting point

Question code

package p;
  parameter int W = 8;
  typedef logic [W-1:0] word_t;
endpackage
module m; p::word_t x; endmodule
Choose one

Answer choices

  1. A. x is 8 bits, and this package parameter is not overridden per module instance like a module parameter
  2. B. x has implementation-defined width until m is instantiated
  3. C. Each import p::* creates a new specialization of the package
  4. D. x is 32 bits because all parameter-based typedefs use int width
Continue practicing

Related questions

SystemVerilogGenerate loops→SystemVerilogType parameters→
asic.fyi · Learn silicon end to end.info@asic.fyi