Revert " fix missing-prototypes warnings in torch_cpu (Part 4) (#100849)"

This reverts commit c2f28d1c1df0db78f2951e4df5dde264f80f07eb.

Reverted https://github.com/pytorch/pytorch/pull/100849 on behalf of https://github.com/izaitsevfb due to fails internal Meta builds, including fbcode and android, see D46009888: ld.lld: error: undefined symbol: nnc_aten_embedding ([comment](https://github.com/pytorch/pytorch/pull/100849#issuecomment-1555105800))
This commit is contained in:
PyTorch MergeBot
2023-05-19 19:05:11 +00:00
parent 083f304d27
commit 498c34e8e8
137 changed files with 773 additions and 572 deletions

View File

@ -76,7 +76,7 @@ bool allArgsAreTensors(const Node* node) {
// These are rarely-used ops. Disallowing them typically eliminates
// corner cases in graph optimizations, allowing for more aggressive
// optimizations and better performance.
static bool isUnsupportedOp(const Node* node) {
bool isUnsupportedOp(const Node* node) {
auto kind = node->kind();
if (kind != aten::__is__ && kind != aten::__isnot__) {
return false;
@ -1587,7 +1587,7 @@ float BlockRunner::benchmark_model(
(static_cast<float>(main_runs) * static_cast<float>(args_list.size()));
}
static bool display_ivalue(const IValue& iv) {
bool display_ivalue(const IValue& iv) {
if (iv.isTensor()) {
std::cout << "Tensor " << iv.toTensor().toString() << " {";
const auto dims = iv.toTensor().sizes();
@ -1622,7 +1622,7 @@ static bool display_ivalue(const IValue& iv) {
return false;
}
static void display_pnode_info(const ProcessedNode& pnode) {
void display_pnode_info(const ProcessedNode& pnode) {
pnode.node()->print(std::cout, 0, nullptr, false);
const auto num_inputs = static_cast<uint32_t>(pnode.num_inputs());
for (const auto i : c10::irange(num_inputs)) {