After discussion in comments of my other answer I did some investigation and found this interesting 5 years old article form Eric Lippert. It says
[...] In particular, be careful of “xor”. It is very common to combine hash codes together by xoring them, but that is not necessarily a good thing. Suppose you have a data structure that contains strings for shipping address and home address. Even if the hash algorithm on the individual strings is really good, if the two strings are frequently the same then xoring their hashes together is frequently going to produce zero. “xor” can create or exacerbate distribution problems when there is redundancy in data structures. [..]
Therefore XOR seems not to be the best solution for combining hash codes in general. Not sure if that is true in your case because the quality of the hash functions depends on the distribution of the data.
However, if XOR is still to slow, you could try to simplify the hash function. Of course, that will increases the number of collisions, but probably it performs better than a GetHashCode method that is much slower than Equals.
You could try something like that for example:
public static int GetHashCode(long[] array)
{
if (array == null) return 0;
if (array.Length == 0) return -1;
unchecked
{
int hash = 17;
hash = 31 * hash + array[0].GetHashCode();
hash = 31 * hash + array[array.Length/2].GetHashCode();
hash = 31 * hash + array[array.Length-1].GetHashCode();
hash = 31 * hash + array.Length;
return hash;
}
}