Sparse ten_J and ten_J_colind memory

PiperOrigin-RevId: 868834376
Change-Id: Iec92d9e09e3134666895e54a78cb02439d74a4de
This commit is contained in:
Google DeepMind
2026-02-11 14:04:45 -08:00
committed by Copybara-Service
parent b466829482
commit 336e1026a4
21 changed files with 43 additions and 118 deletions
+3
View File
@@ -669,6 +669,9 @@ void UpdateWatch(mj::Simulate* sim, const mjModel* m, const mjData* d) {
sim->ui0.sect[SECT_WATCH].item[2].multi.nelem = 1;
mju::strcpy_arr(sim->ui0.sect[SECT_WATCH].item[2].multi.name[0], "invalid field");
// prepare symbols needed by xmacro
MJDATA_POINTERS_PREAMBLE(m);
// find specified field in mjData arrays, update value
#define X(TYPE, NAME, NR, NC) \
if (!mju::strcmp_arr(#NAME, sim->field) && \