[Profiler][Minor] Group and consolidate stub APIs (#85510)

There is a concept in profiler of a stub that wraps a profiling API. It was introduced for CUDA profiling before Kineto, and ITT has adopted it to call into VTune APIs. However for the most part we don't really interact with them when developing the PyTorch profiler.

Thus it makes sense to unify the fallback registration mechanism and create a subfolder to free up real estate in the top level `torch/csrc/profiler` directory.

Differential Revision: [D39108647](https://our.internmc.facebook.com/intern/diff/D39108647/)
Pull Request resolved: https://github.com/pytorch/pytorch/pull/85510
Approved by: https://github.com/aaronenyeshi
This commit is contained in:
Taylor Robie
2022-10-13 07:48:58 -07:00
committed by PyTorch MergeBot
parent bc4ca4c2c4
commit b8f14b7877
15 changed files with 144 additions and 180 deletions

View File

@ -1,6 +1,6 @@
#include <c10/macros/Export.h>
#include <ittnotify.h>
#include <torch/csrc/profiler/api.h>
#include <torch/csrc/profiler/stubs/base.h>
namespace torch {
namespace profiler {