File tree Expand file tree Collapse file tree 4 files changed +9
-4
lines changed
aten/src/ATen/native/mkldnn/xpu
torch/csrc/api/include/torch Expand file tree Collapse file tree 4 files changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -194,7 +194,7 @@ at::Tensor quantized_convolution(
194194 Tensor scratchpad_tensor = at::empty (
195195 {static_cast <int64_t >(scratchpad_size)},
196196 act.options ().dtype (at::kByte ),
197- c10 ::nullopt );
197+ std ::nullopt );
198198 auto scratchpad_m = make_onednn_memory (
199199 conv_fwd_pd.scratchpad_desc (), engine, scratchpad_tensor.data_ptr ());
200200 args.insert ({DNNL_ARG_SCRATCHPAD, scratchpad_m});
Original file line number Diff line number Diff line change @@ -94,12 +94,12 @@ class QConvoneDNNXPU final {
9494 output,
9595 inv_output_scale,
9696 output_zero_point,
97- /* accum*/ c10 ::nullopt ,
97+ /* accum*/ std ::nullopt ,
9898 /* accum_scale*/ 0.0 ,
9999 /* accum_zero_point*/ 0 ,
100100 /* output_dtype*/ output_dtype,
101- /* binary_attr*/ c10 ::nullopt ,
102- /* binary_alpha*/ c10 ::nullopt ,
101+ /* binary_attr*/ std ::nullopt ,
102+ /* binary_alpha*/ std ::nullopt ,
103103 /* unary_attr*/ attr,
104104 /* unary_scalars*/ scalars,
105105 /* unary_algorithm*/ algorithm);
Original file line number Diff line number Diff line change 99// up builds.
1010
1111namespace c10 {
12+
13+ #if !defined(FBCODE_CAFFE2) && !defined(C10_NODEPRECATED)
1214// NOLINTNEXTLINE(misc-unused-using-decls)
1315using std::bad_optional_access;
1416// NOLINTNEXTLINE(misc-unused-using-decls)
@@ -19,6 +21,7 @@ using std::nullopt;
1921using std::nullopt_t ;
2022// NOLINTNEXTLINE(misc-unused-using-decls)
2123using std::optional;
24+ #endif
2225
2326#if !defined(FBCODE_CAFFE2) && !defined(C10_NODEPRECATED)
2427
Original file line number Diff line number Diff line change @@ -38,8 +38,10 @@ namespace torch {
3838// the `func()` function defined in `at::` namespace is always hidden.
3939using namespace at ; // NOLINT
4040
41+ #if !defined(FBCODE_CAFFE2) && !defined(C10_NODEPRECATED)
4142using std::nullopt ; // NOLINT
4243using std::optional; // NOLINT
44+ #endif
4345
4446using Dtype = at::ScalarType;
4547
You can’t perform that action at this time.
0 commit comments