Added InstructionBuffer class as a thread safe queue