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

```asm
<event_is_known>:
  endbr64
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x8,%rsp
  mov    %rdi,%rbp
  mov    (%rdi),%edi
  call   <IIO_EVENT_CODE_EXTRACT_CHAN_TYPE@plt>
  mov    %eax,%ebx
  mov    0x0(%rbp),%edi
  call   <IIO_EVENT_CODE_EXTRACT_MODIFIER@plt>
  mov    %eax,%r12d
  mov    0x0(%rbp),%edi
  call   <IIO_EVENT_CODE_EXTRACT_TYPE@plt>
  mov    %eax,%r13d
  mov    0x0(%rbp),%edi
  call   <IIO_EVENT_CODE_EXTRACT_DIR@plt>
  mov    %eax,%edx
  cmp    $0xb6,%ebx
  jg     L9
  cmp    $0xb0,%ebx
  jg     L52
  add    $0xffffff80,%ebx
  mov    $0x0,%eax
  cmp    $0xb,%ebx
  jbe    L52
L25:
  add    $0x8,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  ret
L9:
  sub    $0xc1,%ebx
  mov    $0x0,%eax
  cmp    $0xa,%ebx
  ja     L25
L52:
  sub    $0x8c,%r12d
  mov    $0x0,%eax
  cmp    $0x24,%r12d
  ja     L25
  sub    $0xb7,%r13d
  cmp    $0x5,%r13d
  ja     L25
  lea    -0xbd(%rdx),%eax
  cmp    $0x3,%eax
  setbe  %al
  movzbl %al,%eax
  jmp    L25
```

assistant: ```c
bool event_is_known(struct iio_event_data *event) {
  enum iio_chan_type type = IIO_EVENT_CODE_EXTRACT_CHAN_TYPE(event->id);
  enum iio_modifier mod = IIO_EVENT_CODE_EXTRACT_MODIFIER(event->id);
  enum iio_event_type ev_type = IIO_EVENT_CODE_EXTRACT_TYPE(event->id);
  enum iio_event_direction dir = IIO_EVENT_CODE_EXTRACT_DIR(event->id);
  switch (type) {
  case IIO_VOLTAGE:
  case IIO_CURRENT:
  case IIO_POWER:
  case IIO_ACCEL:
  case IIO_ANGL_VEL:
  case IIO_MAGN:
  case IIO_LIGHT:
  case IIO_INTENSITY:
  case IIO_PROXIMITY:
  case IIO_TEMP:
  case IIO_INCLI:
  case IIO_ROT:
  case IIO_ANGL:
  case IIO_TIMESTAMP:
  case IIO_CAPACITANCE:
  case IIO_ALTVOLTAGE:
  case IIO_CCT:
  case IIO_PRESSURE:
  case IIO_HUMIDITYRELATIVE:
  case IIO_ACTIVITY:
  case IIO_STEPS:
  case IIO_ENERGY:
  case IIO_DISTANCE:
  case IIO_VELOCITY:
  case IIO_CONCENTRATION:
  case IIO_RESISTANCE:
  case IIO_PH:
  case IIO_UVINDEX:
  case IIO_GRAVITY:
    break;
  default:
    return false;
  }
  switch (mod) {
  case IIO_NO_MOD:
  case IIO_MOD_X:
  case IIO_MOD_Y:
  case IIO_MOD_Z:
  case IIO_MOD_X_AND_Y:
  case IIO_MOD_X_AND_Z:
  case IIO_MOD_Y_AND_Z:
  case IIO_MOD_X_AND_Y_AND_Z:
  case IIO_MOD_X_OR_Y:
  case IIO_MOD_X_OR_Z:
  case IIO_MOD_Y_OR_Z:
  case IIO_MOD_X_OR_Y_OR_Z:
  case IIO_MOD_LIGHT_BOTH:
  case IIO_MOD_LIGHT_IR:
  case IIO_MOD_ROOT_SUM_SQUARED_X_Y:
  case IIO_MOD_SUM_SQUARED_X_Y_Z:
  case IIO_MOD_LIGHT_CLEAR:
  case IIO_MOD_LIGHT_RED:
  case IIO_MOD_LIGHT_GREEN:
  case IIO_MOD_LIGHT_BLUE:
  case IIO_MOD_LIGHT_UV:
  case IIO_MOD_QUATERNION:
  case IIO_MOD_TEMP_AMBIENT:
  case IIO_MOD_TEMP_OBJECT:
  case IIO_MOD_NORTH_MAGN:
  case IIO_MOD_NORTH_TRUE:
  case IIO_MOD_NORTH_MAGN_TILT_COMP:
  case IIO_MOD_NORTH_TRUE_TILT_COMP:
  case IIO_MOD_RUNNING:
  case IIO_MOD_JOGGING:
  case IIO_MOD_WALKING:
  case IIO_MOD_STILL:
  case IIO_MOD_ROOT_SUM_SQUARED_X_Y_Z:
  case IIO_MOD_I:
  case IIO_MOD_Q:
  case IIO_MOD_CO2:
  case IIO_MOD_VOC:
    break;
  default:
    return false;
  }
  switch (ev_type) {
  case IIO_EV_TYPE_THRESH:
  case IIO_EV_TYPE_MAG:
  case IIO_EV_TYPE_ROC:
  case IIO_EV_TYPE_THRESH_ADAPTIVE:
  case IIO_EV_TYPE_MAG_ADAPTIVE:
  case IIO_EV_TYPE_CHANGE:
    break;
  default:
    return false;
  }
  switch (dir) {
  case IIO_EV_DIR_EITHER:
  case IIO_EV_DIR_RISING:
  case IIO_EV_DIR_FALLING:
  case IIO_EV_DIR_NONE:
    break;
  default:
    return false;
  }
  return true;
}
```