mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
Summary: explicit torch::nativert namespace usage + // manual declarations Test Plan: ci Rollback Plan: Differential Revision: D77328855 Pull Request resolved: https://github.com/pytorch/pytorch/pull/156919 Approved by: https://github.com/zhxchen17
30 lines
714 B
C++
30 lines
714 B
C++
#pragma once
|
|
|
|
#include <ATen/core/dispatch/Dispatcher.h>
|
|
#include <ATen/core/function_schema.h>
|
|
#include <c10/core/Device.h>
|
|
|
|
#include <torch/nativert/executor/ExecutionFrame.h>
|
|
#include <torch/nativert/executor/OpKernel.h>
|
|
|
|
namespace torch::nativert {
|
|
|
|
class UnsafeAutoFunctionalizeKernel : public OpKernel {
|
|
public:
|
|
UnsafeAutoFunctionalizeKernel() = delete; // deleted default constructor
|
|
UnsafeAutoFunctionalizeKernel(const Node* node);
|
|
|
|
void computeInternal(ExecutionFrame& executionFrame) const override final;
|
|
|
|
private:
|
|
c10::OperatorHandle op_;
|
|
c10::FunctionSchema schema_;
|
|
|
|
Arguments arguments_;
|
|
|
|
std::vector<Value*> mutatingInputArgs_;
|
|
int numOutputs_;
|
|
};
|
|
|
|
} // namespace torch::nativert
|