This commit prevents overflow by cast in KernelGenerator of acl_cl.
Signed-off-by: jiseob.jang <jiseob.jang@samsung.com>
const auto feature_size = _ctx.at(input_index).shape().num_elements();
UNUSED_RELEASE(feature_size);
- assert((batch_size * input_size) >= 0);
- assert(feature_size == static_cast<uint64_t>(batch_size * input_size));
+ assert(batch_size >= 0 && input_size >= 0);
+ assert(feature_size == static_cast<uint64_t>(batch_size) * static_cast<uint64_t>(input_size));
// for reshaping
needs_reshape = true;