/* get GC debt and convert it from Kb to 'work units' (avoid zero debt and overflows)  */
static l_mem getdebt(global_State *g)
/* get GC debt and convert it from Kb to 'work units' (avoid zero debt and overflows)  */
static l_mem getdebt(global_State *g)
{
    debt = (debt / STEPMULADJ) + 1;
    debt = (debt < MAX_LMEM / stepmul) ? debt * stepmul : MAX_LMEM;
    return debt;
  }
}