Fix null ptr dereference in REDUCE_* cpu implementation
When asked to reduce across all dimensions, reduce would produce a
zero-sized tensor without dimensions and cause segmentation fault in the
implementation.
The change fixes the bug by making the op output a tensor of size [1] in
this case.
Also, updated the bug to clarify this behaviour.
Bug: 155508675
Test: NNTest_static
Change-Id: Ie98d8fa2e508255fd50f6bd8184dc323ba90fac8
Merged-In: Ie98d8fa2e508255fd50f6bd8184dc323ba90fac8
(cherry picked from commit 62160e554e7abf4a29be003dd5938c65d70f649a)
15 files changed