1. In a data processing system in which the structure and operation of a legacy processing unit of a legacy system is emulated by a software program on a host system, a mechanism for improving the performance of the system comprising: A) a function implemented in native machine code running on the host system which performs a function previously implemented as a sequence of legacy instructions as part of the operating system code of the legacy system, where said operating system code includes any code provided by the computer system manufacturer; and B) a mechanism for invoking said function from within the operating system code newly modified for use on the emulated computer system.