pytorch/torch/csrc/jit/codegen/fuser/codegen.h
Meghan Lele 6384c2d81b [JIT] clang-format JIT code (#35115)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/35115

This commit runs the newly added tools/clang_format.py on the JIT
codebase and includes all of the formatting changes thus produced.

Testing:
Ran the script, CI.

Test Plan: Imported from OSS

Reviewed By: eellison

Differential Revision: D20568523

Pulled By: SplitInfinity

fbshipit-source-id: e09bdb982ccf090eecfb7c7b461b8d0681eef82b
2020-03-26 11:24:51 -07:00

31 lines
846 B
C++

#pragma once
#include <torch/csrc/WindowsTorchApiMacro.h>
#include <torch/csrc/jit/codegen/fuser/arg_spec.h>
#include <torch/csrc/jit/codegen/fuser/partition_desc.h>
#include <torch/csrc/jit/codegen/fuser/tensor_desc.h>
#include <torch/csrc/jit/ir/ir.h>
#include <iostream>
#include <string>
#include <tuple>
#include <vector>
namespace torch {
namespace jit {
namespace fuser {
// Creates a CPU or CUDA kernel for the given graph.
// Returns the C++ or CUDA string implementing the kernel.
TORCH_API std::string generateKernel(
const std::string& name,
const Graph& graph,
const std::vector<std::pair<const Value*, const c10::optional<TensorDesc>>>&
inputs,
const std::vector<std::pair<const Value*, const TensorDesc>>& outputs,
const bool use_cuda);
} // namespace fuser
} // namespace jit
} // namespace torch