A method for performing Maximum Likelihood Detector, MLD, preprocessing in a Multiple-Input Multiple-Output, MIMO, communication system, the method comprising, using a processor: obtaining a received signal Y a corresponding channel matrix H and a vector of noise samples n; calculating a whitening filter L -H based on the vector of noise samples n; whitening a channel matrix H̃ using the whitening filter L -H to obtain a whitened channel matrix H̃; estimating a number of MAC operations of a first calculation and a second calculation based on a time domain decimation D_T of calculation of the channel matrix H, a frequency domain decimation D_F of calculation of the channel matrix H, and a number of transmitter antennas M; selecting, one of the first calculation or the second calculation, based on the number of MAC operations of the first calculation and the second calculation so that if the number of MAC operations of the first calculation is smaller than the total estimated number of MAC operations of the second calculation the first calculation is selected and otherwise the second calculation is selected; performing preprocessing of the received signal Y using the selected calculation; and decoding the received signal Y by using the triangular matrix R and Y ̄ ̄ to determine a corresponding transmit signal s, wherein the first calculation comprises: whitening the received signal Y using the whitening filter L -H to obtain a whitened received signal Ỹ and performing a coordinate rotation digital computer, Cordic, based QR decomposition to the whitened channel matrix H̃ and the whitened received signal Ỹ to obtain triangular matrix R of the QR decomposition of the whitened channel matrix H̃ and Y ̄ ̄ = Q H L − H Y, and wherein the second calculation comprises: performing a Cordic based QR decomposition to the whitened channel matrix H̃ and the whitening filter L -H to obtain triangular matrix R of the QR decomposition of the whitened channel matrix H̃ and Q H L -H, and multiplying the received signal Y by Q H L -H to obtain Y ̄ ̄ = Q H L − H Y. obtaining a received signal Y a corresponding channel matrix H and a vector of noise samples n; calculating a whitening filter L -H based on the vector of noise samples n; whitening a channel matrix H̃ using the whitening filter L -H to obtain a whitened channel matrix H̃; estimating a number of MAC operations of a first calculation and a second calculation based on a time domain decimation D_T of calculation of the channel matrix H, a frequency domain decimation D_F of calculation of the channel matrix H, and a number of transmitter antennas M; selecting, one of the first calculation or the second calculation, based on the number of MAC operations of the first calculation and the second calculation so that if the number of MAC operations of the first calculation is smaller than the total estimated number of MAC operations of the second calculation the first calculation is selected and otherwise the second calculation is selected; performing preprocessing of the received signal Y using the selected calculation; and decoding the received signal Y by using the triangular matrix R and Y ̄ ̄ to determine a corresponding transmit signal s, wherein the first calculation comprises: whitening the received signal Y using the whitening filter L -H to obtain a whitened received signal Ỹ and performing a coordinate rotation digital computer, Cordic, based QR decomposition to the whitened channel matrix H̃ and the whitened received signal Ỹ to obtain triangular matrix R of the QR decomposition of the whitened channel matrix H̃ and Y ̄ ̄ = Q H L − H Y, and wherein the second calculation comprises: performing a Cordic based QR decomposition to the whitened channel matrix H̃ and the whitening filter L -H to obtain triangular matrix R of the QR decomposition of the whitened channel matrix H̃ and Q H L -H, and multiplying the received signal Y by Q H L -H to obtain Y ̄ ̄ = Q H L − H Y. performing a Cordic based QR decomposition to the whitened channel matrix H̃ and the whitening filter L -H to obtain triangular matrix R of the QR decomposition of the whitened channel matrix H̃ and Q H L -H, and multiplying the received signal Y by Q H L -H to obtain Y ̄ ̄ = Q H L − H Y.