static void listflags(char *buf, int bufsize, uint32_t fbits,

    const char **featureset, uint32_t flags)

{

    const char **p = &featureset[31];

    char *q, *b, bit;

    int nc;



    b = 4 <= bufsize ? buf + (bufsize -= 3) - 1 : NULL;

    *buf = '\0';

    for (q = buf, bit = 31; fbits && bufsize; --p, fbits &= ~(1 << bit), --bit)

        if (fbits & 1 << bit && (*p || !flags)) {

            if (*p)

                nc = snprintf(q, bufsize, "%s%s", q == buf ? "" : " ", *p);

            else

                nc = snprintf(q, bufsize, "%s[%d]", q == buf ? "" : " ", bit);

            if (bufsize <= nc) {

                if (b)

                    sprintf(b, "...");

                return;

            }

            q += nc;

            bufsize -= nc;

        }

}

static void listflags(char *buf, int bufsize, uint32_t fbits,

    const char **featureset, uint32_t flags)

{

    const char **p = &featureset[31];

    char *q, *b, bit;

    int nc;



    b = 4 <= bufsize ? buf + (bufsize -= 3) - 1 : NULL;

    *buf = '\0';

    for (q = buf, bit = 31; fbits && bufsize; --p, fbits &= ~(1 << bit), --bit)

        if (fbits & 1 << bit && (*p || !flags)) {

            if (*p)

                nc = snprintf(q, bufsize, "%s%s", q == buf ? "" : " ", *p);

            else

                nc = snprintf(q, bufsize, "%s[%d]", q == buf ? "" : " ", bit);

            if (bufsize <= nc) {

                if (b)

                    sprintf(b, "...");

                return;

            }

            q += nc;

            bufsize -= nc;

        }

}

static void FUNC_0(char *VAR_0, int VAR_1, uint32_t VAR_2,

    const char **VAR_3, uint32_t VAR_4)

{

    const char **VAR_5 = &VAR_3[31];

    char *VAR_6, *VAR_7, VAR_8;

    int VAR_9;



    VAR_7 = 4 <= VAR_1 ? VAR_0 + (VAR_1 -= 3) - 1 : NULL;

    *VAR_0 = '\0';

    for (VAR_6 = VAR_0, VAR_8 = 31; VAR_2 && VAR_1; --VAR_5, VAR_2 &= ~(1 << VAR_8), --VAR_8)

        if (VAR_2 & 1 << VAR_8 && (*VAR_5 || !VAR_4)) {

            if (*VAR_5)

                VAR_9 = snprintf(VAR_6, VAR_1, "%s%s", VAR_6 == VAR_0 ? "" : " ", *VAR_5);

            else

                VAR_9 = snprintf(VAR_6, VAR_1, "%s[%d]", VAR_6 == VAR_0 ? "" : " ", VAR_8);

            if (VAR_1 <= VAR_9) {

                if (VAR_7)

                    sprintf(VAR_7, "...");

                return;

            }

            VAR_6 += VAR_9;

            VAR_1 -= VAR_9;

        }

}

static void FUNC_0(char *VAR_0, int VAR_1, uint32_t VAR_2,
const char **VAR_3, uint32_t VAR_4)
{ const char **VAR_5 = &VAR_3[31]; char *VAR_6, *VAR_7, VAR_8; int VAR_9; VAR_7 = 4 <= VAR_1 ? VAR_0 + (VAR_1 -= 3) - 1 : NULL; *VAR_0 = '\0'; for (VAR_6 = VAR_0, VAR_8 = 31; VAR_2 && VAR_1; --VAR_5, VAR_2 &= ~(1 << VAR_8), --VAR_8) if (VAR_2 & 1 << VAR_8 && (*VAR_5 || !VAR_4)) { if (*VAR_5)
VAR_9 = snprintf(VAR_6, VAR_1, "%s%s", VAR_6 == VAR_0 ? "" : " ", *VAR_5); else
VAR_9 = snprintf(VAR_6, VAR_1, "%s[%d]", VAR_6 == VAR_0 ? "" : " ", VAR_8); if (VAR_1 <= VAR_9) { if (VAR_7)
sprintf(VAR_7, "..."); return; } VAR_6 += VAR_9; VAR_1 -= VAR_9; } }