A short tes:
x = rand(2240, 94340); % 1.6 GB RAM
y1 = x * x';
xt = x';
y2 = x * xt;
On my i5 mobile chip in R2018b: 15.1 sec versus 28.5 sec. This shows that James' argument of the explicitly transposed matrix has a remarkable effect.
With the original input data [94340 x 2240] the output would need 71.2 GB of RAM and this is more than my laptop has. This might exceed the memory of your computer also.
You did not answer the question, if the matrix is sparse, so if it just some elements differ from zero. If it is full, remember, that the output of X*X' is symmetric. Then half of the 71.2 GB is redundand. If you habe e.g. 64 GB of RAM than using this fact can allow you to run the code efficiently. Unfortunately there are no built-in methods to exploit the symmetry of matrices and you'd have to implement this by your own, at least the matrix multiplication for your code.
@all readers: Is there a standard library to handle full or sparse symmetric matrices efficiently?