Enzyme
main
Loading...
Searching...
No Matches
MLIR
Implementations
MathAutoDiffOpInterfaceImpl.cpp
Go to the documentation of this file.
1
//===- ArithAutoDiffOpInterfaceImpl.cpp - Interface external model --------===//
2
//
3
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4
// See https://llvm.org/LICENSE.txt for license information.
5
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6
//
7
//===----------------------------------------------------------------------===//
8
//
9
// This file contains the external model implementation of the automatic
10
// differentiation op interfaces for the upstream MLIR arithmetic dialect.
11
//
12
//===----------------------------------------------------------------------===//
13
14
#include "
Implementations/CoreDialectsAutoDiffImplementations.h
"
15
#include "
Interfaces/AutoDiffOpInterface.h
"
16
#include "
Interfaces/GradientUtils.h
"
17
#include "
Interfaces/GradientUtilsReverse.h
"
18
#include "mlir/Dialect/Arith/IR/Arith.h"
19
#include "mlir/Dialect/Complex/IR/Complex.h"
20
#include "mlir/Dialect/Math/IR/Math.h"
21
#include "mlir/IR/DialectRegistry.h"
22
#include "mlir/Support/LogicalResult.h"
23
24
#include "
Dialect/Ops.h
"
25
#include "mlir/IR/TypeSupport.h"
26
27
using namespace
mlir
;
28
using namespace
mlir::enzyme
;
29
30
namespace
{
31
#include "Implementations/MathDerivatives.inc"
32
}
// namespace
33
34
void
mlir::enzyme::registerMathDialectAutoDiffInterface
(
35
DialectRegistry ®istry) {
36
registry.addExtension(+[](MLIRContext *context, math::MathDialect *) {
37
registerInterfaces(context);
38
});
39
}
AutoDiffOpInterface.h
CoreDialectsAutoDiffImplementations.h
GradientUtilsReverse.h
GradientUtils.h
Ops.h
mlir::enzyme
Definition
ActivityAnalysis.h:12
mlir::enzyme::registerMathDialectAutoDiffInterface
void registerMathDialectAutoDiffInterface(DialectRegistry ®istry)
Definition
MathAutoDiffOpInterfaceImpl.cpp:34
mlir
Definition
ActivityAnalysis.h:7
Generated on Fri May 8 2026 19:56:25 for Enzyme by
1.12.0