MCPcopy Create free account
hub / github.com/ROCm/AMDMIGraphX / as_packed

Function as_packed

src/propagate_constant.cpp:62–70  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

60}
61
62static argument as_packed(const argument& c)
63{
64 if(c.get_shape().packed())
65 return c;
66 auto s = c.get_shape().with_lens(c.get_shape().lens());
67 argument result;
68 c.visit([&](auto x) { result = literal{s, x.begin(), x.end()}.get_argument(); });
69 return result;
70}
71
72void propagate_constant::apply(module& m) const
73{

Callers 1

applyMethod · 0.85

Calls 8

with_lensMethod · 0.80
lensMethod · 0.80
get_argumentMethod · 0.80
packedMethod · 0.45
get_shapeMethod · 0.45
visitMethod · 0.45
beginMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected