A computer-implemented method for performing a matrix multiplication operation, wherein the method comprises obtaining , a matrix B1, a matrix A2, and an index matrix, wherein the matrix A2 includes a plurality of elements that were selected from a matrix A1, wherein the index matrix comprises a plurality of indexes indicating where the plurality of elements of the matrix A2 are located in the matrix A1, the matrix B1 is a matrix with k rows and n columns, the matrix A2 is a matrix with m rows and t columns, the index matrix is a matrix with m rows and t columns, the matrix A1 is a matrix with m rows and k columns, k, n, m, and t are all positive integers, and t is less than or equal to k; selecting , elements corresponding to the indexes of the index matrix from the matrix B1 to generate m matrices B2, the m matrices B2 are all matrices with t rows and n columns, the m matrices B2 are in a one-to-one correspondence with the m rows of the index matrix in sequence, t rows of each matrix B2 are in a one-to-one correspondence with t elements in a corresponding row of the index matrix in sequence, and each row of each matrix B2 is a row indicated in the matrix B1 by a corresponding element in the index matrix; and performing , the matrix multiplication operation based on the matrix A2 and the m matrices B2 in parallel, wherein the m rows of the matrix A2 are in a one-to-one correspondence with the m rows of the matrix A1 in sequence, and elements in each row of the matrix A2 comprise all non-zero elements in groups that are sequentially arranged in a corresponding row of the matrix A1, wherein the m rows of the index matrix are in a one-to-one correspondence with the m rows of the matrix A2 in sequence, and elements in each row of the index matrix are column indexes, in the matrix A1, of all elements that are sequentially arranged in a corresponding row of the matrix A2. obtaining , a matrix B1, a matrix A2, and an index matrix, wherein the matrix A2 includes a plurality of elements that were selected from a matrix A1, wherein the index matrix comprises a plurality of indexes indicating where the plurality of elements of the matrix A2 are located in the matrix A1, the matrix B1 is a matrix with k rows and n columns, the matrix A2 is a matrix with m rows and t columns, the index matrix is a matrix with m rows and t columns, the matrix A1 is a matrix with m rows and k columns, k, n, m, and t are all positive integers, and t is less than or equal to k; selecting , elements corresponding to the indexes of the index matrix from the matrix B1 to generate m matrices B2, the m matrices B2 are all matrices with t rows and n columns, the m matrices B2 are in a one-to-one correspondence with the m rows of the index matrix in sequence, t rows of each matrix B2 are in a one-to-one correspondence with t elements in a corresponding row of the index matrix in sequence, and each row of each matrix B2 is a row indicated in the matrix B1 by a corresponding element in the index matrix; and performing , the matrix multiplication operation based on the matrix A2 and the m matrices B2 in parallel, wherein the m rows of the matrix A2 are in a one-to-one correspondence with the m rows of the matrix A1 in sequence, and elements in each row of the matrix A2 comprise all non-zero elements in groups that are sequentially arranged in a corresponding row of the matrix A1, wherein the m rows of the index matrix are in a one-to-one correspondence with the m rows of the matrix A2 in sequence, and elements in each row of the index matrix are column indexes, in the matrix A1, of all elements that are sequentially arranged in a corresponding row of the matrix A2. <EOS>