mirror of
https://github.com/zebrajr/pytorch.git
synced 2025-12-07 12:21:27 +01:00
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/29143 THP_CORE macro is a very old macro that appeared to have served two purposes: 1. The torch-python equivalent of CAFFE2_BUILD_MAIN_LIB, to toggle symbol visibility headers 2. Some sort of ad hoc way of hiding certain definitions from headers so external clients can't get at them. It did (2) in a very confusing manner, because we set THP_CORE in both torch and torch-python (it shouldn't do anything in torch). In this PR I just get rid of use case (2) entirely (so everything shows up in headers all the time), and then redo (1) using a new THP_BUILD_MAIN_LIB macro. This cleans up some of the macro definitions and makes my life easier for working on #27215. Signed-off-by: Edward Z. Yang <ezyang@fb.com> Test Plan: Imported from OSS Differential Revision: D18309594 Pulled By: ezyang fbshipit-source-id: adcb6d7cb387cd818480137e2b94e5e761dbfefc
19 lines
421 B
C
19 lines
421 B
C
#ifndef THCP_H
|
|
#define THCP_H
|
|
|
|
#include <torch/csrc/python_headers.h>
|
|
#include <TH/TH.h>
|
|
#include <THC/THC.h>
|
|
#include <TH/THHalf.h>
|
|
#include <THC/THCTensor.hpp>
|
|
|
|
#include <torch/csrc/THP.h>
|
|
#include <torch/csrc/cuda/serialization.h>
|
|
#include <torch/csrc/cuda/Module.h>
|
|
#include <torch/csrc/cuda/Storage.h>
|
|
#include <torch/csrc/cuda/Stream.h>
|
|
#include <torch/csrc/cuda/Event.h>
|
|
#include <torch/csrc/cuda/utils.h>
|
|
|
|
#endif
|