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
  mov    %rdi,%rbp
  push   %rbx
  sub    $0x8,%rsp
  mov    (%rdi),%edi
  call   <IIO_EVENT_CODE_EXTRACT_CHAN_TYPE@plt>
  mov    0x0(%rbp),%edi
  mov    %eax,%ebx
  call   <IIO_EVENT_CODE_EXTRACT_MODIFIER@plt>
  mov    0x0(%rbp),%edi
  mov    %eax,%r12d
  call   <IIO_EVENT_CODE_EXTRACT_TYPE@plt>
  mov    0x0(%rbp),%edi
  mov    %eax,%r13d
  call   <IIO_EVENT_CODE_EXTRACT_DIR@plt>
  mov    %eax,%edx
  cmp    $0xb6,%ebx
  jg     L26
  cmp    $0xb0,%ebx
  jg     L27
  add    $0xffffff80,%ebx
  xor    %eax,%eax
  cmp    $0xb,%ebx
  jbe    L27
L51:
  add    $0x8,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  ret
  nop
L26:
  sub    $0xc1,%ebx
  xor    %eax,%eax
  cmp    $0xa,%ebx
  ja     L51
L27:
  sub    $0x8c,%r12d
  xor    %eax,%eax
  cmp    $0x24,%r12d
  ja     L51
  sub    $0xb7,%r13d
  cmp    $0x5,%r13d
  ja     L51
  lea    -0xbd(%rdx),%eax
  cmp    $0x3,%eax
  setbe  %al
  add    $0x8,%rsp
  pop    %rbx
  movzbl %al,%eax
  pop    %rbp
  pop    %r12
  pop    %r13
  ret
```

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;
}
```