Commit a972de2a authored by Benjamin Kramer's avatar Benjamin Kramer Committed by TensorFlower Gardener
Browse files

[XLA:GPU] Output fuse bias adds into dot

TuplePointsToAnalysis already knows how to share the input to the add with the
output of the fusion. If for whatever reason the sharing is not possible, emit
a memcpy from input to output before calling gemm. The change is mostly
straight-forward, there's one complication with the online autotune of gemms.
We allocate a scratch buffer to avoid overwriting the bias during autotune.

This doesn't do anything fancy like trying to combine the scalar mul with the
add. We could do but it doesn't seem to be worth the additional complexity.

PiperOrigin-RevId: 219492278
parent 6cc11dcc
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment