Implement faster mju_isZeroByte.

PiperOrigin-RevId: 814148714
Change-Id: Iaf5ed9d3502eaaaee8d46a986f2db00811ae0707
This commit is contained in:
Kyle Bayes
2025-10-02 02:53:02 -07:00
committed by Copybara-Service
parent 401bf431b8
commit 91257896c0
4 changed files with 42 additions and 21 deletions
+1 -1
View File
@@ -136,7 +136,7 @@ MJAPI int mju_isBad(mjtNum x);
// return 1 if all elements are numerically 0 (-0.0 treated as zero)
MJAPI int mju_isZero(const mjtNum* vec, int n);
// return 1 if all elements are 0x00, can be ~2x faster than mju_isZero
// return 1 if all elements are 0x00, faster than mju_isZero
MJAPI int mju_isZeroByte(const unsigned char* vec, int n);
// set integer vector to 0