Patent Document ID: 10067910
Application ID: 15201123
Patent Flag: 1

Claim One:
1. A computer-executable method for performing a general matrix-matrix multiplication (GEMM) operation on a graphics processing unit (GPU), comprising: generating, by a computer, a plurality of kernels, wherein a respective kernel of the plurality of kernels is a function compiled for execution on the GPU, and wherein a respective kernel of the plurality of kernels is compiled with a respective maximum register count (MRC) value between zero and a predetermined number representing a maximum number of registers per thread, and wherein a thread performs operations associated with the kernel; maintaining a set of rules, wherein a respective rule includes a mapping between dimensional parameters of respective input matrices of the GEMM operation and a corresponding kernel, wherein the mapping indicates that the corresponding kernel can perform the GEMM operation faster than any other kernel in the plurality of kernels for the dimensional parameters in the mapping based on the MRC value of the corresponding kernel; storing data associated with two matrices in a memory device of the computer based on a row-major order or a column-major order with at least one row or column having no adjacent storage padding, wherein an adjacent storage padding is a set of bits for aligning a start address of the row or column, thereby reducing memory usage on the computer; determining a first set of dimensional parameters of the two matrices; loading a kernel from the plurality of kernels on the GPU for performing the GEMM operation on the GPU by looking up the first set of dimensional parameters in the set of rules; and executing the loaded kernel on the GPU using the two matrices stored in the memory device as parameters, thereby performing the GEMM operation on the two matrices.