don't delegate nodes with empty tensors (#1847)
Summary:
Pull Request resolved: https://github.com/pytorch/executorch/pull/1847
we occaisionally see the following in some graphs:
```
%empty_20 : [num_users=1] = call_function[target=torch.ops.aten.empty.memory_format](args = ([0],), kwargs = {device: cpu, pin_memory: False})
%cat_97 : [num_users=1] = call_function[target=torch.ops.aten.cat.default](args = ([%slice_146, %slice_145, %empty_20],), kwargs = {})
```
In which empty_20 is an empty tensor. xnnpack does not know how to deal with empty tensors or [0] shape tensors. So don't delegate.
Reviewed By: digantdesai
Differential Revision: D53398027
fbshipit-source-id: 3f8b113b059a9ab04890a756b1bc8557b54f8fce M
Max Ren committed
460803cb7d9b8025208cc92a7a4e24305841a5b6
Parent: bbe3f5b
Committed by Facebook GitHub Bot <facebook-github-bot@users.noreply.github.com>
on 2/6/2024, 9:32:16 PM