// RUN: mlir-hlo-opt %s -inline | FileCheck %s // Test case: Basic test of inlining into xla_hlo.while. // CHECK-LABEL: func @caller // CHECK: "xla_hlo.while"{{.*}}( { // CHECK: }, { // CHECK: "xla_hlo.exponential" // CHECK: }) // CHECK-LABEL: func @callee func @caller(%arg0: tensor, %pred: tensor) -> tensor { %0 = "xla_hlo.while"(%arg0) ( { ^entry(%unused: tensor): "xla_hlo.return"(%pred) : (tensor) -> () }, { ^entry(%0: tensor): %1 = call @callee(%0) : (tensor) -> (tensor) "xla_hlo.return"(%1) : (tensor) -> () } ) : (tensor) -> (tensor) return %0 : tensor } func @callee(%arg0: tensor) -> tensor { %0 = "xla_hlo.exponential"(%arg0) : (tensor) -> tensor return %0 : tensor }