Cannot modify inputs to MaxPoolGrad

Hello,

I want to slice the input to the MaxPoolGradNode, but looks like the MaxPoolGradNode should directly get its input(OriginalOutputForResult) from the maxpool node.

line No 182 in IRGen.cpp cast the input to the MaxPoolGradNode to a MaxPoolNode.

This also creates a problem while partitioning if maxpool node is in a different partition and input to the MaxPoolGradNode becomes a Placeholder.

Here are the lines of code that I was referring to in IRGen.cpp

auto poolOut = PG->getOriginalOutputForResult();
auto *PI = cast<MaxPoolWithArgmaxInst>(nodeToInstr_[poolOut.getNode()]);