user: Please show me the C implementation that matches the assembly code listed below:

```asm
<IntegerUnpacker_8>:
  endbr64
  cmp    $0x8,%edx
  jg     L272
  cmp    %ecx,%edx
  jl     L272
  test   %r9d,%r9d
  lea    0x1f(%r9),%eax
  mov    %r9d,%ecx
  push   %r14
  cmovns %r9d,%eax
  sar    $0x1f,%ecx
  push   %r13
  shr    $0x1b,%ecx
  push   %r12
  sar    $0x5,%eax
  push   %rbp
  cltq
  push   %rbx
  lea    (%rdi,%rax,4),%r10
  lea    (%r9,%rcx,1),%eax
  and    $0x1f,%eax
  sub    %eax,%ecx
  mov    (%r10),%eax
  lea    0x20(%rcx),%ebp
  je     L348
  mov    0x4(%r10),%ecx
  shl    $0x20,%rax
  lea    0x8(%r10),%r11
  or     %rcx,%rax
  mov    %r9d,%ecx
  and    $0x1f,%ecx
  mov    %rax,%rbx
  shl    %cl,%rbx
  cmp    $0x20,%ebp
  cmovl  %rbx,%rax
L171:
  cmp    $0x3,%r8d
  jle    L322
  sub    $0x4,%r8d
  mov    $0x40,%r9d
  mov    %r8d,%ebx
  sub    %edx,%r9d
  shr    $0x2,%ebx
  lea    0x1(%rbx),%ecx
  lea    (%rsi,%rcx,4),%r10
  jmp    L192
  nopw   0x0(%rax,%rax,1)
L153:
  cmp    %r10,%rsi
  je     L15
L192:
  mov    %rax,%rdi
  mov    %r9d,%ecx
  add    $0x4,%rsi
  shr    %cl,%rdi
  mov    %edx,%ecx
  shl    %cl,%rax
  mov    %r9d,%ecx
  mov    %dil,-0x4(%rsi)
  mov    %ebp,%edi
  mov    %rax,%r14
  sub    %edx,%edi
  shr    %cl,%r14
  mov    %edx,%ecx
  sub    %edx,%edi
  shl    %cl,%rax
  mov    %r14b,-0x3(%rsi)
  mov    %r9d,%ecx
  sub    %edx,%edi
  mov    %rax,%r14
  mov    %edi,%ebp
  shr    %cl,%r14
  mov    %edx,%ecx
  sub    %edx,%ebp
  shl    %cl,%rax
  mov    %r14b,-0x2(%rsi)
  mov    %r9d,%ecx
  mov    %rax,%r14
  shr    %cl,%r14
  mov    %edx,%ecx
  mov    %r14b,-0x1(%rsi)
  shl    %cl,%rax
  test   %ebp,%ebp
  jg     L153
  lea    0x4(%r11),%r12
  mov    (%r11),%r11d
  jne    L98
  or     %r11,%rax
L325:
  add    $0x20,%ebp
  mov    %r12,%r11
  cmp    %r10,%rsi
  jne    L192
L15:
  neg    %ebx
  lea    (%r8,%rbx,4),%r8d
L346:
  test   %r8d,%r8d
  jle    L197
  mov    $0x40,%edi
  movslq %r8d,%r8
  sub    %edx,%edi
  add    %r10,%r8
L324:
  mov    %rax,%rsi
  mov    %edi,%ecx
  add    $0x1,%r10
  shr    %cl,%rsi
  mov    %edx,%ecx
  mov    %sil,-0x1(%r10)
  mov    %ebp,%esi
  shl    %cl,%rax
  sub    %edx,%esi
  test   %esi,%esi
  jle    L273
  mov    %esi,%ebp
L198:
  cmp    %r8,%r10
  jne    L324
L197:
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  ret
  nopl   (%rax)
L348:
  lea    0x4(%r10),%rdi
  cmp    $0x8,%edx
  je     L4
  cmp    $0x6,%edx
  jne    L118
  cmp    $0xf,%r8d
  jle    L113
  sub    $0x10,%r8d
  mov    %rdi,%r10
  mov    %r8d,%r12d
  shr    $0x4,%r12d
  lea    0x1(%r12),%ebx
  mov    %rbx,%r11
  shl    $0x4,%r11
  add    %rsi,%r11
  nopl   (%rax)
L312:
  mov    %eax,%r13d
  mov    (%r10),%ecx
  mov    0x4(%r10),%r9d
  add    $0xc,%r10
  mov    %r13d,%r14d
  mov    -0x4(%r10),%eax
  shr    $0x1a,%r14d
  mov    %r14b,(%rsi)
  mov    %r13d,%r14d
  shr    $0x14,%r14d
  and    $0x3f,%r14d
  mov    %r14b,0x1(%rsi)
  mov    %r13d,%r14d
  shr    $0xe,%r14d
  and    $0x3f,%r14d
  mov    %r14b,0x2(%rsi)
  mov    %r13d,%r14d
  shr    $0x8,%r14d
  and    $0x3f,%r14d
  mov    %r14b,0x3(%rsi)
  mov    %r13d,%r14d
  shl    $0x4,%r13d
  shr    $0x2,%r14b
  and    $0x30,%r13d
  mov    %r14b,0x4(%rsi)
  mov    %ecx,%r14d
  shr    $0x1c,%r14d
  or     %r14d,%r13d
  mov    %r13b,0x5(%rsi)
  mov    %ecx,%r13d
  shr    $0x16,%r13d
  and    $0x3f,%r13d
  mov    %r13b,0x6(%rsi)
  mov    %ecx,%r13d
  shr    $0x10,%r13d
  and    $0x3f,%r13d
  mov    %r13b,0x7(%rsi)
  mov    %ecx,%r13d
  shr    $0xa,%r13d
  and    $0x3f,%r13d
  mov    %r13b,0x8(%rsi)
  mov    %ecx,%r13d
  shl    $0x2,%ecx
  shr    $0x4,%r13d
  and    $0x3c,%ecx
  and    $0x3f,%r13d
  mov    %r13b,0x9(%rsi)
  mov    %r9d,%r13d
  shr    $0x1e,%r13d
  or     %r13d,%ecx
  mov    %cl,0xa(%rsi)
  mov    %r9d,%ecx
  shr    $0x18,%ecx
  and    $0x3f,%ecx
  mov    %cl,0xb(%rsi)
  mov    %r9d,%ecx
  shr    $0x12,%ecx
  and    $0x3f,%ecx
  mov    %cl,0xc(%rsi)
  mov    %r9d,%ecx
  shr    $0xc,%ecx
  and    $0x3f,%ecx
  mov    %cl,0xd(%rsi)
  mov    %r9d,%ecx
  shr    $0x6,%ecx
  and    $0x3f,%ecx
  add    $0x10,%rsi
  and    $0x3f,%r9d
  mov    %cl,-0x2(%rsi)
  mov    %r9b,-0x1(%rsi)
  cmp    %r11,%rsi
  jne    L312
  lea    (%rbx,%rbx,2),%rcx
  shl    $0x4,%r12d
  lea    (%rdi,%rcx,4),%rdi
  sub    %r12d,%r8d
L77:
  mov    %r11,%rsi
  mov    %rdi,%r9
  nopl   0x0(%rax,%rax,1)
L41:
  mov    (%r9),%ecx
  shl    $0x20,%rax
  lea    0x4(%r9),%r11
  or     %rcx,%rax
  jmp    L171
  nopl   0x0(%rax,%rax,1)
L98:
  mov    %edx,%ecx
  sub    %edi,%ecx
  shr    %cl,%rax
  or     %r11,%rax
  shl    %cl,%rax
  jmp    L325
  nopw   0x0(%rax,%rax,1)
L273:
  lea    0x4(%r11),%r9
  mov    (%r11),%r11d
  jne    L244
  or     %r11,%rax
L173:
  lea    0x20(%rsi),%ebp
  mov    %r9,%r11
  jmp    L198
  nopw   0x0(%rax,%rax,1)
L244:
  mov    %edx,%ecx
  sub    %ebp,%ecx
  shr    %cl,%rax
  or     %r11,%rax
  shl    %cl,%rax
  jmp    L173
  nop
L272:
  ret
  nopl   0x0(%rax)
L4:
  cmp    $0x7,%r8d
  jle    L22
  sub    $0x8,%r8d
  mov    %rsi,%rcx
  mov    %rdi,%r9
  mov    %r8d,%r11d
  shr    $0x3,%r11d
  mov    %r11d,%r14d
  lea    0xc(%r10,%r14,8),%r12
  nopl   0x0(%rax,%rax,1)
L21:
  mov    %eax,%r10d
  mov    %ah,0x2(%rcx)
  add    $0x8,%r9
  add    $0x8,%rcx
  shr    $0x18,%r10d
  mov    %al,-0x5(%rcx)
  mov    %r10b,-0x8(%rcx)
  mov    %eax,%r10d
  shr    $0x10,%r10d
  mov    %r10b,-0x7(%rcx)
  mov    -0x8(%r9),%eax
  mov    %eax,%r10d
  mov    %ah,-0x2(%rcx)
  shr    $0x18,%r10d
  mov    %r10b,-0x4(%rcx)
  mov    %eax,%r10d
  shr    $0x10,%r10d
  mov    %r10b,-0x3(%rcx)
  mov    %al,-0x1(%rcx)
  mov    -0x4(%r9),%eax
  cmp    %r12,%r9
  jne    L21
  lea    0x8(,%r14,8),%rcx
  neg    %r11d
  add    %rcx,%rsi
  add    %rcx,%rdi
  lea    (%r8,%r11,8),%r8d
L22:
  mov    %rsi,%r11
  cmp    $0x1,%edx
  jne    L77
  cmp    $0x1f,%r8d
  jle    L102
  sub    $0x20,%r8d
  mov    %rsi,%rcx
  mov    %r8d,%ebx
  shr    $0x5,%ebx
  lea    0x1(%rbx),%r11d
  lea    (%rdi,%r11,4),%r9
  nopl   (%rax)
L75:
  mov    %eax,%r10d
  shr    $0x1f,%r10d
  mov    %r10b,(%rcx)
  mov    %eax,%r10d
  shr    $0x1e,%r10d
  and    $0x1,%r10d
  mov    %r10b,0x1(%rcx)
  mov    %eax,%r10d
  shr    $0x1d,%r10d
  and    $0x1,%r10d
  mov    %r10b,0x2(%rcx)
  mov    %eax,%r10d
  shr    $0x1c,%r10d
  and    $0x1,%r10d
  mov    %r10b,0x3(%rcx)
  mov    %eax,%r10d
  shr    $0x1b,%r10d
  and    $0x1,%r10d
  mov    %r10b,0x4(%rcx)
  mov    %eax,%r10d
  shr    $0x1a,%r10d
  and    $0x1,%r10d
  mov    %r10b,0x5(%rcx)
  mov    %eax,%r10d
  shr    $0x19,%r10d
  and    $0x1,%r10d
  mov    %r10b,0x6(%rcx)
  mov    %eax,%r10d
  shr    $0x18,%r10d
  and    $0x1,%r10d
  mov    %r10b,0x7(%rcx)
  mov    %eax,%r10d
  shr    $0x17,%r10d
  and    $0x1,%r10d
  mov    %r10b,0x8(%rcx)
  mov    %eax,%r10d
  shr    $0x16,%r10d
  and    $0x1,%r10d
  mov    %r10b,0x9(%rcx)
  mov    %eax,%r10d
  shr    $0x15,%r10d
  and    $0x1,%r10d
  mov    %r10b,0xa(%rcx)
  mov    %eax,%r10d
  shr    $0x14,%r10d
  and    $0x1,%r10d
  mov    %r10b,0xb(%rcx)
  mov    %eax,%r10d
  shr    $0x13,%r10d
  and    $0x1,%r10d
  mov    %r10b,0xc(%rcx)
  mov    %eax,%r10d
  shr    $0x12,%r10d
  and    $0x1,%r10d
  mov    %r10b,0xd(%rcx)
  mov    %eax,%r10d
  shr    $0x11,%r10d
  and    $0x1,%r10d
  mov    %r10b,0xe(%rcx)
  mov    %eax,%r10d
  shr    $0x10,%r10d
  and    $0x1,%r10d
  mov    %r10b,0xf(%rcx)
  mov    %eax,%r10d
  shr    $0xf,%r10d
  and    $0x1,%r10d
  add    $0x20,%rcx
  add    $0x4,%rdi
  mov    %r10b,-0x10(%rcx)
  mov    %eax,%r10d
  shr    $0xe,%r10d
  and    $0x1,%r10d
  mov    %r10b,-0xf(%rcx)
  mov    %eax,%r10d
  shr    $0xd,%r10d
  and    $0x1,%r10d
  mov    %r10b,-0xe(%rcx)
  mov    %eax,%r10d
  shr    $0xc,%r10d
  and    $0x1,%r10d
  mov    %r10b,-0xd(%rcx)
  mov    %eax,%r10d
  shr    $0xb,%r10d
  and    $0x1,%r10d
  mov    %r10b,-0xc(%rcx)
  mov    %eax,%r10d
  shr    $0xa,%r10d
  and    $0x1,%r10d
  mov    %r10b,-0xb(%rcx)
  mov    %eax,%r10d
  shr    $0x9,%r10d
  and    $0x1,%r10d
  mov    %r10b,-0xa(%rcx)
  mov    %eax,%r10d
  shr    $0x8,%r10d
  and    $0x1,%r10d
  mov    %r10b,-0x9(%rcx)
  mov    %eax,%r10d
  shr    $0x7,%r10b
  mov    %r10b,-0x8(%rcx)
  mov    %eax,%r10d
  shr    $0x6,%r10d
  and    $0x1,%r10d
  mov    %r10b,-0x7(%rcx)
  mov    %eax,%r10d
  shr    $0x5,%r10d
  and    $0x1,%r10d
  mov    %r10b,-0x6(%rcx)
  mov    %eax,%r10d
  shr    $0x4,%r10d
  and    $0x1,%r10d
  mov    %r10b,-0x5(%rcx)
  mov    %eax,%r10d
  shr    $0x3,%r10d
  and    $0x1,%r10d
  mov    %r10b,-0x4(%rcx)
  mov    %eax,%r10d
  shr    $0x2,%r10d
  and    $0x1,%r10d
  mov    %r10b,-0x3(%rcx)
  mov    %eax,%r10d
  and    $0x1,%eax
  shr    %r10d
  and    $0x1,%r10d
  mov    %r10b,-0x2(%rcx)
  mov    %al,-0x1(%rcx)
  mov    -0x4(%rdi),%eax
  cmp    %r9,%rdi
  jne    L75
  shl    $0x5,%r11
  shl    $0x5,%ebx
  add    %r11,%rsi
  sub    %ebx,%r8d
  jmp    L41
  nopl   0x0(%rax,%rax,1)
L118:
  cmp    $0x4,%edx
  jne    L42
  cmp    $0x7,%r8d
  jle    L102
  sub    $0x8,%r8d
  mov    %rsi,%rcx
  mov    %r8d,%r11d
  shr    $0x3,%r11d
  lea    0x1(%r11),%ebx
  lea    (%rdi,%rbx,4),%r9
  nopl   0x0(%rax)
L247:
  mov    %eax,%r10d
  add    $0x8,%rcx
  add    $0x4,%rdi
  shr    $0x1c,%r10d
  mov    %r10b,-0x8(%rcx)
  mov    %eax,%r10d
  shr    $0x18,%r10d
  and    $0xf,%r10d
  mov    %r10b,-0x7(%rcx)
  mov    %eax,%r10d
  shr    $0x14,%r10d
  and    $0xf,%r10d
  mov    %r10b,-0x6(%rcx)
  mov    %eax,%r10d
  shr    $0x10,%r10d
  and    $0xf,%r10d
  mov    %r10b,-0x5(%rcx)
  mov    %eax,%r10d
  shr    $0xc,%r10d
  and    $0xf,%r10d
  mov    %r10b,-0x4(%rcx)
  mov    %eax,%r10d
  shr    $0x8,%r10d
  and    $0xf,%r10d
  mov    %r10b,-0x3(%rcx)
  mov    %eax,%r10d
  and    $0xf,%eax
  shr    $0x4,%r10b
  mov    %r10b,-0x2(%rcx)
  mov    %al,-0x1(%rcx)
  mov    -0x4(%rdi),%eax
  cmp    %r9,%rdi
  jne    L247
  neg    %r11d
  lea    (%rsi,%rbx,8),%rsi
  lea    (%r8,%r11,8),%r8d
  jmp    L41
L42:
  cmp    $0x2,%edx
  jne    L22
  cmp    $0xf,%r8d
  jle    L102
  sub    $0x10,%r8d
  mov    %rsi,%rcx
  mov    %r8d,%ebx
  shr    $0x4,%ebx
  lea    0x1(%rbx),%r11d
  lea    (%rdi,%r11,4),%r9
  nopw   0x0(%rax,%rax,1)
L1:
  mov    %eax,%r10d
  add    $0x10,%rcx
  add    $0x4,%rdi
  shr    $0x1e,%r10d
  mov    %r10b,-0x10(%rcx)
  mov    %eax,%r10d
  shr    $0x1c,%r10d
  and    $0x3,%r10d
  mov    %r10b,-0xf(%rcx)
  mov    %eax,%r10d
  shr    $0x1a,%r10d
  and    $0x3,%r10d
  mov    %r10b,-0xe(%rcx)
  mov    %eax,%r10d
  shr    $0x18,%r10d
  and    $0x3,%r10d
  mov    %r10b,-0xd(%rcx)
  mov    %eax,%r10d
  shr    $0x16,%r10d
  and    $0x3,%r10d
  mov    %r10b,-0xc(%rcx)
  mov    %eax,%r10d
  shr    $0x14,%r10d
  and    $0x3,%r10d
  mov    %r10b,-0xb(%rcx)
  mov    %eax,%r10d
  shr    $0x12,%r10d
  and    $0x3,%r10d
  mov    %r10b,-0xa(%rcx)
  mov    %eax,%r10d
  shr    $0x10,%r10d
  and    $0x3,%r10d
  mov    %r10b,-0x9(%rcx)
  mov    %eax,%r10d
  shr    $0xe,%r10d
  and    $0x3,%r10d
  mov    %r10b,-0x8(%rcx)
  mov    %eax,%r10d
  shr    $0xc,%r10d
  and    $0x3,%r10d
  mov    %r10b,-0x7(%rcx)
  mov    %eax,%r10d
  shr    $0xa,%r10d
  and    $0x3,%r10d
  mov    %r10b,-0x6(%rcx)
  mov    %eax,%r10d
  shr    $0x8,%r10d
  and    $0x3,%r10d
  mov    %r10b,-0x5(%rcx)
  mov    %eax,%r10d
  shr    $0x6,%r10b
  mov    %r10b,-0x4(%rcx)
  mov    %eax,%r10d
  shr    $0x4,%r10d
  and    $0x3,%r10d
  mov    %r10b,-0x3(%rcx)
  mov    %eax,%r10d
  and    $0x3,%eax
  shr    $0x2,%r10d
  and    $0x3,%r10d
  mov    %r10b,-0x2(%rcx)
  mov    %al,-0x1(%rcx)
  mov    -0x4(%rdi),%eax
  cmp    %r9,%rdi
  jne    L1
  shl    $0x4,%r11
  shl    $0x4,%ebx
  add    %r11,%rsi
  sub    %ebx,%r8d
  jmp    L41
  nopl   (%rax)
L322:
  mov    %rsi,%r10
  jmp    L346
L102:
  mov    %rdi,%r9
  jmp    L41
L113:
  mov    %rsi,%r11
  jmp    L77
```

assistant: ```c
void IntegerUnpacker_8(void *stream, void *dst, int nbits, int nbitt, int n, int offset) {
  unsigned int *packed = (unsigned int *)stream;
  char *unpacked = (char *)dst;
  unsigned long long temp;
  unsigned int token, token1, token2, token3;
  int bleft;
  int signed_offset = 0;
  if (nbits > 8 || nbitt > nbits)
    return;
  packed += offset / 32;
  bleft = 32 - (offset % 32);
  token = *packed++;
  if (nbits == -1)
    signed_offset = -(1 << (nbitt - 1));
  if (bleft == 32) {
    if (nbits == 8) {
      while (n > 7) {
        *unpacked++ = ((token >> 24));
        *unpacked++ = ((token >> 16) & 0xFF);
        *unpacked++ = ((token >> 8) & 0xFF);
        *unpacked++ = (token & 0xFF);
        token = *packed++;
        *unpacked++ = ((token >> 24));
        *unpacked++ = ((token >> 16) & 0xFF);
        *unpacked++ = ((token >> 8) & 0xFF);
        *unpacked++ = (token & 0xFF);
        token = *packed++;
        n -= 8;
      }
    }
    if (nbits == 6) {
      while (n > 15) {
        token2 = *packed++;
        token3 = *packed++;
        token1 = *packed++;
        *unpacked++ = ((token >> 26));
        *unpacked++ = ((token >> 20) & 0x3F);
        *unpacked++ = ((token >> 14) & 0x3F);
        *unpacked++ = ((token >> 8) & 0x3F);
        *unpacked++ = ((token >> 2) & 0x3F);
        *unpacked++ = (((token & 0x3) << 4) | (token2 >> 28));
        *unpacked++ = ((token2 >> 22) & 0x3F);
        *unpacked++ = ((token2 >> 16) & 0x3F);
        *unpacked++ = ((token2 >> 10) & 0x3F);
        *unpacked++ = ((token2 >> 4) & 0x3F);
        *unpacked++ = (((token2 & 0xF) << 2) | (token3 >> 30));
        *unpacked++ = ((token3 >> 24) & 0x3F);
        *unpacked++ = ((token3 >> 18) & 0x3F);
        *unpacked++ = ((token3 >> 12) & 0x3F);
        *unpacked++ = ((token3 >> 6) & 0x3F);
        *unpacked++ = (token3 & 0x3F);
        token = token1;
        n -= 16;
      }
    }
    if (nbits == 4) {
      while (n > 7) {
        *unpacked++ = ((token >> 28));
        *unpacked++ = ((token >> 24) & 0xF);
        *unpacked++ = ((token >> 20) & 0xF);
        *unpacked++ = ((token >> 16) & 0xF);
        *unpacked++ = ((token >> 12) & 0xF);
        *unpacked++ = ((token >> 8) & 0xF);
        *unpacked++ = ((token >> 4) & 0xF);
        *unpacked++ = (token & 0xF);
        token = *packed++;
        n -= 8;
      }
    }
    if (nbits == 2) {
      while (n > 15) {
        *unpacked++ = ((token >> 30));
        *unpacked++ = ((token >> 28) & 0x3);
        *unpacked++ = ((token >> 26) & 0x3);
        *unpacked++ = ((token >> 24) & 0x3);
        *unpacked++ = ((token >> 22) & 0x3);
        *unpacked++ = ((token >> 20) & 0x3);
        *unpacked++ = ((token >> 18) & 0x3);
        *unpacked++ = ((token >> 16) & 0x3);
        *unpacked++ = ((token >> 14) & 0x3);
        *unpacked++ = ((token >> 12) & 0x3);
        *unpacked++ = ((token >> 10) & 0x3);
        *unpacked++ = ((token >> 8) & 0x3);
        *unpacked++ = ((token >> 6) & 0x3);
        *unpacked++ = ((token >> 4) & 0x3);
        *unpacked++ = ((token >> 2) & 0x3);
        *unpacked++ = (token & 0x3);
        token = *packed++;
        n -= 16;
      }
    }
    if (nbits == 1) {
      while (n > 31) {
        *unpacked++ = ((token >> 31) & 1);
        *unpacked++ = ((token >> 30) & 1);
        *unpacked++ = ((token >> 29) & 1);
        *unpacked++ = ((token >> 28) & 1);
        *unpacked++ = ((token >> 27) & 1);
        *unpacked++ = ((token >> 26) & 1);
        *unpacked++ = ((token >> 25) & 1);
        *unpacked++ = ((token >> 24) & 1);
        *unpacked++ = ((token >> 23) & 1);
        *unpacked++ = ((token >> 22) & 1);
        *unpacked++ = ((token >> 21) & 1);
        *unpacked++ = ((token >> 20) & 1);
        *unpacked++ = ((token >> 19) & 1);
        *unpacked++ = ((token >> 18) & 1);
        *unpacked++ = ((token >> 17) & 1);
        *unpacked++ = ((token >> 16) & 1);
        *unpacked++ = ((token >> 15) & 1);
        *unpacked++ = ((token >> 14) & 1);
        *unpacked++ = ((token >> 13) & 1);
        *unpacked++ = ((token >> 12) & 1);
        *unpacked++ = ((token >> 11) & 1);
        *unpacked++ = ((token >> 10) & 1);
        *unpacked++ = ((token >> 9) & 1);
        *unpacked++ = ((token >> 8) & 1);
        *unpacked++ = ((token >> 7) & 1);
        *unpacked++ = ((token >> 6) & 1);
        *unpacked++ = ((token >> 5) & 1);
        *unpacked++ = ((token >> 4) & 1);
        *unpacked++ = ((token >> 3) & 1);
        *unpacked++ = ((token >> 2) & 1);
        *unpacked++ = ((token >> 1) & 1);
        *unpacked++ = (token & 1);
        token = *packed++;
        n -= 32;
      }
    }
  }
  temp = token;
  temp <<= 32;
  temp |= *packed++;
  if (bleft < 32)
    temp <<= (32 - bleft);
  while (n > 3) {
    *unpacked++ = (temp >> (64 - nbits));
    temp <<= nbits;
    bleft -= nbits;
    *unpacked++ = (temp >> (64 - nbits));
    temp <<= nbits;
    bleft -= nbits;
    *unpacked++ = (temp >> (64 - nbits));
    temp <<= nbits;
    bleft -= nbits;
    *unpacked++ = (temp >> (64 - nbits));
    temp <<= nbits;
    bleft -= nbits;
    if (bleft <= 0) {
      token = *packed++;
      if (bleft == 0) {
        temp |= token;
      } else {
        temp = temp >> (-bleft);
        temp |= token;
        temp <<= (-bleft);
      }
      bleft += 32;
    }
    n -= 4;
  }
  while (n-- > 0) {
    *unpacked++ = (temp >> (64 - nbits));
    temp <<= nbits;
    bleft -= nbits;
    if (bleft <= 0) {
      token = *packed++;
      if (bleft == 0) {
        temp |= token;
      } else {
        temp = temp >> (-bleft);
        temp |= token;
        temp <<= (-bleft);
      }
      bleft += 32;
    }
  }
}
```