void tcg_dump_ops(TCGContext *s)

{

    char buf[128];

    TCGOp *op;

    int oi;



    for (oi = s->gen_first_op_idx; oi >= 0; oi = op->next) {

        int i, k, nb_oargs, nb_iargs, nb_cargs;

        const TCGOpDef *def;

        const TCGArg *args;

        TCGOpcode c;



        op = &s->gen_op_buf[oi];

        c = op->opc;

        def = &tcg_op_defs[c];

        args = &s->gen_opparam_buf[op->args];



        if (c == INDEX_op_insn_start) {

            qemu_log("%s ----", oi != s->gen_first_op_idx ? "\n" : "");



            for (i = 0; i < TARGET_INSN_START_WORDS; ++i) {

                target_ulong a;

#if TARGET_LONG_BITS > TCG_TARGET_REG_BITS

                a = ((target_ulong)args[i * 2 + 1] << 32) | args[i * 2];

#else

                a = args[i];

#endif

                qemu_log(" " TARGET_FMT_lx, a);

            }

        } else if (c == INDEX_op_call) {

            /* variable number of arguments */

            nb_oargs = op->callo;

            nb_iargs = op->calli;

            nb_cargs = def->nb_cargs;



            /* function name, flags, out args */

            qemu_log(" %s %s,$0x%" TCG_PRIlx ",$%d", def->name,

                     tcg_find_helper(s, args[nb_oargs + nb_iargs]),

                     args[nb_oargs + nb_iargs + 1], nb_oargs);

            for (i = 0; i < nb_oargs; i++) {

                qemu_log(",%s", tcg_get_arg_str_idx(s, buf, sizeof(buf),

                                                   args[i]));

            }

            for (i = 0; i < nb_iargs; i++) {

                TCGArg arg = args[nb_oargs + i];

                const char *t = "<dummy>";

                if (arg != TCG_CALL_DUMMY_ARG) {

                    t = tcg_get_arg_str_idx(s, buf, sizeof(buf), arg);

                }

                qemu_log(",%s", t);

            }

        } else {

            qemu_log(" %s ", def->name);



            nb_oargs = def->nb_oargs;

            nb_iargs = def->nb_iargs;

            nb_cargs = def->nb_cargs;



            k = 0;

            for (i = 0; i < nb_oargs; i++) {

                if (k != 0) {

                    qemu_log(",");

                }

                qemu_log("%s", tcg_get_arg_str_idx(s, buf, sizeof(buf),

                                                   args[k++]));

            }

            for (i = 0; i < nb_iargs; i++) {

                if (k != 0) {

                    qemu_log(",");

                }

                qemu_log("%s", tcg_get_arg_str_idx(s, buf, sizeof(buf),

                                                   args[k++]));

            }

            switch (c) {

            case INDEX_op_brcond_i32:

            case INDEX_op_setcond_i32:

            case INDEX_op_movcond_i32:

            case INDEX_op_brcond2_i32:

            case INDEX_op_setcond2_i32:

            case INDEX_op_brcond_i64:

            case INDEX_op_setcond_i64:

            case INDEX_op_movcond_i64:

                if (args[k] < ARRAY_SIZE(cond_name) && cond_name[args[k]]) {

                    qemu_log(",%s", cond_name[args[k++]]);

                } else {

                    qemu_log(",$0x%" TCG_PRIlx, args[k++]);

                }

                i = 1;

                break;

            case INDEX_op_qemu_ld_i32:

            case INDEX_op_qemu_st_i32:

            case INDEX_op_qemu_ld_i64:

            case INDEX_op_qemu_st_i64:

                {

                    TCGMemOpIdx oi = args[k++];

                    TCGMemOp op = get_memop(oi);

                    unsigned ix = get_mmuidx(oi);



                    if (op & ~(MO_AMASK | MO_BSWAP | MO_SSIZE)) {

                        qemu_log(",$0x%x,%u", op, ix);

                    } else {

                        const char *s_al = "", *s_op;

                        if (op & MO_AMASK) {

                            if ((op & MO_AMASK) == MO_ALIGN) {

                                s_al = "al+";

                            } else {

                                s_al = "un+";

                            }

                        }

                        s_op = ldst_name[op & (MO_BSWAP | MO_SSIZE)];

                        qemu_log(",%s%s,%u", s_al, s_op, ix);

                    }

                    i = 1;

                }

                break;

            default:

                i = 0;

                break;

            }

            switch (c) {

            case INDEX_op_set_label:

            case INDEX_op_br:

            case INDEX_op_brcond_i32:

            case INDEX_op_brcond_i64:

            case INDEX_op_brcond2_i32:

                qemu_log("%s$L%d", k ? "," : "", arg_label(args[k])->id);

                i++, k++;

                break;

            default:

                break;

            }

            for (; i < nb_cargs; i++, k++) {

                qemu_log("%s$0x%" TCG_PRIlx, k ? "," : "", args[k]);

            }

        }

        qemu_log("\n");

    }

}

void tcg_dump_ops(TCGContext *s)

{

    char buf[128];

    TCGOp *op;

    int oi;



    for (oi = s->gen_first_op_idx; oi >= 0; oi = op->next) {

        int i, k, nb_oargs, nb_iargs, nb_cargs;

        const TCGOpDef *def;

        const TCGArg *args;

        TCGOpcode c;



        op = &s->gen_op_buf[oi];

        c = op->opc;

        def = &tcg_op_defs[c];

        args = &s->gen_opparam_buf[op->args];



        if (c == INDEX_op_insn_start) {

            qemu_log("%s ----", oi != s->gen_first_op_idx ? "\n" : "");



            for (i = 0; i < TARGET_INSN_START_WORDS; ++i) {

                target_ulong a;

#if TARGET_LONG_BITS > TCG_TARGET_REG_BITS

                a = ((target_ulong)args[i * 2 + 1] << 32) | args[i * 2];

#else

                a = args[i];

#endif

                qemu_log(" " TARGET_FMT_lx, a);

            }

        } else if (c == INDEX_op_call) {

            

            nb_oargs = op->callo;

            nb_iargs = op->calli;

            nb_cargs = def->nb_cargs;



            

            qemu_log(" %s %s,$0x%" TCG_PRIlx ",$%d", def->name,

                     tcg_find_helper(s, args[nb_oargs + nb_iargs]),

                     args[nb_oargs + nb_iargs + 1], nb_oargs);

            for (i = 0; i < nb_oargs; i++) {

                qemu_log(",%s", tcg_get_arg_str_idx(s, buf, sizeof(buf),

                                                   args[i]));

            }

            for (i = 0; i < nb_iargs; i++) {

                TCGArg arg = args[nb_oargs + i];

                const char *t = "<dummy>";

                if (arg != TCG_CALL_DUMMY_ARG) {

                    t = tcg_get_arg_str_idx(s, buf, sizeof(buf), arg);

                }

                qemu_log(",%s", t);

            }

        } else {

            qemu_log(" %s ", def->name);



            nb_oargs = def->nb_oargs;

            nb_iargs = def->nb_iargs;

            nb_cargs = def->nb_cargs;



            k = 0;

            for (i = 0; i < nb_oargs; i++) {

                if (k != 0) {

                    qemu_log(",");

                }

                qemu_log("%s", tcg_get_arg_str_idx(s, buf, sizeof(buf),

                                                   args[k++]));

            }

            for (i = 0; i < nb_iargs; i++) {

                if (k != 0) {

                    qemu_log(",");

                }

                qemu_log("%s", tcg_get_arg_str_idx(s, buf, sizeof(buf),

                                                   args[k++]));

            }

            switch (c) {

            case INDEX_op_brcond_i32:

            case INDEX_op_setcond_i32:

            case INDEX_op_movcond_i32:

            case INDEX_op_brcond2_i32:

            case INDEX_op_setcond2_i32:

            case INDEX_op_brcond_i64:

            case INDEX_op_setcond_i64:

            case INDEX_op_movcond_i64:

                if (args[k] < ARRAY_SIZE(cond_name) && cond_name[args[k]]) {

                    qemu_log(",%s", cond_name[args[k++]]);

                } else {

                    qemu_log(",$0x%" TCG_PRIlx, args[k++]);

                }

                i = 1;

                break;

            case INDEX_op_qemu_ld_i32:

            case INDEX_op_qemu_st_i32:

            case INDEX_op_qemu_ld_i64:

            case INDEX_op_qemu_st_i64:

                {

                    TCGMemOpIdx oi = args[k++];

                    TCGMemOp op = get_memop(oi);

                    unsigned ix = get_mmuidx(oi);



                    if (op & ~(MO_AMASK | MO_BSWAP | MO_SSIZE)) {

                        qemu_log(",$0x%x,%u", op, ix);

                    } else {

                        const char *s_al = "", *s_op;

                        if (op & MO_AMASK) {

                            if ((op & MO_AMASK) == MO_ALIGN) {

                                s_al = "al+";

                            } else {

                                s_al = "un+";

                            }

                        }

                        s_op = ldst_name[op & (MO_BSWAP | MO_SSIZE)];

                        qemu_log(",%s%s,%u", s_al, s_op, ix);

                    }

                    i = 1;

                }

                break;

            default:

                i = 0;

                break;

            }

            switch (c) {

            case INDEX_op_set_label:

            case INDEX_op_br:

            case INDEX_op_brcond_i32:

            case INDEX_op_brcond_i64:

            case INDEX_op_brcond2_i32:

                qemu_log("%s$L%d", k ? "," : "", arg_label(args[k])->id);

                i++, k++;

                break;

            default:

                break;

            }

            for (; i < nb_cargs; i++, k++) {

                qemu_log("%s$0x%" TCG_PRIlx, k ? "," : "", args[k]);

            }

        }

        qemu_log("\n");

    }

}

void FUNC_0(TCGContext *VAR_0)

{

    char VAR_1[128];

    TCGOp *op;

    int VAR_2;



    for (VAR_2 = VAR_0->gen_first_op_idx; VAR_2 >= 0; VAR_2 = op->next) {

        int VAR_3, VAR_4, VAR_5, VAR_6, VAR_7;

        const TCGOpDef *VAR_8;

        const TCGArg *VAR_9;

        TCGOpcode c;



        op = &VAR_0->gen_op_buf[VAR_2];

        c = op->opc;

        VAR_8 = &tcg_op_defs[c];

        VAR_9 = &VAR_0->gen_opparam_buf[op->VAR_9];



        if (c == INDEX_op_insn_start) {

            qemu_log("%VAR_0 ----", VAR_2 != VAR_0->gen_first_op_idx ? "\n" : "");



            for (VAR_3 = 0; VAR_3 < TARGET_INSN_START_WORDS; ++VAR_3) {

                target_ulong a;

#if TARGET_LONG_BITS > TCG_TARGET_REG_BITS

                a = ((target_ulong)VAR_9[VAR_3 * 2 + 1] << 32) | VAR_9[VAR_3 * 2];

#else

                a = VAR_9[VAR_3];

#endif

                qemu_log(" " TARGET_FMT_lx, a);

            }

        } else if (c == INDEX_op_call) {

            

            VAR_5 = op->callo;

            VAR_6 = op->calli;

            VAR_7 = VAR_8->VAR_7;



            

            qemu_log(" %VAR_0 %VAR_0,$0x%" TCG_PRIlx ",$%d", VAR_8->name,

                     tcg_find_helper(VAR_0, VAR_9[VAR_5 + VAR_6]),

                     VAR_9[VAR_5 + VAR_6 + 1], VAR_5);

            for (VAR_3 = 0; VAR_3 < VAR_5; VAR_3++) {

                qemu_log(",%VAR_0", tcg_get_arg_str_idx(VAR_0, VAR_1, sizeof(VAR_1),

                                                   VAR_9[VAR_3]));

            }

            for (VAR_3 = 0; VAR_3 < VAR_6; VAR_3++) {

                TCGArg arg = VAR_9[VAR_5 + VAR_3];

                const char *VAR_10 = "<dummy>";

                if (arg != TCG_CALL_DUMMY_ARG) {

                    VAR_10 = tcg_get_arg_str_idx(VAR_0, VAR_1, sizeof(VAR_1), arg);

                }

                qemu_log(",%VAR_0", VAR_10);

            }

        } else {

            qemu_log(" %VAR_0 ", VAR_8->name);



            VAR_5 = VAR_8->VAR_5;

            VAR_6 = VAR_8->VAR_6;

            VAR_7 = VAR_8->VAR_7;



            VAR_4 = 0;

            for (VAR_3 = 0; VAR_3 < VAR_5; VAR_3++) {

                if (VAR_4 != 0) {

                    qemu_log(",");

                }

                qemu_log("%VAR_0", tcg_get_arg_str_idx(VAR_0, VAR_1, sizeof(VAR_1),

                                                   VAR_9[VAR_4++]));

            }

            for (VAR_3 = 0; VAR_3 < VAR_6; VAR_3++) {

                if (VAR_4 != 0) {

                    qemu_log(",");

                }

                qemu_log("%VAR_0", tcg_get_arg_str_idx(VAR_0, VAR_1, sizeof(VAR_1),

                                                   VAR_9[VAR_4++]));

            }

            switch (c) {

            case INDEX_op_brcond_i32:

            case INDEX_op_setcond_i32:

            case INDEX_op_movcond_i32:

            case INDEX_op_brcond2_i32:

            case INDEX_op_setcond2_i32:

            case INDEX_op_brcond_i64:

            case INDEX_op_setcond_i64:

            case INDEX_op_movcond_i64:

                if (VAR_9[VAR_4] < ARRAY_SIZE(cond_name) && cond_name[VAR_9[VAR_4]]) {

                    qemu_log(",%VAR_0", cond_name[VAR_9[VAR_4++]]);

                } else {

                    qemu_log(",$0x%" TCG_PRIlx, VAR_9[VAR_4++]);

                }

                VAR_3 = 1;

                break;

            case INDEX_op_qemu_ld_i32:

            case INDEX_op_qemu_st_i32:

            case INDEX_op_qemu_ld_i64:

            case INDEX_op_qemu_st_i64:

                {

                    TCGMemOpIdx VAR_2 = VAR_9[VAR_4++];

                    TCGMemOp op = get_memop(VAR_2);

                    unsigned VAR_11 = get_mmuidx(VAR_2);



                    if (op & ~(MO_AMASK | MO_BSWAP | MO_SSIZE)) {

                        qemu_log(",$0x%x,%u", op, VAR_11);

                    } else {

                        const char *VAR_12 = "", *VAR_13;

                        if (op & MO_AMASK) {

                            if ((op & MO_AMASK) == MO_ALIGN) {

                                VAR_12 = "al+";

                            } else {

                                VAR_12 = "un+";

                            }

                        }

                        VAR_13 = ldst_name[op & (MO_BSWAP | MO_SSIZE)];

                        qemu_log(",%VAR_0%VAR_0,%u", VAR_12, VAR_13, VAR_11);

                    }

                    VAR_3 = 1;

                }

                break;

            default:

                VAR_3 = 0;

                break;

            }

            switch (c) {

            case INDEX_op_set_label:

            case INDEX_op_br:

            case INDEX_op_brcond_i32:

            case INDEX_op_brcond_i64:

            case INDEX_op_brcond2_i32:

                qemu_log("%VAR_0$L%d", VAR_4 ? "," : "", arg_label(VAR_9[VAR_4])->id);

                VAR_3++, VAR_4++;

                break;

            default:

                break;

            }

            for (; VAR_3 < VAR_7; VAR_3++, VAR_4++) {

                qemu_log("%VAR_0$0x%" TCG_PRIlx, VAR_4 ? "," : "", VAR_9[VAR_4]);

            }

        }

        qemu_log("\n");

    }

}

void FUNC_0(TCGContext *VAR_0)
{ char VAR_1[128]; TCGOp *op; int VAR_2; for (VAR_2 = VAR_0->gen_first_op_idx; VAR_2 >= 0; VAR_2 = op->next) { int VAR_3, VAR_4, VAR_5, VAR_6, VAR_7; const TCGOpDef *VAR_8; const TCGArg *VAR_9; TCGOpcode c; op = &VAR_0->gen_op_buf[VAR_2]; c = op->opc; VAR_8 = &tcg_op_defs[c]; VAR_9 = &VAR_0->gen_opparam_buf[op->VAR_9]; if (c == INDEX_op_insn_start) { qemu_log("%VAR_0 ----", VAR_2 != VAR_0->gen_first_op_idx ? "\n" : ""); for (VAR_3 = 0; VAR_3 < TARGET_INSN_START_WORDS; ++VAR_3) { target_ulong a; #if TARGET_LONG_BITS > TCG_TARGET_REG_BITS
a = ((target_ulong)VAR_9[VAR_3 * 2 + 1] << 32) | VAR_9[VAR_3 * 2]; #else
a = VAR_9[VAR_3]; #endif
qemu_log(" " TARGET_FMT_lx, a); } } else if (c == INDEX_op_call) { VAR_5 = op->callo; VAR_6 = op->calli; VAR_7 = VAR_8->VAR_7; qemu_log(" %VAR_0 %VAR_0,$0x%" TCG_PRIlx ",$%d", VAR_8->name,
tcg_find_helper(VAR_0, VAR_9[VAR_5 + VAR_6]),
VAR_9[VAR_5 + VAR_6 + 1], VAR_5); for (VAR_3 = 0; VAR_3 < VAR_5; VAR_3++) { qemu_log(",%VAR_0", tcg_get_arg_str_idx(VAR_0, VAR_1, sizeof(VAR_1),
VAR_9[VAR_3])); } for (VAR_3 = 0; VAR_3 < VAR_6; VAR_3++) { TCGArg arg = VAR_9[VAR_5 + VAR_3]; const char *VAR_10 = "<dummy>"; if (arg != TCG_CALL_DUMMY_ARG) { VAR_10 = tcg_get_arg_str_idx(VAR_0, VAR_1, sizeof(VAR_1), arg); } qemu_log(",%VAR_0", VAR_10); } } else { qemu_log(" %VAR_0 ", VAR_8->name); VAR_5 = VAR_8->VAR_5; VAR_6 = VAR_8->VAR_6; VAR_7 = VAR_8->VAR_7; VAR_4 = 0; for (VAR_3 = 0; VAR_3 < VAR_5; VAR_3++) { if (VAR_4 != 0) { qemu_log(","); } qemu_log("%VAR_0", tcg_get_arg_str_idx(VAR_0, VAR_1, sizeof(VAR_1),
VAR_9[VAR_4++])); } for (VAR_3 = 0; VAR_3 < VAR_6; VAR_3++) { if (VAR_4 != 0) { qemu_log(","); } qemu_log("%VAR_0", tcg_get_arg_str_idx(VAR_0, VAR_1, sizeof(VAR_1),
VAR_9[VAR_4++])); } switch (c) { case INDEX_op_brcond_i32:
case INDEX_op_setcond_i32:
case INDEX_op_movcond_i32:
case INDEX_op_brcond2_i32:
case INDEX_op_setcond2_i32:
case INDEX_op_brcond_i64:
case INDEX_op_setcond_i64:
case INDEX_op_movcond_i64:
if (VAR_9[VAR_4] < ARRAY_SIZE(cond_name) && cond_name[VAR_9[VAR_4]]) { qemu_log(",%VAR_0", cond_name[VAR_9[VAR_4++]]); } else { qemu_log(",$0x%" TCG_PRIlx, VAR_9[VAR_4++]); } VAR_3 = 1; break; case INDEX_op_qemu_ld_i32:
case INDEX_op_qemu_st_i32:
case INDEX_op_qemu_ld_i64:
case INDEX_op_qemu_st_i64:
{ TCGMemOpIdx VAR_2 = VAR_9[VAR_4++]; TCGMemOp op = get_memop(VAR_2); unsigned VAR_11 = get_mmuidx(VAR_2); if (op & ~(MO_AMASK | MO_BSWAP | MO_SSIZE)) { qemu_log(",$0x%x,%u", op, VAR_11); } else { const char *VAR_12 = "", *VAR_13; if (op & MO_AMASK) { if ((op & MO_AMASK) == MO_ALIGN) { VAR_12 = "al+"; } else { VAR_12 = "un+"; } } VAR_13 = ldst_name[op & (MO_BSWAP | MO_SSIZE)]; qemu_log(",%VAR_0%VAR_0,%u", VAR_12, VAR_13, VAR_11); } VAR_3 = 1; } break; default:
VAR_3 = 0; break; } switch (c) { case INDEX_op_set_label:
case INDEX_op_br:
case INDEX_op_brcond_i32:
case INDEX_op_brcond_i64:
case INDEX_op_brcond2_i32:
qemu_log("%VAR_0$L%d", VAR_4 ? "," : "", arg_label(VAR_9[VAR_4])->id); VAR_3++, VAR_4++; break; default:
break; } for (; VAR_3 < VAR_7; VAR_3++, VAR_4++) { qemu_log("%VAR_0$0x%" TCG_PRIlx, VAR_4 ? "," : "", VAR_9[VAR_4]); } } qemu_log("\n"); } }