1. A method, comprising: partitioning elements of a first matrix into a first partition and a second partition, such that the first partition contains a first group of the elements, and the second partition contains a second group of the elements; reordering the first matrix to generate a second matrix having the same elements as the first matrix; defining a first portion of the second matrix as an area within at least one of the first partition of the first matrix and the second partition of the first matrix; defining a second portion of the second matrix as an area outside of both the first partition of the first matrix and the second partition of the first matrix; processing, by a first set of a plurality of threads, the first portion of the second matrix utilizing a first memory; and processing, by a second set of the plurality of threads, the second portion of the second matrix utilizing a second memory.