// File: jkingan[P]ladyheather/heathui.cpp
// Function: show_plot_stats()
void show_plot_stats()
{
int old_stat;
char units[SLEN+1];
int id;
double val;

    // show all current plot statistics for a selected plot
    if(show_all_stats <= 0) return;

    id = selected_plot;
    if(id < 0) id = selected_plot = DAC;
    if(id >= (NUM_PLOTS+DERIVED_PLOTS)) id = selected_plot = DAC;

    old_stat = plot[id].show_stat;

    strcpy(units, plot[id].units);

    plot[id].show_stat = RMS;
    val = get_stat_val(id);
    sprintf(out, "%s  %.9f %s (%s)  ", stat_id, val, units, plot[id].plot_id);
    strcpy(debug_text7, out);

    plot[id].show_stat = AVG;
    val = get_stat_val(id);
    sprintf(out, "%s  %.9f %s (%s)  ", stat_id, val, units, plot[id].plot_id);
    strcpy(debug_text6, out);

    plot[id].show_stat = SDEV;
    val = get_stat_val(id);
    sprintf(out, "%s  %.9f %s (%s)  ", stat_id, val, units, plot[id].plot_id);
    strcpy(debug_text5, out);

    plot[id].show_stat = VAR;
    val = get_stat_val(id);
    sprintf(out, "%s  %.9f %s (%s)  ", stat_id, val, units, plot[id].plot_id);
    strcpy(debug_text4, out);

    plot[id].show_stat = SHOW_MIN;
    val = get_stat_val(id);
    sprintf(out, "%s  %.9f %s (%s)  ", stat_id, val, units, plot[id].plot_id);
    strcpy(debug_text3, out);

    plot[id].show_stat = SHOW_MAX;
    val = get_stat_val(id);
    sprintf(out, "%s  %.9f %s (%s)  ", stat_id, val, units, plot[id].plot_id);
    strcpy(debug_text2, out);

    plot[id].show_stat = SHOW_SPAN;
    val = get_stat_val(id);
    sprintf(out, "%s %.9f %s (%s)  ", stat_id, val, units, plot[id].plot_id);
    strcpy(debug_text, out);

    plot[id].show_stat = old_stat;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x110, %rsp            # imm = 0x110
leaq 0x34ef4e(%rip), %rax    # 0x39ef40
cmpl $0x0, (%rax)
jg 0x4fffc
jmp 0x50497
leaq 0x34ef35(%rip), %rax    # 0x39ef38
movl (%rax), %eax
movl %eax, -0x104(%rbp)
cmpl $0x0, -0x104(%rbp)
jge 0x5002b
leaq 0x34ef1d(%rip), %rax    # 0x39ef38
movl $0x2, (%rax)
movl $0x2, -0x104(%rbp)
cmpl $0x14, -0x104(%rbp)
jl 0x5004b
leaq 0x34eefd(%rip), %rax    # 0x39ef38
movl $0x2, (%rax)
movl $0x2, -0x104(%rbp)
movslq -0x104(%rbp), %rcx
leaq 0x16ccc7(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rcx, %rcx
addq %rcx, %rax
movl 0xd4(%rax), %eax
movl %eax, -0x4(%rbp)
leaq -0x100(%rbp), %rdi
movslq -0x104(%rbp), %rcx
leaq 0x16cc9f(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rcx, %rcx
addq %rcx, %rax
movq 0x8(%rax), %rsi
callq 0x9350
movslq -0x104(%rbp), %rcx
leaq 0x16cc7e(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rcx, %rcx
addq %rcx, %rax
movl $0x1, 0xd4(%rax)
movl -0x104(%rbp), %edi
callq 0x19040
movsd %xmm0, -0x110(%rbp)
movsd -0x110(%rbp), %xmm0
leaq -0x100(%rbp), %rcx
movslq -0x104(%rbp), %rdx
leaq 0x16cc3a(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rdx, %rdx
addq %rdx, %rax
movq (%rax), %r8
leaq 0x34b306(%rip), %rdi    # 0x39b400
leaq 0x12abdb(%rip), %rsi    # 0x17acdc
leaq 0x34e818(%rip), %rdx    # 0x39e920
movb $0x1, %al
callq 0x9060
leaq 0x34e24a(%rip), %rdi    # 0x39e360
leaq 0x34b2e3(%rip), %rsi    # 0x39b400
callq 0x9350
movslq -0x104(%rbp), %rcx
leaq 0x16cbf0(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rcx, %rcx
addq %rcx, %rax
movl $0x2, 0xd4(%rax)
movl -0x104(%rbp), %edi
callq 0x19040
movsd %xmm0, -0x110(%rbp)
movsd -0x110(%rbp), %xmm0
leaq -0x100(%rbp), %rcx
movslq -0x104(%rbp), %rdx
leaq 0x16cbac(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rdx, %rdx
addq %rdx, %rax
movq (%rax), %r8
leaq 0x34b278(%rip), %rdi    # 0x39b400
leaq 0x12ab4d(%rip), %rsi    # 0x17acdc
leaq 0x34e78a(%rip), %rdx    # 0x39e920
movb $0x1, %al
callq 0x9060
leaq 0x34e06c(%rip), %rdi    # 0x39e210
leaq 0x34b255(%rip), %rsi    # 0x39b400
callq 0x9350
movslq -0x104(%rbp), %rcx
leaq 0x16cb62(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rcx, %rcx
addq %rcx, %rax
movl $0x4, 0xd4(%rax)
movl -0x104(%rbp), %edi
callq 0x19040
movsd %xmm0, -0x110(%rbp)
movsd -0x110(%rbp), %xmm0
leaq -0x100(%rbp), %rcx
movslq -0x104(%rbp), %rdx
leaq 0x16cb1e(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rdx, %rdx
addq %rdx, %rax
movq (%rax), %r8
leaq 0x34b1ea(%rip), %rdi    # 0x39b400
leaq 0x12aabf(%rip), %rsi    # 0x17acdc
leaq 0x34e6fc(%rip), %rdx    # 0x39e920
movb $0x1, %al
callq 0x9060
leaq 0x34de8e(%rip), %rdi    # 0x39e0c0
leaq 0x34b1c7(%rip), %rsi    # 0x39b400
callq 0x9350
movslq -0x104(%rbp), %rcx
leaq 0x16cad4(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rcx, %rcx
addq %rcx, %rax
movl $0x8, 0xd4(%rax)
movl -0x104(%rbp), %edi
callq 0x19040
movsd %xmm0, -0x110(%rbp)
movsd -0x110(%rbp), %xmm0
leaq -0x100(%rbp), %rcx
movslq -0x104(%rbp), %rdx
leaq 0x16ca90(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rdx, %rdx
addq %rdx, %rax
movq (%rax), %r8
leaq 0x34b15c(%rip), %rdi    # 0x39b400
leaq 0x12aa31(%rip), %rsi    # 0x17acdc
leaq 0x34e66e(%rip), %rdx    # 0x39e920
movb $0x1, %al
callq 0x9060
leaq 0x34dcb0(%rip), %rdi    # 0x39df70
leaq 0x34b139(%rip), %rsi    # 0x39b400
callq 0x9350
movslq -0x104(%rbp), %rcx
leaq 0x16ca46(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rcx, %rcx
addq %rcx, %rax
movl $0x10, 0xd4(%rax)
movl -0x104(%rbp), %edi
callq 0x19040
movsd %xmm0, -0x110(%rbp)
movsd -0x110(%rbp), %xmm0
leaq -0x100(%rbp), %rcx
movslq -0x104(%rbp), %rdx
leaq 0x16ca02(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rdx, %rdx
addq %rdx, %rax
movq (%rax), %r8
leaq 0x34b0ce(%rip), %rdi    # 0x39b400
leaq 0x12a9a3(%rip), %rsi    # 0x17acdc
leaq 0x34e5e0(%rip), %rdx    # 0x39e920
movb $0x1, %al
callq 0x9060
leaq 0x34dad2(%rip), %rdi    # 0x39de20
leaq 0x34b0ab(%rip), %rsi    # 0x39b400
callq 0x9350
movslq -0x104(%rbp), %rcx
leaq 0x16c9b8(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rcx, %rcx
addq %rcx, %rax
movl $0x20, 0xd4(%rax)
movl -0x104(%rbp), %edi
callq 0x19040
movsd %xmm0, -0x110(%rbp)
movsd -0x110(%rbp), %xmm0
leaq -0x100(%rbp), %rcx
movslq -0x104(%rbp), %rdx
leaq 0x16c974(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rdx, %rdx
addq %rdx, %rax
movq (%rax), %r8
leaq 0x34b040(%rip), %rdi    # 0x39b400
leaq 0x12a915(%rip), %rsi    # 0x17acdc
leaq 0x34e552(%rip), %rdx    # 0x39e920
movb $0x1, %al
callq 0x9060
leaq 0x34d8f4(%rip), %rdi    # 0x39dcd0
leaq 0x34b01d(%rip), %rsi    # 0x39b400
callq 0x9350
movslq -0x104(%rbp), %rcx
leaq 0x16c92a(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rcx, %rcx
addq %rcx, %rax
movl $0x40, 0xd4(%rax)
movl -0x104(%rbp), %edi
callq 0x19040
movsd %xmm0, -0x110(%rbp)
movsd -0x110(%rbp), %xmm0
leaq -0x100(%rbp), %rcx
movslq -0x104(%rbp), %rdx
leaq 0x16c8e6(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rdx, %rdx
addq %rdx, %rax
movq (%rax), %r8
leaq 0x34afb2(%rip), %rdi    # 0x39b400
leaq 0x12a89a(%rip), %rsi    # 0x17acef
leaq 0x34e4c4(%rip), %rdx    # 0x39e920
movb $0x1, %al
callq 0x9060
leaq 0x34d716(%rip), %rdi    # 0x39db80
leaq 0x34af8f(%rip), %rsi    # 0x39b400
callq 0x9350
movl -0x4(%rbp), %ecx
movslq -0x104(%rbp), %rdx
leaq 0x16c899(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rdx, %rdx
addq %rdx, %rax
movl %ecx, 0xd4(%rax)
addq $0x110, %rsp            # imm = 0x110
popq %rbp
retq