sim: cgen: add asserts to fix unused engine warnings
authorMike Frysinger <vapier@gentoo.org>
Sun, 27 Jun 2021 03:03:53 +0000 (23:03 -0400)
committerMike Frysinger <vapier@gentoo.org>
Sun, 27 Jun 2021 14:48:07 +0000 (10:48 -0400)
commitb69bd9e723db53ce95c6ebb911d623b8f396b6ac
treed2cde494c0cee486772f3a692052c29a13b9918b
parenta7ffa88dc665b09f774c4a8cce1ac31377c96a74
sim: cgen: add asserts to fix unused engine warnings

If the user passed in values outside the range of [0, MAX_NR_PROCESSORS),
it would cause the code to access out-of-bind engine function pointers.
Add some asserts to catch that and to fix the related compiler warnings.
sim/common/ChangeLog
sim/common/cgen-run.c