split out HDL from Simulator into separate functions