VLSI DV Interview Puzzles · All levels

Parameterized Class Puzzles

These puzzles focus on where specialization boundaries matter: static storage, type compatibility, and factory registration with parameterized classes. Interviewers look for precise statements like 'per specialization' vs 'shared through non-parameterized base' backed by predicted outputs.

About this puzzle set

These puzzles focus on where specialization boundaries matter: static storage, type compatibility, and factory registration with parameterized classes. Interviewers look for precise statements like 'per specialization' vs 'shared through non-parameterized base' backed by predicted outputs.

Puzzles in this topic

diagram
1. Global Static vs Per-Specialization Static  [Easy]
2. Same Specialization via typedef Alias  [Medium]
3. Integral Parameter Specializations Split Statics  [Easy]
4. Invariance of Parameterized Type Assignment  [Hard]
5. Static Function Counters Per Specialization  [Medium]
6. Wrong UVM Macro for Parameterized Object  [Hard]

Work each puzzle before reading the solution: predict the exact output or answer, name the rule that governs it, then check yourself.

fork/join variants and completion semantics

diagram
FORK/JOIN INTERVIEW CHEAT MAP

fork
  task_a();   // 3 cycles
  task_b();   // 1 cycle
join
--> parent waits for all children

fork ... join_any
--> parent continues after first child completes

fork ... join_none
--> parent continues immediately; children run detached

Use wait fork; later to synchronize detached threads.

Related topics