Fixed reg file and added test bench