From 0f5eac4cd54faac4d94cdad5308e0fb0996a72a1 Mon Sep 17 00:00:00 2001 From: Justin Lebar Date: Tue, 7 May 2019 12:12:41 -0700 Subject: [PATCH] [XLA] Fix comment on asinh implementation. PiperOrigin-RevId: 247066151 --- tensorflow/compiler/xla/client/lib/math.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tensorflow/compiler/xla/client/lib/math.cc b/tensorflow/compiler/xla/client/lib/math.cc index ee70adc6e7d..3061cd6c95b 100644 --- a/tensorflow/compiler/xla/client/lib/math.cc +++ b/tensorflow/compiler/xla/client/lib/math.cc @@ -574,9 +574,9 @@ XlaOp Acosh(XlaOp x) { // If x^2 will overflow and x is positive, we can approximate x + sqrt(x^2 + 1) // as 2*x and return log(2) + log(x). // -// If x is negative, the above would give us some trouble, because we'd need to -// approximate x + sqrt(sqrt(x^2 + 1) - abs(x). But we're saved -// by the fact that asinh(-x) = -asinh(x). +// If x is negative, the above would give us some trouble; we can't approximate +// the result as x + abs(x) = 0! But we're saved by the fact that asinh(-x) = +// -asinh(x). XlaOp Asinh(XlaOp x) { XlaBuilder* b = x.builder(); auto do_it = [&](XlaOp x) -> StatusOr {