Skip to content

Commit cefb9e0

Browse files
author
Ashkan Aliabadi
authored
Update pthreadpool to pthreadpool:029c88620802e1361ccf41d1970bd5b07fd6b7bb. (pytorch#40524) (pytorch#41190)
Summary: Pull Request resolved: pytorch#40524 Reviewed By: ezyang Differential Revision: D22215742 Pulled By: AshkanAliabadi fbshipit-source-id: ef594e0901337a92b21ddd44e554da66c723eb7c
1 parent d9e9e00 commit cefb9e0

15 files changed

+114
-44
lines changed

caffe2/operators/quantized/int8_add_op.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ class Int8AddOp final : public Operator<CPUContext> {
8888
setupStatus == qnnp_status_success,
8989
"failed to setup QNNPACK add operator");
9090

91-
#ifdef FBCODE_CAFFE2
91+
#if defined(FBCODE_CAFFE2) || !defined(USE_INTERNAL_PTHREADPOOL_IMPL)
9292
const qnnp_status runStatus =
9393
qnnp_run_operator(this->qnnpackOperator_, nullptr /* thread pool */);
9494
#else

caffe2/operators/quantized/int8_average_pool_op.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ class Int8AveragePoolOp final : public ConvPoolOpBase<CPUContext> {
8080
setupStatus == qnnp_status_success,
8181
"failed to setup QNNPACK Global Average Pooling operator");
8282

83-
#ifdef FBCODE_CAFFE2
83+
#if defined(FBCODE_CAFFE2) || !defined(USE_INTERNAL_PTHREADPOOL_IMPL)
8484
const qnnp_status runStatus =
8585
qnnp_run_operator(this->qnnpackGlobalOperator_,
8686
nullptr /* thread pool */);
@@ -122,7 +122,7 @@ class Int8AveragePoolOp final : public ConvPoolOpBase<CPUContext> {
122122
setupStatus == qnnp_status_success,
123123
"failed to setup QNNPACK Average Pooling operator");
124124

125-
#ifdef FBCODE_CAFFE2
125+
#if defined(FBCODE_CAFFE2) || !defined(USE_INTERNAL_PTHREADPOOL_IMPL)
126126
const qnnp_status runStatus =
127127
qnnp_run_operator(this->qnnpackOperator_, nullptr /* thread pool */);
128128
#else

caffe2/operators/quantized/int8_channel_shuffle_op.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ class Int8ChannelShuffleOp final : public ConvPoolOpBase<CPUContext> {
7272
setupStatus == qnnp_status_success,
7373
"failed to setup QNNPACK channel shuffle operator");
7474

75-
#ifdef FBCODE_CAFFE2
75+
#if defined(FBCODE_CAFFE2) || !defined(USE_INTERNAL_PTHREADPOOL_IMPL)
7676
const qnnp_status runStatus =
7777
qnnp_run_operator(this->qnnpackOperator_, nullptr /* thread pool */);
7878
#else

caffe2/operators/quantized/int8_conv_op.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ class Int8ConvOp final : public ConvPoolOpBase<CPUContext> {
141141
lastOutputPointer_ = Y->t.template mutable_data<uint8_t>();
142142
}
143143

144-
#ifdef FBCODE_CAFFE2
144+
#if defined(FBCODE_CAFFE2) || !defined(USE_INTERNAL_PTHREADPOOL_IMPL)
145145
const qnnp_status runStatus =
146146
qnnp_run_operator(this->qnnpackObject_, nullptr /* thread pool */);
147147
#else

caffe2/operators/quantized/int8_conv_transpose_op.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ class Int8ConvTransposeOp final : public ConvTransposeUnpoolBase<CPUContext> {
140140
lastOutputPointer_ = Y->t.template mutable_data<uint8_t>();
141141
}
142142

143-
#ifdef FBCODE_CAFFE2
143+
#if defined(FBCODE_CAFFE2) || !defined(USE_INTERNAL_PTHREADPOOL_IMPL)
144144
const qnnp_status runStatus =
145145
qnnp_run_operator(this->qnnpackObject_, nullptr /* thread pool */);
146146
#else

caffe2/operators/quantized/int8_fc_op.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ class Int8FCOp final : public Operator<CPUContext> {
104104
lastOutputPointer_ = Y->t.template mutable_data<uint8_t>();
105105
}
106106

107-
#ifdef FBCODE_CAFFE2
107+
#if defined(FBCODE_CAFFE2) || !defined(USE_INTERNAL_PTHREADPOOL_IMPL)
108108
const qnnp_status runStatus =
109109
qnnp_run_operator(this->qnnpackObject_, nullptr /* thread pool */);
110110
#else

caffe2/operators/quantized/int8_leaky_relu_op.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ class Int8LeakyReluOp final : public Operator<CPUContext> {
8080
setupStatus == qnnp_status_success,
8181
"failed to setup QNNPACK Leaky ReLU operator");
8282

83-
#ifdef FBCODE_CAFFE2
83+
#if defined(FBCODE_CAFFE2) || !defined(USE_INTERNAL_PTHREADPOOL_IMPL)
8484
const qnnp_status runStatus =
8585
qnnp_run_operator(this->qnnpackOperator_, nullptr /* thread pool */);
8686
#else

caffe2/operators/quantized/int8_max_pool_op.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ class Int8MaxPoolOp final : public ConvPoolOpBase<CPUContext> {
7474
setupStatus == qnnp_status_success,
7575
"failed to setup QNNPACK Max Pooling operator");
7676

77-
#ifdef FBCODE_CAFFE2
77+
#if defined(FBCODE_CAFFE2) || !defined(USE_INTERNAL_PTHREADPOOL_IMPL)
7878
const qnnp_status runStatus =
7979
qnnp_run_operator(this->qnnpackOperator_, nullptr /* thread pool */);
8080
#else

caffe2/operators/quantized/int8_relu_op.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ class Int8ReluOp final : public Operator<CPUContext> {
6565
setupStatus == qnnp_status_success,
6666
"failed to setup QNNPACK Clamp operator");
6767

68-
#ifdef FBCODE_CAFFE2
68+
#if defined(FBCODE_CAFFE2) || !defined(USE_INTERNAL_PTHREADPOOL_IMPL)
6969
const qnnp_status runStatus =
7070
qnnp_run_operator(this->qnnpackOperator_, nullptr /* thread pool */);
7171
#else

caffe2/operators/quantized/int8_sigmoid_op.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ class Int8SigmoidOp final : public Operator<CPUContext> {
7373
setupStatus == qnnp_status_success,
7474
"failed to setup QNNPACK Sigmoid operator");
7575

76-
#ifdef FBCODE_CAFFE2
76+
#if defined(FBCODE_CAFFE2) || !defined(USE_INTERNAL_PTHREADPOOL_IMPL)
7777
const qnnp_status runStatus =
7878
qnnp_run_operator(this->qnnpackOperator_, nullptr /* thread pool */);
7979
#else

0 commit comments

Comments
 (0)