user: 请从给定的汇编指令推导出C源代码：

```asm
<vertical_flash_test>:
  endbr64
  push   %rbx
  sub    $0x10,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x8(%rsp)
  xor    %eax,%eax
  mov    %rsp,%rdi
  call   <FS460_get_tv_active_lines@plt>
  xor    %eax,%eax
  call   <FS460_play_begin@plt>
  test   %eax,%eax
  je     L48
L24:
  xor    %eax,%eax
  call   <FS460_play_begin@plt>
  mov    D7(%rip),%eax
  lea    0x1(%rax),%edx
  mov    %edx,D5(%rip)
  cmp    $0x6,%eax
  ja     L9
  lea    D5(%rip),%rdx
  movslq (%rdx,%rax,4),%rax
  add    %rdx,%rax
  notrack jmp *%rax
L9:
  movl   $0x1,D5(%rip)
  xor    %esi,%esi
  mov    $0x1,%edi
  call   <vertical_flash@plt>
L31:
  mov    $0x1,%edi
  call   <FS460_play_run@plt>
  mov    0x8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L42
  add    $0x10,%rsp
  pop    %rbx
  ret
  nopw   0x0(%rax,%rax,1)
L48:
  mov    (%rsp),%ecx
  xor    %r8d,%r8d
  xor    %esi,%esi
  xor    %edi,%edi
  mov    $0x1,%r9d
  mov    $0x2d0,%edx
  call   <set@plt>
  mov    (%rsp),%ecx
  xor    %r8d,%r8d
  xor    %esi,%esi
  xor    %edi,%edi
  mov    $0x1,%r9d
  mov    $0x2d0,%edx
  call   <set@plt>
  mov    (%rsp),%ecx
  xor    %r8d,%r8d
  xor    %esi,%esi
  xor    %edi,%edi
  mov    $0x1,%r9d
  mov    $0x2d0,%edx
  call   <set@plt>
  mov    (%rsp),%ecx
  xor    %edi,%edi
  xor    %r8d,%r8d
  xor    %esi,%esi
  mov    $0x1,%r9d
  mov    $0x2d0,%edx
  call   <set@plt>
  xor    %edi,%edi
  call   <FS460_play_run@plt>
  test   %eax,%eax
  jne    L24
  movl   $0x0,0x4(%rsp)
  lea    0x4(%rsp),%rbx
  nopl   0x0(%rax)
L3:
  mov    %rbx,%rdi
  call   <FS460_play_is_effect_finished@plt>
  or     0x4(%rsp),%eax
  je     L3
  jmp    L24
  nopl   0x0(%rax,%rax,1)
  xor    %esi,%esi
  mov    $0x2,%edi
  call   <vertical_flash@plt>
  jmp    L31
  nopl   0x0(%rax)
  xor    %esi,%esi
  mov    $0x4,%edi
  call   <vertical_flash@plt>
  jmp    L31
  nopl   0x0(%rax)
  xor    %esi,%esi
  mov    $0x6,%edi
  call   <vertical_flash@plt>
  jmp    L31
  nopl   0x0(%rax)
  xor    %esi,%esi
  mov    $0x8,%edi
  call   <vertical_flash@plt>
  jmp    L31
  nopl   0x0(%rax)
  xor    %esi,%esi
  mov    $0xa,%edi
  call   <vertical_flash@plt>
  jmp    L31
  nopl   0x0(%rax)
  mov    $0x1,%esi
  mov    $0x6,%edi
  call   <vertical_flash@plt>
  jmp    L31
L42:
  call   <__stack_chk_fail@plt>
```

assistant: ```c
void vertical_flash_test(void) {
  static int mode = 0;
  int full_height;
  unsigned int completed;
  int err;
  FS460_get_tv_active_lines(&full_height);
  err = FS460_play_begin();
  if (!err) {
    set(0, 0, 720, full_height, 0, 0x0001);
    set(0, 0, 720, full_height, 0, 0x0001);
    set(0, 0, 720, full_height, 0, 0x0001);
    set(0, 0, 720, full_height, 0, 0x0001);
    err = FS460_play_run(0);
    if (!err) {
      completed = 0;
      while (!err && !completed)
        err = FS460_play_is_effect_finished(&completed);
    }
  }
  FS460_play_begin();
  switch (mode++) {
  default:
    mode = 1;
  case 0:
    vertical_flash(1, 0);
    break;
  case 1:
    vertical_flash(2, 0);
    break;
  case 2:
    vertical_flash(4, 0);
    break;
  case 3:
    vertical_flash(6, 0);
    break;
  case 4:
    vertical_flash(8, 0);
    break;
  case 5:
    vertical_flash(10, 0);
    break;
  case 6:
    vertical_flash(6, 1);
    break;
  }
  FS460_play_run(0x0001);
}
```