Patent ID: 8219786

Claim:
A method for coalescing fetch requests for multiple data classes, comprising: writing a first fetch request, a second fetch request, and a third fetch request to an instruction stream first-in first-out buffer (FIFO) stored in a first portion of a memory, wherein each of the fetch requests comprises a data class that indicates a type of data and a start location in a second portion of the memory, the second portion of the memory storing a combination of sets of instructions and data to be processed by the sets of instructions; receiving the first fetch request that specifies a first data class; receiving, following the first fetch request, a second fetch request that specifies a second data class; receiving, following the second fetch request, a third fetch request that specifies the first data class and is sequential to the first fetch request; aligning each fetch request to a preferred memory alignment based on a width of the memory to produce aligned fetch requests; unrolling the aligned fetch requests to produce one or more unrolled fetch requests that do not exceed a maximum fetch request size; combining unrolled fetch requests for the first data class to produce a coalesced fetch request for the first data class that is aligned to the preferred memory alignment and does not exceed the maximum fetch request size; fetching first data specified by the coalesced fetch request from a memory; fetching second data specified by the second fetch request from the memory; outputting an instruction stream that includes the first data and the second data ordered according to the first fetch request, the second fetch request, and the third fetch request; storing the first fetch request, second fetch request, and third fetch request in a first local FIFO; popping the first fetch request from the first local FIFO, storing the first fetch request in a first register file that stores fetch requests for the first data class, and also storing the first fetch request in a second local FIFO; popping the second fetch request from the first local FIFO, storing the second fetch request in a second register file that stores fetch requests for the second data class, and storing the second fetch request in the second local FIFO; and popping the third fetch request from the first local FIFO, storing the third fetch request in the first register file, and also storing the third fetch request in the second local FIFO, wherein the first fetch request and third fetch request stored in the first register file are unrolled and combined to produce the coalesced fetch request.