// File: /workspace/github_c_makefile_star2_O0/mbitsnbites[P]SoftFP/softfloat.c
// Function: float128_mul
float128 float128_mul(float128 a, float128 b, float_status *status)
{
    flag aSign, bSign, zSign;
    int32 aExp, bExp, zExp;
    uint64_t aSig0, aSig1, bSig0, bSig1, zSig0, zSig1, zSig2, zSig3;
    float128 z;

    aSig1 = extractFloat128Frac1( a );
    aSig0 = extractFloat128Frac0( a );
    aExp = extractFloat128Exp( a );
    aSign = extractFloat128Sign( a );
    bSig1 = extractFloat128Frac1( b );
    bSig0 = extractFloat128Frac0( b );
    bExp = extractFloat128Exp( b );
    bSign = extractFloat128Sign( b );
    zSign = aSign ^ bSign;
    if ( aExp == 0x7FFF ) {
        if (    ( aSig0 | aSig1 )
             || ( ( bExp == 0x7FFF ) && ( bSig0 | bSig1 ) ) ) {
            return propagateFloat128NaN(a, b, status);
        }
        if ( ( bExp | bSig0 | bSig1 ) == 0 ) goto invalid;
        return packFloat128( zSign, 0x7FFF, 0, 0 );
    }
    if ( bExp == 0x7FFF ) {
        if (bSig0 | bSig1) {
            return propagateFloat128NaN(a, b, status);
        }
        if ( ( aExp | aSig0 | aSig1 ) == 0 ) {
 invalid:
            float_raise(float_flag_invalid, status);
            z.low = float128_default_nan_low;
            z.high = float128_default_nan_high;
            return z;
        }
        return packFloat128( zSign, 0x7FFF, 0, 0 );
    }
    if ( aExp == 0 ) {
        if ( ( aSig0 | aSig1 ) == 0 ) return packFloat128( zSign, 0, 0, 0 );
        normalizeFloat128Subnormal( aSig0, aSig1, &aExp, &aSig0, &aSig1 );
    }
    if ( bExp == 0 ) {
        if ( ( bSig0 | bSig1 ) == 0 ) return packFloat128( zSign, 0, 0, 0 );
        normalizeFloat128Subnormal( bSig0, bSig1, &bExp, &bSig0, &bSig1 );
    }
    zExp = aExp + bExp - 0x4000;
    aSig0 |= LIT64( 0x0001000000000000 );
    shortShift128Left( bSig0, bSig1, 16, &bSig0, &bSig1 );
    mul128To256( aSig0, aSig1, bSig0, bSig1, &zSig0, &zSig1, &zSig2, &zSig3 );
    add128( zSig0, zSig1, aSig0, aSig1, &zSig0, &zSig1 );
    zSig2 |= ( zSig3 != 0 );
    if ( LIT64( 0x0002000000000000 ) <= zSig0 ) {
        shift128ExtraRightJamming(
            zSig0, zSig1, zSig2, 1, &zSig0, &zSig1, &zSig2 );
        ++zExp;
    }
    return roundAndPackFloat128(zSign, zExp, zSig0, zSig1, zSig2, status);

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xb0, %rsp
movq %rdi, -0x20(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x30(%rbp)
movq %rcx, -0x28(%rbp)
movq %r8, -0x38(%rbp)
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x1e410
movq %rax, -0x58(%rbp)
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x1e430
movq %rax, -0x50(%rbp)
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x1e450
movl %eax, -0x40(%rbp)
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x1e470
movb %al, -0x39(%rbp)
movq -0x30(%rbp), %rdi
movq -0x28(%rbp), %rsi
callq 0x1e410
movq %rax, -0x68(%rbp)
movq -0x30(%rbp), %rdi
movq -0x28(%rbp), %rsi
callq 0x1e430
movq %rax, -0x60(%rbp)
movq -0x30(%rbp), %rdi
movq -0x28(%rbp), %rsi
callq 0x1e450
movl %eax, -0x44(%rbp)
movq -0x30(%rbp), %rdi
movq -0x28(%rbp), %rsi
callq 0x1e470
movb %al, -0x3a(%rbp)
movzbl -0x39(%rbp), %eax
movzbl -0x3a(%rbp), %ecx
xorl %ecx, %eax
movb %al, -0x3b(%rbp)
cmpl $0x7fff, -0x40(%rbp)    # imm = 0x7FFF
jne 0x2007e
movq -0x50(%rbp), %rax
orq -0x58(%rbp), %rax
cmpq $0x0, %rax
jne 0x20022
cmpl $0x7fff, -0x44(%rbp)    # imm = 0x7FFF
jne 0x20048
movq -0x60(%rbp), %rax
orq -0x68(%rbp), %rax
cmpq $0x0, %rax
je 0x20048
movq -0x38(%rbp), %r8
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x30(%rbp), %rdx
movq -0x28(%rbp), %rcx
callq 0x1f480
movq %rax, -0x10(%rbp)
movq %rdx, -0x8(%rbp)
jmp 0x202d9
movslq -0x44(%rbp), %rax
orq -0x60(%rbp), %rax
orq -0x68(%rbp), %rax
cmpq $0x0, %rax
jne 0x2005c
jmp 0x200d3
movl $0x7fff, %esi           # imm = 0x7FFF
xorl %eax, %eax
movl %eax, %ecx
movzbl -0x3b(%rbp), %edi
movq %rcx, %rdx
callq 0x11a80
movq %rax, -0x10(%rbp)
movq %rdx, -0x8(%rbp)
jmp 0x202d9
cmpl $0x7fff, -0x44(%rbp)    # imm = 0x7FFF
jne 0x2013a
movq -0x60(%rbp), %rax
orq -0x68(%rbp), %rax
cmpq $0x0, %rax
je 0x200bf
movq -0x38(%rbp), %r8
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x30(%rbp), %rdx
movq -0x28(%rbp), %rcx
callq 0x1f480
movq %rax, -0x10(%rbp)
movq %rdx, -0x8(%rbp)
jmp 0x202d9
movslq -0x40(%rbp), %rax
orq -0x50(%rbp), %rax
orq -0x58(%rbp), %rax
cmpq $0x0, %rax
jne 0x20118
jmp 0x200d3
movq -0x38(%rbp), %rsi
movl $0x1, %edi
callq 0x11080
movq $0x0, -0x98(%rbp)
movabsq $0x7fff800000000000, %rax # imm = 0x7FFF800000000000
movq %rax, -0x90(%rbp)
movq -0x98(%rbp), %rax
movq %rax, -0x10(%rbp)
movq -0x90(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x202d9
movl $0x7fff, %esi           # imm = 0x7FFF
xorl %eax, %eax
movl %eax, %ecx
movzbl -0x3b(%rbp), %edi
movq %rcx, %rdx
callq 0x11a80
movq %rax, -0x10(%rbp)
movq %rdx, -0x8(%rbp)
jmp 0x202d9
cmpl $0x0, -0x40(%rbp)
jne 0x20186
movq -0x50(%rbp), %rax
orq -0x58(%rbp), %rax
cmpq $0x0, %rax
jne 0x2016d
xorl %esi, %esi
xorl %eax, %eax
movl %eax, %ecx
movzbl -0x3b(%rbp), %edi
movq %rcx, %rdx
callq 0x11a80
movq %rax, -0x10(%rbp)
movq %rdx, -0x8(%rbp)
jmp 0x202d9
movq -0x50(%rbp), %rdi
movq -0x58(%rbp), %rsi
leaq -0x40(%rbp), %rdx
leaq -0x50(%rbp), %rcx
leaq -0x58(%rbp), %r8
callq 0x1ee00
cmpl $0x0, -0x44(%rbp)
jne 0x201d2
movq -0x60(%rbp), %rax
orq -0x68(%rbp), %rax
cmpq $0x0, %rax
jne 0x201b9
xorl %esi, %esi
xorl %eax, %eax
movl %eax, %ecx
movzbl -0x3b(%rbp), %edi
movq %rcx, %rdx
callq 0x11a80
movq %rax, -0x10(%rbp)
movq %rdx, -0x8(%rbp)
jmp 0x202d9
movq -0x60(%rbp), %rdi
movq -0x68(%rbp), %rsi
leaq -0x44(%rbp), %rdx
leaq -0x60(%rbp), %rcx
leaq -0x68(%rbp), %r8
callq 0x1ee00
movl -0x40(%rbp), %eax
addl -0x44(%rbp), %eax
subl $0x4000, %eax           # imm = 0x4000
movl %eax, -0x48(%rbp)
movabsq $0x1000000000000, %rax  # imm = 0x1000000000000
orq -0x50(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x60(%rbp), %rdi
movq -0x68(%rbp), %rsi
movl $0x10, %edx
leaq -0x60(%rbp), %rcx
leaq -0x68(%rbp), %r8
callq 0x121c0
movq -0x50(%rbp), %rdi
movq -0x58(%rbp), %rsi
movq -0x60(%rbp), %rdx
movq -0x68(%rbp), %rcx
leaq -0x70(%rbp), %r8
leaq -0x78(%rbp), %r9
leaq -0x80(%rbp), %r10
leaq -0x88(%rbp), %rax
movq %r10, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x202f0
movq -0x70(%rbp), %rdi
movq -0x78(%rbp), %rsi
movq -0x50(%rbp), %rdx
movq -0x58(%rbp), %rcx
leaq -0x70(%rbp), %r8
leaq -0x78(%rbp), %r9
callq 0x18bd0
cmpq $0x0, -0x88(%rbp)
setne %al
andb $0x1, %al
movzbl %al, %eax
cltq
orq -0x80(%rbp), %rax
movq %rax, -0x80(%rbp)
movabsq $0x2000000000000, %rax  # imm = 0x2000000000000
cmpq -0x70(%rbp), %rax
ja 0x202b3
movq -0x70(%rbp), %rdi
movq -0x78(%rbp), %rsi
movq -0x80(%rbp), %rdx
movl $0x1, %ecx
leaq -0x70(%rbp), %r8
leaq -0x78(%rbp), %r9
leaq -0x80(%rbp), %rax
movq %rax, (%rsp)
callq 0x20420
movl -0x48(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x48(%rbp)
movb -0x3b(%rbp), %al
movl -0x48(%rbp), %esi
movq -0x70(%rbp), %rdx
movq -0x78(%rbp), %rcx
movq -0x80(%rbp), %r8
movq -0x38(%rbp), %r9
movzbl %al, %edi
callq 0x20590
movq %rax, -0x10(%rbp)
movq %rdx, -0x8(%rbp)
movq -0x10(%rbp), %rax
movq -0x8(%rbp), %rdx
addq $0xb0, %rsp
popq %rbp
retq
nopw (%rax,%rax)