|
XORarrayValues being immutable is certainly hurting perf. You should consider making it mutable where it stores the result in one of the inouy buffers or reuse an output buffer.
Memory allocation is expensive and you overdo it. Also the ToArray calls should be avoided if there is any other way to reference the bytes needed as a view or what have you.
|