1 | /******************************************************************************* |
2 | * Copyright 2018-2022 Intel Corporation |
3 | * |
4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
5 | * you may not use this file except in compliance with the License. |
6 | * You may obtain a copy of the License at |
7 | * |
8 | * http://www.apache.org/licenses/LICENSE-2.0 |
9 | * |
10 | * Unless required by applicable law or agreed to in writing, software |
11 | * distributed under the License is distributed on an "AS IS" BASIS, |
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
13 | * See the License for the specific language governing permissions and |
14 | * limitations under the License. |
15 | *******************************************************************************/ |
16 | |
17 | #include "dnnl_common.hpp" |
18 | #include "dnnl_debug.hpp" |
19 | |
20 | #include "shuffle/shuffle.hpp" |
21 | |
22 | namespace shuffle { |
23 | |
24 | std::ostream &operator<<(std::ostream &s, const prb_t &prb) { |
25 | dump_global_params(s); |
26 | settings_t def; |
27 | |
28 | if (canonical || prb.dir != def.dir[0]) s << "--dir=" << prb.dir << " " ; |
29 | if (canonical || prb.dt != def.dt[0]) s << "--dt=" << prb.dt << " " ; |
30 | if (canonical || prb.tag != def.tag[0]) s << "--tag=" << prb.tag << " " ; |
31 | if (canonical || prb.group != def.group[0]) |
32 | s << "--group=" << prb.group << " " ; |
33 | if (canonical || prb.axis != def.axis[0]) s << "--axis=" << prb.axis << " " ; |
34 | |
35 | s << prb.attr; |
36 | if (canonical || prb.ctx_init != def.ctx_init[0]) |
37 | s << "--ctx-init=" << prb.ctx_init << " " ; |
38 | if (canonical || prb.ctx_exe != def.ctx_exe[0]) |
39 | s << "--ctx-exe=" << prb.ctx_exe << " " ; |
40 | |
41 | s << static_cast<prb_dims_t>(prb); |
42 | |
43 | return s; |
44 | } |
45 | |
46 | } // namespace shuffle |
47 | |