Suppose the covariance matrix is $V$ (which is n by n) and the weights are $w$ (of length n).
Then the Portfolio Variance is $V_p = w^T V w$
and the Risk Contribution (in terms of variance) of asset $k$ is
$RC_k=w_k \sum_j V[k,j]w_j$
in words this is "the weight of asset k times the inner product of the k-th row of $V$ and the weight vector". (Sometimes ...
I don’t see how just calculation of Portfolio variance would need an invertible var-covar matrix, I mean you don’t even have to use the matrix notation to calculate it. It may be so that lower time frames would output unstable values of the individual variances and pairwise correlations.
However there are certain methods to achieve a stable covariance ...