#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */
struct katcp_dispatch {
  int dummy;
};
struct katcp_acquire {
  int dummy;
};

/* Variables and functions */
int declare_multi_integer_sensor_katcp(
    struct katcp_dispatch *, int, char *, char *, char *, int, int, int, int,
    struct katcp_acquire *,
    int (*)(struct katcp_dispatch *, struct katcp_sensor *),
    int (*)(struct katcp_dispatch *, struct katcp_sensor *));
int register_multi_integer_sensor_katcp(
    struct katcp_dispatch *d, int mode, char *name, char *description,
    char *units, int min, int max, struct katcp_acquire *a,
    int (*extract)(struct katcp_dispatch *d, struct katcp_sensor *sn),
    int (*flush)(struct katcp_dispatch *d, struct katcp_sensor *sn)) {
  return declare_multi_integer_sensor_katcp(
      d, mode, name, description, units, min, max, min, max, a, extract, flush);
}


x86 assembly (clang, -O0):
<register_multi_integer_sensor_katcp>:
push   %rbp
mov    %rsp,%rbp
push   %r15
push   %r14
push   %rbx
sub    $0x68,%rsp
mov    0x28(%rbp),%rax
mov    0x20(%rbp),%rax
mov    0x18(%rbp),%rax
mov    0x10(%rbp),%eax
mov    %rdi,-0x20(%rbp)
mov    %esi,-0x24(%rbp)
mov    %rdx,-0x30(%rbp)
mov    %rcx,-0x38(%rbp)
mov    %r8,-0x40(%rbp)
mov    %r9d,-0x44(%rbp)
mov    -0x20(%rbp),%rdi
mov    -0x24(%rbp),%esi
mov    -0x30(%rbp),%rdx
mov    -0x38(%rbp),%rcx
mov    -0x40(%rbp),%r8
mov    -0x44(%rbp),%r9d
mov    0x10(%rbp),%r15d
mov    -0x44(%rbp),%r14d
mov    0x10(%rbp),%ebx
mov    0x18(%rbp),%r11
mov    0x20(%rbp),%r10
mov    0x28(%rbp),%rax
mov    %r15d,(%rsp)
mov    %r14d,0x8(%rsp)
mov    %ebx,0x10(%rsp)
mov    %r11,0x18(%rsp)
mov    %r10,0x20(%rsp)
mov    %rax,0x28(%rsp)
call   1030 <declare_multi_integer_sensor_katcp@plt>
add    $0x68,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret

x86 assembly (clang, -O2):
<register_multi_integer_sensor_katcp>:
sub    $0x38,%rsp
mov    0x40(%rsp),%eax
movups 0x48(%rsp),%xmm0
mov    0x58(%rsp),%r10
mov    %r10,0x28(%rsp)
movups %xmm0,0x18(%rsp)
mov    %eax,0x10(%rsp)
mov    %r9d,0x8(%rsp)
mov    %eax,(%rsp)
call   1030 <declare_multi_integer_sensor_katcp@plt>
add    $0x38,%rsp
ret

LLVM IR (-O0):
%struct.katcp_dispatch = type { i32 }
%struct.katcp_acquire = type { i32 }
%struct.katcp_sensor = type opaque
%struct.katcp_sensor.0 = type opaque
%struct.katcp_sensor.1 = type opaque
%struct.katcp_sensor.2 = type opaque
define i32 @register_multi_integer_sensor_katcp(%struct.katcp_dispatch* %0, i32 %1, i8* %2, i8* %3, i8* %4, i32 %5, i32 %6, %struct.katcp_acquire* %7, i32 (%struct.katcp_dispatch*, %struct.katcp_sensor*)* %8, i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.0*)* %9) {
%11 = alloca %struct.katcp_dispatch*
%12 = alloca i32
%13 = alloca i8*
%14 = alloca i8*
%15 = alloca i8*
%16 = alloca i32
%17 = alloca i32
%18 = alloca %struct.katcp_acquire*
%19 = alloca i32 (%struct.katcp_dispatch*, %struct.katcp_sensor*)*
%20 = alloca i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.0*)*
store %struct.katcp_dispatch* %0, %struct.katcp_dispatch** %11
store i32 %1, i32* %12
store i8* %2, i8** %13
store i8* %3, i8** %14
store i8* %4, i8** %15
store i32 %5, i32* %16
store i32 %6, i32* %17
store %struct.katcp_acquire* %7, %struct.katcp_acquire** %18
store i32 (%struct.katcp_dispatch*, %struct.katcp_sensor*)* %8, i32 (%struct.katcp_dispatch*, %struct.katcp_sensor*)** %19
store i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.0*)* %9, i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.0*)** %20
%21 = load %struct.katcp_dispatch*, %struct.katcp_dispatch** %11
%22 = load i32, i32* %12
%23 = load i8*, i8** %13
%24 = load i8*, i8** %14
%25 = load i8*, i8** %15
%26 = load i32, i32* %16
%27 = load i32, i32* %17
%28 = load i32, i32* %16
%29 = load i32, i32* %17
%30 = load %struct.katcp_acquire*, %struct.katcp_acquire** %18
%31 = load i32 (%struct.katcp_dispatch*, %struct.katcp_sensor*)*, i32 (%struct.katcp_dispatch*, %struct.katcp_sensor*)** %19
%32 = bitcast i32 (%struct.katcp_dispatch*, %struct.katcp_sensor*)* %31 to i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.1*)*
%33 = load i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.0*)*, i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.0*)** %20
%34 = bitcast i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.0*)* %33 to i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.2*)*
%35 = call i32 @declare_multi_integer_sensor_katcp(%struct.katcp_dispatch* %21, i32 %22, i8* %23, i8* %24, i8* %25, i32 %26, i32 %27, i32 %28, i32 %29, %struct.katcp_acquire* %30, i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.1*)* %32, i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.2*)* %34)
ret i32 %35
}

LLVM IR (-O2):
%struct.katcp_dispatch = type { i32 }
%struct.katcp_acquire = type { i32 }
%struct.katcp_sensor = type opaque
%struct.katcp_sensor.0 = type opaque
%struct.katcp_sensor.1 = type opaque
%struct.katcp_sensor.2 = type opaque
define i32 @register_multi_integer_sensor_katcp(%struct.katcp_dispatch* %0, i32 %1, i8* %2, i8* %3, i8* %4, i32 %5, i32 %6, %struct.katcp_acquire* %7, i32 (%struct.katcp_dispatch*, %struct.katcp_sensor*)* %8, i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.0*)* %9) {
%11 = bitcast i32 (%struct.katcp_dispatch*, %struct.katcp_sensor*)* %8 to i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.1*)*
%12 = bitcast i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.0*)* %9 to i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.2*)*
%13 = tail call i32 @declare_multi_integer_sensor_katcp(%struct.katcp_dispatch* %0, i32 %1, i8* %2, i8* %3, i8* %4, i32 %5, i32 %6, i32 %5, i32 %6, %struct.katcp_acquire* %7, i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.1*)* %11, i32 (%struct.katcp_dispatch*, %struct.katcp_sensor.2*)* %12)
ret i32 %13
}