Implemented instruction parsing function.