Added function for computing phi instructions.