Extension from the single-measurement vector (SMV) problem to the multiple-measurement vectors (MMV) problem is critical for compressed sensing (CS) in many applications. By increasing the number of measurement vectors, a k-jointly-sparse signal can be recovered with less stringent requirements on the signal sparsity. Simultaneous orthogonal matching pursuit (SOMP), an MMV extension of the orthogonal matching pursuit (OMP) algorithm, is a widely used algorithm for the MMV problem. We noticed that for the SMV problems, the subspace pursuit (SP) algorithm outperforms OMP, so it was expected that the extension of SP to its MMV version, called simultaneous subspace pursuit (SSP) here, will easily outperform SOMP. However, we found that this direct approach does not allow the signal recovery rate to scale with the increase in the number of measurement vectors. To circumvent this, in this paper we propose the generalized subspace pursuit (GSP) algorithm, in which the number of columns to be selected in each of subspace pursuit iteration is properly chosen. Extensive simulation results confirm that the proposed GSP algorithm outperforms SOMP and SSP under various sampling matrix settings with noiseless and noisy measurements. In addition, we show the restricted isometry property (RIP)-guarantee that leads to the convergence of the proposed GSP algorithm and the uniqueness of the recovered signal.