I think the background is moving the model to TVM see this discussion on TVM and copy_ 7.
@apivovarov You probably increase your chance of getting good answers if you give more context.
Personally, I think the two main ways of doing this is:

As you suggest, the immediate way is to change  the model to use torch.cat + view instead. This is probably wildly preferable because any translation of index assignment look funny.
Implement view tracking in TVM. I commented a bit on this in the TVM copy_ PR before yours. Takes some effort but after that it should be reasonably possible to express index assignments. There will likely be corner cases that you miss as there are operations PyTorch (e.g. reshape) that may or may not return views.

Best regards
Thomas