1. A method in a processor having a plurality of hardware resources comprising: on at least one clock cycle: setting a mode of the processor, the mode being one of a virtual function mode or a physical function mode; if the mode of the processor is set to the virtual function mode, determining a plurality of virtual functions corresponding to the virtual function mode; wherein the virtual functions are configured to share the plurality of hardware resources among the plurality of virtual functions; and assigning each work store of a plurality of work stores into one of a plurality of virtual functions; assigning the plurality of work stores into one physical function if the mode of the processor is set to the physical function mode; on each clock cycle: releasing any idle hardware resource to be available for any virtual function or physical function; and dispatching work from any work store corresponding to any virtual function or physical function to any released hardware resources; dispatching including arbitrating the work within each of the plurality of virtual functions to nominate corresponding work units and arbitrating among each of the corresponding work units to select a work unit for dispatch if the mode is set to the virtual function mode or arbitrating the work within the physical function to select a work unit for dispatch if the mode is set to the physical function mode.