Home | History | Annotate | Download | only in service

Lines Matching refs:Tuple

87   // Computation is a single parameter passed into a tuple. The parameter should
88 // be copied before entering the tuple.
92 HloInstruction* tuple =
95 EXPECT_THAT(x->users(), UnorderedElementsAre(tuple));
103 op::Tuple(op::Copy(x)));
107 // Computation is a single constant passed into a tuple. The parameter should
108 // be copied before entering the tuple.
112 HloInstruction* tuple =
115 EXPECT_THAT(constant->users(), UnorderedElementsAre(tuple));
124 op::Tuple(op::Copy(constant)));
160 // each constant/parameter is pointed to by the output tuple. Only these
187 op::Tuple(op::Copy(constant2), op::Copy(x), op::Add(constant1, y)));
223 op::Tuple(op::Copy(op::GetTupleElement(old_root)),
272 // Same as BitcastParameter, but the bitcast is wrapped in a tuple.
289 op::Tuple(op::Copy(bitcast)));
294 // nested tuple-shaped parameter. The parameter should be deep copied and the
322 op::Tuple(
323 op::Tuple(
330 // Construct a computation where the root of the computation is a tuple
331 // element of a nested tuple-shaped parameter.
344 // tuple. This element is itself a tuple.
358 op::Tuple(op::Copy(op::GetTupleElement(op::GetTupleElement(param))),
403 // from the tuple parameter, and returns a predicate indicating whether this
423 // Builds a While body computation with one output tuple element dependent on
424 // both input tuple elements.
429 // Tuple(out0, out1)
446 // Use 'induction_variable' in computation with no path to output tuple.
451 // Create output Tuple.
456 // Builds a While body computation with two output tuple elements dependent on
457 // both input tuple elements.
463 // Tuple(out0, out1, out2)
491 // Create output Tuple.
497 // Builds a While body computation with read-only tuple element 0.
502 // Tuple(out0, out1)
516 // Use 'induction_variable' in computation with no path to output tuple.
521 // Create output Tuple.
532 // Tuple(out0, out1)
567 // Create output Tuple.
578 // Builds a While body computation with the following nested tuple
617 // Create output Tuple.
734 auto tuple = xla_while->parent()->AddInstruction(
737 xla_while->parent()->set_root_instruction(tuple);
773 // Tests while body computation with independent tuple elements:
778 // Tuple(out0, out1)
797 op::Tuple(op::Copy(op::Constant()), op::Copy(op::Constant())));
800 // Tests while body computation with dependent tuple elements:
805 // Tuple(out0, out1)
809 // Tuple(Copy(out0), out1)
824 op::Tuple(op::Add(), op::Add(op::GetTupleElement(), op::Broadcast())));
833 op::Tuple(op::Add(op::Copy(), op::Constant()),
838 op::Tuple(op::Copy(op::Constant()), op::Copy(op::Constant())));
841 // Tests while body computation with read-only tuple element 0:
852 // TUPLE (root)
913 // a copy of tuple element 1 (init value is a parameter, and the element is
968 // have a copy of tuple element 1 (the non-read-only element) so each of the
974 op::Tuple(op::Exp(), op::Copy(op::Exp())));
976 op::Tuple(op::Exp(), op::Copy(op::Exp())));
979 // Tests while body computation with nested tuple elements:
990 // actual GTE and Tuple instructions optimized away:
992 // Tuple // old root
1003 // \ Tuple // "inner" tuple.
1006 // Tuple // new root
1031 op::Tuple(op::Add(), op::Tuple(op::Add(), op::Copy(op::Reverse()))));
1035 op::Tuple(op::Add(), op::Tuple(op::Add(), op::Reverse(op::Copy()))));
1041 // init = Tuple(Constant(S32, {}), Constant(F32, {8}))
1053 op::Tuple(op::Copy(op::Constant()), op::Copy(op::Constant())));
1058 // init = Tuple(Constant(S32, {}), Parameter(F32, {8}))
1070 op::Tuple(op::Copy(op::Constant()), op::Copy(op::Parameter())));
1076 // init = Tuple(Constant(S32, {}), Parameter(F32, {8}))
1079 // the actual GTE and Tuple instructions optimized away:
1081 // Tuple // old init
1092 // \ Tuple
1095 // Tuple // new init
1106 op::Tuple(op::Copy(op::Constant()),
1107 op::Tuple(op::Copy(op::GetTupleElement()),
1121 op::Tuple(op::Add(), op::Tuple(op::Copy(op::Add()), op::Add())));
1125 op::Tuple(op::Add(), op::Tuple(op::Add(), op::Copy(op::Add()))));
1131 // init = Tuple(Constant(S32, {}), Tuple({vec_one, vec_one}))
1134 // the actual GTE and Tuple instructions optimized away:
1136 // Tuple // old init
1147 // \ Tuple
1150 // Tuple // new init
1165 op::Tuple(op::Copy(op::Constant()),
1166 op::Tuple(op::Copy(op::Broadcast()), op::Broadcast())));
1170 op::Tuple(op::Copy(op::Constant()),
1171 op::Tuple(op::Broadcast(), op::Copy(op::Broadcast()))));
1185 op::Tuple(op::Add(), op::Tuple(op::Copy(op::Add()), op::Add())));
1189 op::Tuple(op::Add(), op::Tuple(op::Add(), op::Copy(op::Add()))));
1198 // init = Tuple(Constant(S32, {}), init_data))
1210 op::Tuple(op::Copy(op::Constant()), op::Copy(op::Broadcast())));
1215 // init = Tuple(Parameter(S32, {}), Parameter(F32, {8},
1218 // where the second and third parameters are identical *and* the tuple shared
1221 // Verifies that the resulting point-to set is distinct in the resulting Tuple
1223 // insert identical copies to the resulting tuple.
1225 // Loop body that outputs tuple comprises two elements dependent on the init
1226 // tuple.
1246 // Loop init tuple contains two identical parameter buffers.
1251 // Two while loops shares the same loop init tuple.
1273 // The loop bodies pass through elements 1 and 2 in the init tuple, so ideally
1280 op::Tuple(op::Copy(), op::Parameter(), op::Parameter()));
1282 op::Tuple(op::Copy(), op::Parameter(), op::Parameter()));
1286 // Test a while instruction with a body which permutes its tuple parameter
1292 // Body simply interchanges the two tuple elements in the loop state.
1319 auto tuple = builder.AddInstruction(
1322 HloInstruction::CreateWhile(loop_state_shape, condition, body, tuple));
1338 op::Tuple(op::Copy(op::Copy()), op::Copy(op::Copy())));
1341 EXPECT_THAT(xla_while->operand(0), op::Tuple(op::Copy(), op::Copy()));
1345 // Test a while instruction with a body which permutes its tuple parameter
1354 // Body interchanges the two tuple elements in the loop state and negates one
1384 auto tuple = builder.AddInstruction(
1387 HloInstruction::CreateWhile(loop_state_shape, condition, body, tuple));
1401 op::Tuple(op::Copy(op::Negate(op::Copy())), op::Copy(op::Copy())));
1404 EXPECT_THAT(xla_while->operand(0), op::Tuple(op::Copy(), op::Copy()));
1408 // Test a while instruction with a body which permutes it's tuple parameter
1417 // Body simply interchanges the two tuple elements in the loop state.
1442 auto tuple =
1445 HloInstruction::CreateWhile(loop_state_shape, condition, body, tuple));
1455 op::Tuple(op::Copy(), op::Copy()));
1554 EXPECT_THAT(whiles[0]->operand(0), op::Tuple(op::Parameter(), op::Parameter(),
1557 op::Tuple(op::Copy(), op::Copy(), op::GetTupleElement(),
1787 get-tuple-element.18 = (s32[], s32[], s32[]) get-tuple-element(p.1), index=1
1788 get-tuple-element.65 = s32[] get-tuple-element(get-tuple-element.18), index=0
1789 get-tuple-element.66 = s32[] get-tuple-element(get-tuple-element.18), index=1
1790 add.3 = s32[] add(get-tuple-element.65, get-tuple-element.66)
1791 tuple.33 = (s32[]) tuple(add.3)
1792 ROOT tuple.34 = (s32[], (s32[], s32[], s32[]), (s32[])) tuple(constant.3, get-tuple-element.18, tuple.33)
1797 get-tuple-element.67 = s32[] get-tuple-element(p.2), index=0
1799 ROOT equal-to = pred[] equal-to(get-tuple-element.67, constant.4)
1804 get-tuple-element.68 = s32[] get-tuple-element(arg_tuple.4), index=0
1806 add.4 = s32[] add(get-tuple-element.68, constant.7)
1807 get-tuple-element.69 = s32[] get-tuple-element(arg_tuple.4), index=1
1808 get-tuple-element.70 = s32[] get-tuple-element(arg_tuple.4), index=2
1809 less-than-or-equal-to = pred[] less-than-or-equal-to(get-tuple-element.69, get-tuple-element.70)
1812 get-tuple-element.71 = s32[] get-tuple-element(arg_tuple.4), index=3
1813 tuple.35 = (s32[], s32[], s32[]) tuple(get-tuple-element.69, get-tuple-element.71, get-tuple-element.70)
1814 tuple.36 = (s32[]) tuple(constant.8)
1815 tuple.37 = (s32[], (s32[], s32[], s32[]), (s32[])) tuple(select, tuple.35, tuple.36)
1816 while = (s32[], (s32[], s32[], s32[]), (s32[])) while(tuple.37), condition=if-condition.v4, body=if-body.v5
1817 get-tuple-element.72 = (s32[]) get-tuple-element(while), index=2
1818 get-tuple-element.73 = s32[] get-tuple-element(get-tuple-element.72), index=0
1819 ROOT tuple.38 = (s32[], s32[], s32[], s32[]) tuple(add.4, get-tuple-element.69, get-tuple-element.70, get-tuple-element.73)
1824 get-tuple-element.75 = s32[] get-tuple-element(inputs.1), index=0
1826 ROOT less-than.2 = pred[] less-than(get-tuple-element.75, constant.11)
1831 get-tuple-element.76 = s32[] get-tuple-element(arg_tuple.5), index=0
1832 get-tuple-element.77 = s32[] get-tuple-element(arg_tuple.5), index=2
1833 get-tuple-element.78 = s32[] get-tuple-element(arg_tuple.5), index=3
1834 get-tuple-element.79 = s32[] get-tuple-element(arg_tuple.5), index=4
1835 tuple.39 = (s32[], s32[], s32[], s32[]) tuple(get-tuple-element.76, get-tuple-element.77, get-tuple-element.78, get-tuple-element.79)
1836 while.2 = (s32[], s32[], s32[], s32[]) while(tuple.39), condition=cond_wrapper.v3.1, body=_functionalize_body_1__.v28
1837 get-tuple-element.80 = s32[] get-tuple-element(while.2), index=0
1838 get-tuple-element.81 = s32[] get-tuple-element(arg_tuple.5), index=1
1840 add.5 = s32[] add(get-tuple-element.81, constant.12)
1841 get-tuple-element.82 = s32[] get-tuple-element(while.2), index=3
1842 ROOT tuple.40 = (s32[], s32[], s32[], s32[], s32[]) tuple(get-tuple-element.80, add.5, get-tuple-element.77, get-tuple-element.78, get-tuple-element.82)
1847 get-tuple-element.83 = s32[] get-tuple-element(inputs.2), index=1
1849 ROOT less-than.3 = pred[] less-than(get-tuple-element.83, constant.13)
1870 get-tuple-element.18 = (s32[], s32[], s32[]) get-tuple-element(p.1), index=1
1871 get-tuple-element.65 = s32[] get-tuple-element(get-tuple-element.18), index=0
1872 get-tuple-element.66 = s32[] get-tuple-element(get-tuple-element.18), index=1
1873 add.3 = s32[] add(get-tuple-element.65, get-tuple-element.66)
1874 tuple.33 = (s32[]) tuple(add.3)
1875 ROOT tuple.34 = (s32[], (s32[], s32[], s32[]), (s32[])) tuple(constant.3, get-tuple-element.18, tuple.33)
1880 get-tuple-element.67 = s32[] get-tuple-element(p.2), index=0
1882 ROOT equal-to = pred[] equal-to(get-tuple-element.67, constant.4)
1888 get-tuple-element.68 = (s32[], s32[], s32[]) get-tuple-element(p.3), index=1
1889 get-tuple-element.70 = s32[] get-tuple-element(get-tuple-element.68), index=2
1890 multiply.1 = s32[] multiply(get-tuple-element.70, get-tuple-element.70)
1891 tuple.35 = (s32[]) tuple(multiply.1)
1892 ROOT tuple.36 = (s32[], (s32[], s32[], s32[]), (s32[])) tuple(constant.5, get-tuple-element.68, tuple.35)
1897 get-tupletuple-element(p.4), index=0
1899 ROOT equal-to.1 = pred[] equal-to(get-tuple-element.71, constant.6)
1904 get-tuple-element.72 = s32[] get-tuple-element(arg_tuple.4), index=0
1906 add.4 = s32[] add(get-tuple-element.72, constant.7)
1907 get-tuple-element.73 = s32[] get-tuple-element(arg_tuple.4), index=1
1908 get-tuple-element.74 = s32[] get-tuple-element(arg_tuple.4), index=2
1909 less-than-or-equal-to = pred[] less-than-or-equal-to(get-tuple-element.73, get-tuple-element.74)
1912 get-tuple-element.75 = s32[] get-tuple-element(arg_tuple.4), index=3
1913 tuple.37 = (s32[], s32[], s32[]) tuple(get-tuple-element.73, get-tuple-element.75, get-tuple-element.74)
1914 tuple.38 = (s32[]) tuple(constant.8)
1915 tuple.39 = (s32[], (s32[], s32[], s32[]), (s32[])) tuple(select, tuple.37, tuple.38)
1916 while = (s32[], (s32[], s32[], s32[]), (s32[])) while(tuple.39), condition=if-condition.v4, body=if-body.v5
1918 get-tuple-element.76 = (s32[]) get-tuple-element(while.1), index=2
1919 get-tuple-element.77 = s32[] get-tuple-element(get-tuple-element.76), index=0
1920 ROOT tuple.40 = (s32[], s32[], s32[], s32[]) tuple(add.4, get-tuple-element.73, get-tuple-element.74, get-tuple-element.77)
1925 get-tuple-element.78 = s32[] get-tuple-element(inputs.1), index=0
1927 ROOT less-than.2 = pred[] less-than(get-tuple-element.78, constant.11)
1932 get-tuple-element.79 = s32[] get-tuple-element(arg_tuple.5), index=0
1933 get-tuple-element.80 = s32[] get-tuple-element(arg_tuple.5), index=2
1934 get-tuple-element.81 = s32[] get-tuple-element(arg_tuple.5), index=3
1935 get-tuple-element.82 = s32[] get-tuple-element(arg_tuple.5), index=4
1936 tuple.41 = (s32[], s32[], s32[], s32[]) tuple(get-tuple-element.79, get-tuple-element.80, get-tuple-element.81, get-tuple-element.82)
1937 while.2 = (s32[], s32[], s32[], s32[]) while(tuple.41), condition=cond_wrapper.v3.1, body=_functionalize_body_1__.v28
1938 get-tuple-element.83 = s32[] get-tuple-element(while.2), index=0
1939 get-tuple-element.84 = s32[] get-tuple-element(arg_tuple.5), index=1
1941 add.5 = s32[] add(get-tuple-element.84, constant.12)
1942 get-tuple-element.85 = s32[] get-tuple-element(while.2), index=3
1943 ROOT tuple.42 = (s32[], s32[], s32[], s32[], s32[]) tuple(get-tuple-element.83, add.5, get-tuple-element.80, get-tuple-element.81, get-tuple-element.85)
1948 get-tuple-element.86 = s32[] get-tuple-element(inputs.2), index=1
1950 ROOT less-than.3 = pred[] less-than(get-tuple-element.86, constant.13)