set and get registers and memory cap are now working, and return a
structure composed of the registers and memory caps, instead of a pointer
to a structure.