| 141 | |
| 142 | namespace { |
| 143 | bool IsTensorStridesRowMajor(const std::shared_ptr<DataType>& type, |
| 144 | const std::vector<int64_t>& shape, |
| 145 | const std::vector<int64_t>& strides) { |
| 146 | std::vector<int64_t> c_strides; |
| 147 | const auto& fw_type = checked_cast<const FixedWidthType&>(*type); |
| 148 | if (internal::ComputeRowMajorStrides(fw_type, shape, &c_strides).ok()) { |
| 149 | return strides == c_strides; |
| 150 | } else { |
| 151 | return false; |
| 152 | } |
| 153 | } |
| 154 | |
| 155 | bool IsTensorStridesColumnMajor(const std::shared_ptr<DataType>& type, |
| 156 | const std::vector<int64_t>& shape, |
no test coverage detected