Mailbox

*In reply to sreelaxmi:*You should always parameterize your mailbox with the type of item being put/get.

mailbox #(stimulus) m_box;
  function new(mailbox  #(stimulus) m_box);
    this.m_box = m_box;
  endfunction
 

But this is not your problem. You need to show us what you expect to happen to your inputs and you need to show who does the get(). What you are doing does not make much sense. Normally, your class ‘stimulus’ represents one set of values for (opcode,op1,o2) and create an class object for each set. The each object goes onto the mailbox.