// File: /workspace/github_c_makefile_star2_O3/pipde[P]deos-songlib/utils/processtab/tabchecker.c
// Function: buildMeasureFromASTEvents
static void
buildMeasureFromASTEvents(Measure *measure, char *astEvents, char *astTimingEvents)
    {
    int i;
    DoubleArray *eventDurations = parseMeasureEventDurations(astTimingEvents, (int)measure->beatsInMeasure);
    NoteInstance *ni;
    double currentDuration;
    
    for (i = 0; i < eventDurations->length; i++)
        {
        ni = newNoteInstance();
        /* ni->noteName == 0 is rest */
        ni->noteName = astEvents == 0 ? 0 : ((astEvents[i] == '-' || astEvents[i] == ' ') ? 0 : astEvents[i]);
        
        /* spaces ' ' hold the note length.  Loop through them, adding to the current duration. */
        currentDuration = eventDurations->values[i]; 
        for (; i < (eventDurations->length - 1) && (astEvents == 0 || astEvents[i+1] == ' '); i++)
            {
            currentDuration += eventDurations->values[i+1];
            }
        
        ni->duration = currentDuration;
        addNoteInstanceToMeasure(ni, measure);
        }
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, %r15
movq %rsi, %rbp
movq %rdi, %r14
movb 0xc(%rdi), %bl
leal 0x30(%rbx), %eax
movsbl %al, %r12d
cmpb $0x30, %r12b
jg 0x4532
leaq 0x2faf(%rip), %rdi      # 0x74ca
xorl %r13d, %r13d
movl $0x31, %esi
movl %r12d, %edx
xorl %eax, %eax
callq 0x5138
jmp 0x4ab0
leal -0x2f(%r12), %edi
callq 0x5257
movq %rax, %r13
addb $0x31, %bl
movzbl %bl, %eax
cmpb $0x33, %al
movl $0x32, %ecx
cmovgel %eax, %ecx
movzbl %cl, %ecx
leaq -0x22(%rcx), %rax
andq $-0x10, %rax
addq $-0x32, %rcx
movq %rcx, %xmm0
pshufd $0x44, %xmm0, %xmm0     # xmm0 = xmm0[0,1,0,1]
xorl %ecx, %ecx
movdqa 0x2e6e(%rip), %xmm3     # 0x73e0
movdqa 0x2e76(%rip), %xmm4     # 0x73f0
movdqa 0x2e7e(%rip), %xmm5     # 0x7400
movdqa 0x2e86(%rip), %xmm6     # 0x7410
movdqa 0x2e8e(%rip), %xmm7     # 0x7420
movdqa 0x2e95(%rip), %xmm8     # 0x7430
movdqa 0x2e9c(%rip), %xmm9     # 0x7440
pcmpeqd %xmm10, %xmm10
movq %rcx, %xmm11
pshufd $0x44, %xmm11, %xmm11   # xmm11 = xmm11[0,1,0,1]
movdqa %xmm11, %xmm13
por %xmm8, %xmm13
movdqa %xmm0, %xmm12
pxor %xmm9, %xmm12
pxor %xmm9, %xmm13
movdqa %xmm13, %xmm15
pcmpgtd %xmm12, %xmm15
pshufd $0xa0, %xmm15, %xmm14   # xmm14 = xmm15[0,0,2,2]
pshuflw $0xe8, %xmm14, %xmm1    # xmm1 = xmm14[0,2,2,3,4,5,6,7]
pcmpeqd %xmm12, %xmm13
pshufd $0xf5, %xmm13, %xmm13   # xmm13 = xmm13[1,1,3,3]
pshuflw $0xe8, %xmm13, %xmm2    # xmm2 = xmm13[0,2,2,3,4,5,6,7]
pand %xmm1, %xmm2
pshufd $0xf5, %xmm15, %xmm15   # xmm15 = xmm15[1,1,3,3]
pshuflw $0xe8, %xmm15, %xmm1    # xmm1 = xmm15[0,2,2,3,4,5,6,7]
por %xmm2, %xmm1
pxor %xmm10, %xmm1
packssdw %xmm1, %xmm1
movd %xmm1, %edx
testb $0x1, %dl
je 0x4622
leal 0x31(%rcx), %edx
movb %dl, (%r13,%rcx)
pand %xmm14, %xmm13
por %xmm15, %xmm13
packssdw %xmm13, %xmm13
pxor %xmm10, %xmm13
packssdw %xmm13, %xmm13
packsswb %xmm13, %xmm13
movd %xmm13, %edx
shrl $0x8, %edx
testb $0x1, %dl
je 0x4655
leal 0x32(%rcx), %edx
movb %dl, 0x1(%r13,%rcx)
movdqa %xmm11, %xmm1
por %xmm7, %xmm1
pxor %xmm9, %xmm1
movdqa %xmm1, %xmm2
pcmpgtd %xmm12, %xmm2
pshufd $0xa0, %xmm2, %xmm13    # xmm13 = xmm2[0,0,2,2]
pcmpeqd %xmm12, %xmm1
pshufd $0xf5, %xmm1, %xmm14    # xmm14 = xmm1[1,1,3,3]
movdqa %xmm14, %xmm1
pand %xmm13, %xmm1
pshufd $0xf5, %xmm2, %xmm15    # xmm15 = xmm2[1,1,3,3]
por %xmm15, %xmm1
packssdw %xmm1, %xmm1
pxor %xmm10, %xmm1
packssdw %xmm1, %xmm1
packsswb %xmm1, %xmm1
movd %xmm1, %edx
shrl $0x10, %edx
testb $0x1, %dl
je 0x46b7
leal 0x33(%rcx), %edx
movb %dl, 0x2(%r13,%rcx)
pshufhw $0x84, %xmm13, %xmm1    # xmm1 = xmm13[0,1,2,3,4,5,4,6]
pshufhw $0x84, %xmm14, %xmm2    # xmm2 = xmm14[0,1,2,3,4,5,4,6]
pand %xmm1, %xmm2
pshufhw $0x84, %xmm15, %xmm1    # xmm1 = xmm15[0,1,2,3,4,5,4,6]
por %xmm2, %xmm1
pxor %xmm10, %xmm1
packssdw %xmm1, %xmm1
packsswb %xmm1, %xmm1
movd %xmm1, %edx
shrl $0x18, %edx
testb $0x1, %dl
je 0x46f2
leal 0x34(%rcx), %edx
movb %dl, 0x3(%r13,%rcx)
movdqa %xmm11, %xmm1
por %xmm6, %xmm1
pxor %xmm9, %xmm1
movdqa %xmm1, %xmm2
pcmpgtd %xmm12, %xmm2
pshufd $0xa0, %xmm2, %xmm14    # xmm14 = xmm2[0,0,2,2]
pshuflw $0xe8, %xmm14, %xmm15   # xmm15 = xmm14[0,2,2,3,4,5,6,7]
pcmpeqd %xmm12, %xmm1
pshufd $0xf5, %xmm1, %xmm13    # xmm13 = xmm1[1,1,3,3]
pshuflw $0xe8, %xmm13, %xmm1    # xmm1 = xmm13[0,2,2,3,4,5,6,7]
pand %xmm15, %xmm1
pshufd $0xf5, %xmm2, %xmm15    # xmm15 = xmm2[1,1,3,3]
pshuflw $0xe8, %xmm15, %xmm2    # xmm2 = xmm15[0,2,2,3,4,5,6,7]
por %xmm1, %xmm2
pxor %xmm10, %xmm2
packssdw %xmm2, %xmm1
packsswb %xmm1, %xmm1
pextrw $0x2, %xmm1, %edx
testb $0x1, %dl
je 0x475a
leal 0x35(%rcx), %edx
movb %dl, 0x4(%r13,%rcx)
pand %xmm14, %xmm13
por %xmm15, %xmm13
packssdw %xmm13, %xmm13
pxor %xmm10, %xmm13
packssdw %xmm13, %xmm1
packsswb %xmm1, %xmm1
pextrw $0x2, %xmm1, %edx
shrl $0x8, %edx
testb $0x1, %dl
je 0x478c
leal 0x36(%rcx), %edx
movb %dl, 0x5(%r13,%rcx)
movdqa %xmm11, %xmm1
por %xmm5, %xmm1
pxor %xmm9, %xmm1
movdqa %xmm1, %xmm2
pcmpgtd %xmm12, %xmm2
pshufd $0xa0, %xmm2, %xmm13    # xmm13 = xmm2[0,0,2,2]
pcmpeqd %xmm12, %xmm1
pshufd $0xf5, %xmm1, %xmm14    # xmm14 = xmm1[1,1,3,3]
movdqa %xmm14, %xmm1
pand %xmm13, %xmm1
pshufd $0xf5, %xmm2, %xmm15    # xmm15 = xmm2[1,1,3,3]
por %xmm15, %xmm1
packssdw %xmm1, %xmm1
pxor %xmm10, %xmm1
packssdw %xmm1, %xmm1
packsswb %xmm1, %xmm1
pextrw $0x3, %xmm1, %edx
testb $0x1, %dl
je 0x47ec
leal 0x37(%rcx), %edx
movb %dl, 0x6(%r13,%rcx)
pshufhw $0x84, %xmm13, %xmm1    # xmm1 = xmm13[0,1,2,3,4,5,4,6]
pshufhw $0x84, %xmm14, %xmm2    # xmm2 = xmm14[0,1,2,3,4,5,4,6]
pand %xmm1, %xmm2
pshufhw $0x84, %xmm15, %xmm1    # xmm1 = xmm15[0,1,2,3,4,5,4,6]
por %xmm2, %xmm1
pxor %xmm10, %xmm1
packssdw %xmm1, %xmm1
packsswb %xmm1, %xmm1
pextrw $0x3, %xmm1, %edx
shrl $0x8, %edx
testb $0x1, %dl
je 0x4828
leal 0x38(%rcx), %edx
movb %dl, 0x7(%r13,%rcx)
movdqa %xmm11, %xmm1
por %xmm4, %xmm1
pxor %xmm9, %xmm1
movdqa %xmm1, %xmm2
pcmpgtd %xmm12, %xmm2
pshufd $0xa0, %xmm2, %xmm14    # xmm14 = xmm2[0,0,2,2]
pshuflw $0xe8, %xmm14, %xmm15   # xmm15 = xmm14[0,2,2,3,4,5,6,7]
pcmpeqd %xmm12, %xmm1
pshufd $0xf5, %xmm1, %xmm13    # xmm13 = xmm1[1,1,3,3]
pshuflw $0xe8, %xmm13, %xmm1    # xmm1 = xmm13[0,2,2,3,4,5,6,7]
pand %xmm15, %xmm1
pshufd $0xf5, %xmm2, %xmm15    # xmm15 = xmm2[1,1,3,3]
pshuflw $0xe8, %xmm15, %xmm2    # xmm2 = xmm15[0,2,2,3,4,5,6,7]
por %xmm1, %xmm2
pxor %xmm10, %xmm2
packssdw %xmm2, %xmm2
packsswb %xmm2, %xmm1
pextrw $0x4, %xmm1, %edx
testb $0x1, %dl
je 0x4890
leal 0x39(%rcx), %edx
movb %dl, 0x8(%r13,%rcx)
pand %xmm14, %xmm13
por %xmm15, %xmm13
packssdw %xmm13, %xmm13
pxor %xmm10, %xmm13
packssdw %xmm13, %xmm13
packsswb %xmm13, %xmm1
pextrw $0x4, %xmm1, %edx
shrl $0x8, %edx
testb $0x1, %dl
je 0x48c3
leal 0x3a(%rcx), %edx
movb %dl, 0x9(%r13,%rcx)
movdqa %xmm11, %xmm1
por %xmm3, %xmm1
pxor %xmm9, %xmm1
movdqa %xmm1, %xmm2
pcmpgtd %xmm12, %xmm2
pshufd $0xa0, %xmm2, %xmm13    # xmm13 = xmm2[0,0,2,2]
pcmpeqd %xmm12, %xmm1
pshufd $0xf5, %xmm1, %xmm14    # xmm14 = xmm1[1,1,3,3]
movdqa %xmm14, %xmm1
pand %xmm13, %xmm1
pshufd $0xf5, %xmm2, %xmm15    # xmm15 = xmm2[1,1,3,3]
por %xmm15, %xmm1
packssdw %xmm1, %xmm1
pxor %xmm10, %xmm1
packssdw %xmm1, %xmm1
packsswb %xmm1, %xmm1
pextrw $0x5, %xmm1, %edx
testb $0x1, %dl
je 0x4923
leal 0x3b(%rcx), %edx
movb %dl, 0xa(%r13,%rcx)
pshufhw $0x84, %xmm13, %xmm1    # xmm1 = xmm13[0,1,2,3,4,5,4,6]
pshufhw $0x84, %xmm14, %xmm2    # xmm2 = xmm14[0,1,2,3,4,5,4,6]
pand %xmm1, %xmm2
pshufhw $0x84, %xmm15, %xmm1    # xmm1 = xmm15[0,1,2,3,4,5,4,6]
por %xmm2, %xmm1
pxor %xmm10, %xmm1
packssdw %xmm1, %xmm1
packsswb %xmm1, %xmm1
pextrw $0x5, %xmm1, %edx
shrl $0x8, %edx
testb $0x1, %dl
je 0x495f
leal 0x3c(%rcx), %edx
movb %dl, 0xb(%r13,%rcx)
movdqa %xmm11, %xmm1
por 0x2a64(%rip), %xmm1     # 0x73d0
pxor %xmm9, %xmm1
movdqa %xmm1, %xmm2
pcmpgtd %xmm12, %xmm2
pshufd $0xa0, %xmm2, %xmm14    # xmm14 = xmm2[0,0,2,2]
pshuflw $0xe8, %xmm14, %xmm15   # xmm15 = xmm14[0,2,2,3,4,5,6,7]
pcmpeqd %xmm12, %xmm1
pshufd $0xf5, %xmm1, %xmm13    # xmm13 = xmm1[1,1,3,3]
pshuflw $0xe8, %xmm13, %xmm1    # xmm1 = xmm13[0,2,2,3,4,5,6,7]
pand %xmm15, %xmm1
pshufd $0xf5, %xmm2, %xmm15    # xmm15 = xmm2[1,1,3,3]
pshuflw $0xe8, %xmm15, %xmm2    # xmm2 = xmm15[0,2,2,3,4,5,6,7]
por %xmm1, %xmm2
pxor %xmm10, %xmm2
packssdw %xmm2, %xmm1
packsswb %xmm1, %xmm1
pextrw $0x6, %xmm1, %edx
testb $0x1, %dl
je 0x49cb
leal 0x3d(%rcx), %edx
movb %dl, 0xc(%r13,%rcx)
pand %xmm14, %xmm13
por %xmm15, %xmm13
packssdw %xmm13, %xmm13
pxor %xmm10, %xmm13
packssdw %xmm13, %xmm1
packsswb %xmm1, %xmm1
pextrw $0x6, %xmm1, %edx
shrl $0x8, %edx
testb $0x1, %dl
je 0x49fd
leal 0x3e(%rcx), %edx
movb %dl, 0xd(%r13,%rcx)
por 0x29ba(%rip), %xmm11    # 0x73c0
pxor %xmm9, %xmm11
movdqa %xmm11, %xmm1
pcmpgtd %xmm12, %xmm1
pshufd $0xa0, %xmm1, %xmm13    # xmm13 = xmm1[0,0,2,2]
pcmpeqd %xmm12, %xmm11
pshufd $0xf5, %xmm11, %xmm11   # xmm11 = xmm11[1,1,3,3]
movdqa %xmm11, %xmm2
pand %xmm13, %xmm2
pshufd $0xf5, %xmm1, %xmm12    # xmm12 = xmm1[1,1,3,3]
por %xmm12, %xmm2
packssdw %xmm2, %xmm1
pxor %xmm10, %xmm1
packssdw %xmm1, %xmm1
packsswb %xmm1, %xmm1
pextrw $0x7, %xmm1, %edx
testb $0x1, %dl
je 0x4a5e
leal 0x3f(%rcx), %edx
movb %dl, 0xe(%r13,%rcx)
pshufhw $0x84, %xmm13, %xmm1    # xmm1 = xmm13[0,1,2,3,4,5,4,6]
pshufhw $0x84, %xmm11, %xmm2    # xmm2 = xmm11[0,1,2,3,4,5,4,6]
pand %xmm1, %xmm2
pshufhw $0x84, %xmm12, %xmm1    # xmm1 = xmm12[0,1,2,3,4,5,4,6]
por %xmm2, %xmm1
pxor %xmm10, %xmm1
packssdw %xmm1, %xmm1
packsswb %xmm1, %xmm1
pextrw $0x7, %xmm1, %edx
shrl $0x8, %edx
testb $0x1, %dl
je 0x4a9a
leal 0x40(%rcx), %edx
movb %dl, 0xf(%r13,%rcx)
addq $0x10, %rcx
cmpq %rcx, %rax
jne 0x45a9
movslq %r12d, %rax
movb $0x0, -0x30(%r13,%rax)
movq %r15, %rdi
movq %r13, %rsi
callq 0x4d4c
cmpl $0x0, 0x8(%rax)
jle 0x4c62
movq %rax, %r12
xorl %ebx, %ebx
xorl %r15d, %r15d
movq %rbp, 0x8(%rsp)
movq %rax, 0x10(%rsp)
movq (%r12), %rax
movq (%rax,%rbx,8), %r13
movsbl (%r13), %edi
leaq 0x2a10(%rip), %rsi      # 0x74fb
callq 0x504d
movq %r13, %rdi
movq %rax, %rsi
callq 0x4d4c
testq %rax, %rax
je 0x4b7d
movq %rax, %rbp
cmpl $0x2, 0x8(%rax)
jne 0x4b7d
movq (%rbp), %rax
movq (%rax), %r12
movsbl (%r12), %edi
leaq 0x1645(%rip), %rsi      # 0x6161
callq 0x504d
movq %r12, %rdi
movq %rax, %rsi
callq 0x4d4c
testq %rax, %rax
je 0x4b97
movq %rax, %r13
cmpl $0x2, 0x8(%rax)
jne 0x4b97
movq (%r13), %rax
movq (%rax), %rdi
movsd 0x1537(%rip), %xmm0     # 0x6080
callq 0x50a9
xorl %edi, %edi
movq %rax, %rsi
callq 0x4eb7
movq %rax, %r12
movq (%r13), %rax
movq 0x8(%rax), %rdi
movsd 0x1515(%rip), %xmm0     # 0x6080
callq 0x50a9
movq %r12, %rdi
movq %rax, %rsi
callq 0x4eb7
jmp 0x4ba7
movq %r13, %rdi
movq 0x1508(%rip), %xmm0     # 0x6090
callq 0x50a9
movq 0x8(%rsp), %rbp
jmp 0x4c41
movq %r12, %rdi
movsd 0x14e6(%rip), %xmm0     # 0x6088
callq 0x50a9
xorl %edi, %edi
movq %rax, %rsi
callq 0x4eb7
movq %rax, %r13
movq (%rbp), %rax
movq 0x8(%rax), %r12
movq %r12, %rdi
leaq 0x2958(%rip), %rsi      # 0x751e
callq 0x4d4c
testq %rax, %rax
je 0x4c1c
movq %rax, %rbp
cmpl $0x2, 0x8(%rax)
jne 0x4c1c
movq (%rbp), %rax
movq (%rax), %rdi
movsd 0x1498(%rip), %xmm0     # 0x6080
callq 0x50a9
xorl %edi, %edi
movq %rax, %rsi
callq 0x4eb7
movq %rax, %r12
movq (%rbp), %rax
movq 0x8(%rax), %rdi
movq 0x1476(%rip), %xmm0     # 0x6080
callq 0x50a9
movq %r12, %rdi
movq %rax, %rsi
callq 0x4eb7
jmp 0x4c2c
movq %r12, %rdi
movq 0x1461(%rip), %xmm0     # 0x6088
callq 0x50a9
movq 0x8(%rsp), %rbp
movq %r13, %rdi
movq %rax, %rsi
callq 0x4eb7
movq 0x10(%rsp), %r12
movq %r15, %rdi
movq %rax, %rsi
callq 0x4eb7
movq %rax, %r15
incq %rbx
movslq 0x8(%r12), %rax
cmpq %rax, %rbx
jl 0x4ad7
jmp 0x4c65
xorl %r15d, %r15d
cmpl $0x0, 0x8(%r15)
jle 0x4d3d
xorl %r13d, %r13d
movl $0x10, %edi
callq 0x5257
movq %rax, %r12
movb $0x0, (%rax)
movq $0x0, 0x8(%rax)
movslq %r13d, %rax
testq %rbp, %rbp
je 0x4ca8
movzbl (%rbp,%rax), %edx
xorl %ecx, %ecx
cmpl $0x20, %edx
je 0x4caa
cmpl $0x2d, %edx
je 0x4caa
movl %edx, %ecx
jmp 0x4caa
xorl %ecx, %ecx
movb %cl, (%r12)
movq (%r15), %rcx
movsd (%rcx,%rax,8), %xmm0
movslq 0x8(%r15), %rbx
decq %rbx
cmpl %ebx, %eax
jge 0x4cdd
testq %rbp, %rbp
je 0x4ccd
cmpb $0x20, 0x1(%rbp,%rax)
jne 0x4ce2
addsd 0x8(%rcx,%rax,8), %xmm0
incq %rax
cmpq %rbx, %rax
jl 0x4cc1
jmp 0x4ce4
movl %r13d, %ebx
jmp 0x4ce4
movl %eax, %ebx
movsd %xmm0, 0x8(%r12)
movq (%r14), %r13
movl 0x8(%r14), %eax
leal 0x8(,%rax,8), %edi
callq 0x5257
movq %rax, (%r14)
movslq 0x8(%r14), %rcx
testq %rcx, %rcx
jle 0x4d23
xorl %eax, %eax
movq (%r13,%rax,8), %rdx
movq (%r14), %rsi
movq %rdx, (%rsi,%rax,8)
incq %rax
cmpq %rax, %rcx
jne 0x4d0c
movq (%r14), %rax
movq %r12, (%rax,%rcx,8)
leal 0x1(%rcx), %eax
movl %eax, 0x8(%r14)
incl %ebx
movl %ebx, %r13d
cmpl 0x8(%r15), %ebx
jl 0x4c73
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq