| 61 | } |
| 62 | |
| 63 | bool ProgramShapesEqual(const ProgramShape& lhs, const ProgramShape& rhs) { |
| 64 | if (lhs.parameters_size() != rhs.parameters_size()) { |
| 65 | return false; |
| 66 | } |
| 67 | for (int i = 0; i < lhs.parameters_size(); i++) { |
| 68 | if (!ShapeUtil::Equal(lhs.parameters(i), rhs.parameters(i))) { |
| 69 | return false; |
| 70 | } |
| 71 | } |
| 72 | return ShapeUtil::Equal(lhs.result(), rhs.result()); |
| 73 | } |
| 74 | |
| 75 | ProgramShape GetProgramShapeWithLayout(const HloModule& module) { |
| 76 | ProgramShape program_shape; |
no test coverage detected