#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 target {
  int dummy;
};

/* Variables and functions */
char *copy_params(char **, int, int *);
scalar_t__ dump_long_long_unsigned_int_from_mem(unsigned int, char **,
                                                struct target *);
scalar_t__ dump_n_bytes_from_mem(unsigned int, char **, struct target *, int);
scalar_t__ dump_unsigned_int_from_mem(unsigned int, char **, struct target *);
int /*<<< orphan*/ free_dumped_params(char **, int);
void *malloc(int);
int dump_perf_event_attr(int depth, unsigned int addr, char **dumped_params,
                         struct target *target) {
  char **dumped_type_params;
  unsigned int arm_tracing_type = addr;
  unsigned int arm_tracing_size = addr + 4;
  unsigned int arm_tracing_config = addr + 8;
  unsigned int arm_tracing_22 = addr + 16;
  unsigned int arm_tracing_sample_type = addr + 24;
  unsigned int arm_tracing_read_format = addr + 32;
  unsigned int arm_tracing_disabled = addr + 40;
  unsigned int arm_tracing_inherit = addr + 40;
  unsigned int arm_tracing_pinned = addr + 40;
  unsigned int arm_tracing_exclusive = addr + 40;
  unsigned int arm_tracing_exclude_user = addr + 40;
  unsigned int arm_tracing_exclude_kernel = addr + 40;
  unsigned int arm_tracing_exclude_hv = addr + 40;
  unsigned int arm_tracing_exclude_idle = addr + 40;
  unsigned int arm_tracing_mmap = addr + 40;
  unsigned int arm_tracing_comm = addr + 40;
  unsigned int arm_tracing_freq = addr + 40;
  unsigned int arm_tracing_inherit_stat = addr + 40;
  unsigned int arm_tracing_enable_on_exec = addr + 40;
  unsigned int arm_tracing_task = addr + 40;
  unsigned int arm_tracing_watermark = addr + 40;
  unsigned int arm_tracing_precise_ip = addr + 40;
  unsigned int arm_tracing_mmap_data = addr + 40;
  unsigned int arm_tracing_sample_id_all = addr + 40;
  unsigned int arm_tracing_exclude_host = addr + 40;
  unsigned int arm_tracing_exclude_guest = addr + 40;
  unsigned int arm_tracing___reserved_1 = addr + 40;
  unsigned int arm_tracing_23 = addr + 48;
  unsigned int arm_tracing_bp_type = addr + 52;
  unsigned int arm_tracing_24 = addr + 56;
  unsigned int arm_tracing_25 = addr + 64;
  int len = 0;
  if (depth < 0) {
    *dumped_params = malloc(0);
    return len;
  }
  dumped_type_params = malloc(31 * (sizeof(char *)));
  if (depth >= 0) {
    len += dump_unsigned_int_from_mem(arm_tracing_type, &dumped_type_params[0],
                                      target);
    len += dump_unsigned_int_from_mem(arm_tracing_size, &dumped_type_params[1],
                                      target);
    len += dump_long_long_unsigned_int_from_mem(arm_tracing_config,
                                                &dumped_type_params[2], target);
    len += dump_n_bytes_from_mem(arm_tracing_22, &dumped_type_params[3], target,
                                 8);
    len += dump_long_long_unsigned_int_from_mem(arm_tracing_sample_type,
                                                &dumped_type_params[4], target);
    len += dump_long_long_unsigned_int_from_mem(arm_tracing_read_format,
                                                &dumped_type_params[5], target);
    len += dump_long_long_unsigned_int_from_mem(arm_tracing_disabled,
                                                &dumped_type_params[6], target);
    len += dump_long_long_unsigned_int_from_mem(arm_tracing_inherit,
                                                &dumped_type_params[7], target);
    len += dump_long_long_unsigned_int_from_mem(arm_tracing_pinned,
                                                &dumped_type_params[8], target);
    len += dump_long_long_unsigned_int_from_mem(arm_tracing_exclusive,
                                                &dumped_type_params[9], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_exclude_user, &dumped_type_params[10], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_exclude_kernel, &dumped_type_params[11], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_exclude_hv, &dumped_type_params[12], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_exclude_idle, &dumped_type_params[13], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_mmap, &dumped_type_params[14], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_comm, &dumped_type_params[15], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_freq, &dumped_type_params[16], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_inherit_stat, &dumped_type_params[17], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_enable_on_exec, &dumped_type_params[18], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_task, &dumped_type_params[19], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_watermark, &dumped_type_params[20], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_precise_ip, &dumped_type_params[21], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_mmap_data, &dumped_type_params[22], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_sample_id_all, &dumped_type_params[23], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_exclude_host, &dumped_type_params[24], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing_exclude_guest, &dumped_type_params[25], target);
    len += dump_long_long_unsigned_int_from_mem(
        arm_tracing___reserved_1, &dumped_type_params[26], target);
    len += dump_n_bytes_from_mem(arm_tracing_23, &dumped_type_params[27],
                                 target, 4);
    len += dump_unsigned_int_from_mem(arm_tracing_bp_type,
                                      &dumped_type_params[28], target);
    len += dump_n_bytes_from_mem(arm_tracing_24, &dumped_type_params[29],
                                 target, 8);
    len += dump_n_bytes_from_mem(arm_tracing_25, &dumped_type_params[30],
                                 target, 8);
  }
  *dumped_params = copy_params(dumped_type_params, 31, &len);
  free_dumped_params(dumped_type_params, 31);
  return len;
}


x86 assembly (clang, -O0):
<dump_perf_event_attr>:
push   %rbp
mov    %rsp,%rbp
sub    $0xb0,%rsp
mov    %edi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x2c(%rbp)
mov    -0xc(%rbp),%eax
add    $0x4,%eax
mov    %eax,-0x30(%rbp)
mov    -0xc(%rbp),%eax
add    $0x8,%eax
mov    %eax,-0x34(%rbp)
mov    -0xc(%rbp),%eax
add    $0x10,%eax
mov    %eax,-0x38(%rbp)
mov    -0xc(%rbp),%eax
add    $0x18,%eax
mov    %eax,-0x3c(%rbp)
mov    -0xc(%rbp),%eax
add    $0x20,%eax
mov    %eax,-0x40(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x44(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x48(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x4c(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x50(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x54(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x58(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x5c(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x60(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x64(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x68(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x6c(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x70(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x74(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x78(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x7c(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x80(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x84(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x88(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x8c(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x90(%rbp)
mov    -0xc(%rbp),%eax
add    $0x28,%eax
mov    %eax,-0x94(%rbp)
mov    -0xc(%rbp),%eax
add    $0x30,%eax
mov    %eax,-0x98(%rbp)
mov    -0xc(%rbp),%eax
add    $0x34,%eax
mov    %eax,-0x9c(%rbp)
mov    -0xc(%rbp),%eax
add    $0x38,%eax
mov    %eax,-0xa0(%rbp)
mov    -0xc(%rbp),%eax
add    $0x40,%eax
mov    %eax,-0xa4(%rbp)
movl   $0x0,-0xa8(%rbp)
cmpl   $0x0,-0x8(%rbp)
jge    12db <dump_perf_event_attr+0x17b>
xor    %edi,%edi
call   1070 <malloc@plt>
mov    %rax,%rcx
mov    -0x18(%rbp),%rax
mov    %rcx,(%rax)
mov    -0xa8(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    183a <dump_perf_event_attr+0x6da>
mov    $0xf8,%edi
call   1070 <malloc@plt>
mov    %rax,-0x28(%rbp)
cmpl   $0x0,-0x8(%rbp)
jl     1804 <dump_perf_event_attr+0x6a4>
mov    -0x2c(%rbp),%edi
mov    -0x28(%rbp),%rsi
mov    -0x20(%rbp),%rdx
call   1080 <dump_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x30(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x8,%rsi
mov    -0x20(%rbp),%rdx
call   1080 <dump_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x34(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x10,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x38(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x18,%rsi
mov    -0x20(%rbp),%rdx
mov    $0x8,%ecx
call   1030 <dump_n_bytes_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x3c(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x20,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x40(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x28,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x44(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x30,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x48(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x38,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x4c(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x40,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x50(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x48,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x54(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x50,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x58(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x58,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x5c(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x60,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x60(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x68,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x64(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x70,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x68(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x78,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x6c(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x80,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x70(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x88,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x74(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x90,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x78(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0x98,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x7c(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0xa0,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x80(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0xa8,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x84(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0xb0,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x88(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0xb8,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x8c(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0xc0,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x90(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0xc8,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x94(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0xd0,%rsi
mov    -0x20(%rbp),%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x98(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0xd8,%rsi
mov    -0x20(%rbp),%rdx
mov    $0x4,%ecx
call   1030 <dump_n_bytes_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x9c(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0xe0,%rsi
mov    -0x20(%rbp),%rdx
call   1080 <dump_unsigned_int_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0xa0(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0xe8,%rsi
mov    -0x20(%rbp),%rdx
mov    $0x8,%ecx
call   1030 <dump_n_bytes_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0xa4(%rbp),%edi
mov    -0x28(%rbp),%rsi
add    $0xf0,%rsi
mov    -0x20(%rbp),%rdx
mov    $0x8,%ecx
call   1030 <dump_n_bytes_from_mem@plt>
mov    %rax,%rcx
movslq -0xa8(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0xa8(%rbp)
mov    -0x28(%rbp),%rdi
mov    $0x1f,%esi
lea    -0xa8(%rbp),%rdx
call   1060 <copy_params@plt>
mov    %rax,%rcx
mov    -0x18(%rbp),%rax
mov    %rcx,(%rax)
mov    -0x28(%rbp),%rdi
mov    $0x1f,%esi
call   1050 <free_dumped_params@plt>
mov    -0xa8(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0xb0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<dump_perf_event_attr>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x38,%rsp
mov    %rdx,%rbp
test   %edi,%edi
js     14b9 <dump_perf_event_attr+0x359>
mov    %rcx,%r15
mov    %esi,%r13d
lea    0x28(%r13),%r12d
lea    0x40(%r13),%eax
mov    %eax,0x2c(%rsp)
lea    0x38(%r13),%eax
mov    %eax,0x28(%rsp)
lea    0x34(%r13),%eax
mov    %eax,0x24(%rsp)
lea    0x30(%r13),%eax
mov    %eax,0x20(%rsp)
lea    0x20(%r13),%eax
mov    %eax,0x1c(%rsp)
lea    0x18(%r13),%eax
mov    %eax,0x18(%rsp)
lea    0x10(%r13),%eax
mov    %eax,0x14(%rsp)
lea    0x8(%r13),%eax
mov    %eax,0x10(%rsp)
lea    0x4(%r13),%ebx
mov    $0xf8,%edi
call   1070 <malloc@plt>
mov    %rbp,0x30(%rsp)
mov    %rax,%r14
mov    %r13d,%edi
mov    %rax,%rsi
mov    %r15,%rdx
call   1080 <dump_unsigned_int_from_mem@plt>
mov    %rax,%r13
lea    0x8(%r14),%rsi
mov    %ebx,%edi
mov    %r15,%rdx
call   1080 <dump_unsigned_int_from_mem@plt>
mov    %rax,%rbx
add    %r13d,%ebx
lea    0x10(%r14),%rsi
mov    0x10(%rsp),%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbp
add    %ebx,%ebp
lea    0x18(%r14),%rsi
mov    0x14(%rsp),%edi
mov    %r15,%rdx
mov    $0x8,%ecx
call   1030 <dump_n_bytes_from_mem@plt>
mov    %rax,%rbx
add    %ebp,%ebx
lea    0x20(%r14),%rsi
mov    0x18(%rsp),%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbp
add    %ebx,%ebp
lea    0x28(%r14),%rsi
mov    0x1c(%rsp),%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbx
add    %ebp,%ebx
lea    0x30(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbp
add    %ebx,%ebp
lea    0x38(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbx
add    %ebp,%ebx
lea    0x40(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbp
add    %ebx,%ebp
lea    0x48(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbx
add    %ebp,%ebx
lea    0x50(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbp
add    %ebx,%ebp
lea    0x58(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbx
add    %ebp,%ebx
lea    0x60(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbp
add    %ebx,%ebp
lea    0x68(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbx
add    %ebp,%ebx
lea    0x70(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbp
add    %ebx,%ebp
lea    0x78(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbx
add    %ebp,%ebx
lea    0x80(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbp
add    %ebx,%ebp
lea    0x88(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbx
add    %ebp,%ebx
lea    0x90(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbp
add    %ebx,%ebp
lea    0x98(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbx
add    %ebp,%ebx
lea    0xa0(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbp
add    %ebx,%ebp
lea    0xa8(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbx
add    %ebp,%ebx
lea    0xb0(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbp
add    %ebx,%ebp
lea    0xb8(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbx
add    %ebp,%ebx
lea    0xc0(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbp
add    %ebx,%ebp
lea    0xc8(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbx
add    %ebp,%ebx
lea    0xd0(%r14),%rsi
mov    %r12d,%edi
mov    %r15,%rdx
call   1040 <dump_long_long_unsigned_int_from_mem@plt>
mov    %rax,%rbp
add    %ebx,%ebp
lea    0xd8(%r14),%rsi
mov    0x20(%rsp),%edi
mov    %r15,%rdx
mov    $0x4,%ecx
call   1030 <dump_n_bytes_from_mem@plt>
mov    %rax,%rbx
add    %ebp,%ebx
lea    0xe0(%r14),%rsi
mov    0x24(%rsp),%edi
mov    %r15,%rdx
call   1080 <dump_unsigned_int_from_mem@plt>
mov    %rax,%rbp
add    %ebx,%ebp
lea    0xe8(%r14),%rsi
mov    0x28(%rsp),%edi
mov    %r15,%rdx
mov    $0x8,%ecx
call   1030 <dump_n_bytes_from_mem@plt>
mov    %rax,%rbx
add    %ebp,%ebx
lea    0xf0(%r14),%rsi
mov    0x2c(%rsp),%edi
mov    %r15,%rdx
mov    $0x8,%ecx
call   1030 <dump_n_bytes_from_mem@plt>
add    %ebx,%eax
mov    %eax,0xc(%rsp)
lea    0xc(%rsp),%rdx
mov    %r14,%rdi
mov    $0x1f,%esi
call   1060 <copy_params@plt>
mov    0x30(%rsp),%rcx
mov    %rax,(%rcx)
mov    %r14,%rdi
mov    $0x1f,%esi
call   1050 <free_dumped_params@plt>
mov    0xc(%rsp),%ebx
jmp    14c6 <dump_perf_event_attr+0x366>
xor    %ebx,%ebx
xor    %edi,%edi
call   1070 <malloc@plt>
mov    %rax,0x0(%rbp)
mov    %ebx,%eax
add    $0x38,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
%struct.target = type { i32 }
define i32 @dump_perf_event_attr(i32 %0, i32 %1, i8** %2, %struct.target* %3) {
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i8**
%9 = alloca %struct.target*
%10 = alloca i8**
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca i32
%15 = alloca i32
%16 = alloca i32
%17 = alloca i32
%18 = alloca i32
%19 = alloca i32
%20 = alloca i32
%21 = alloca i32
%22 = alloca i32
%23 = alloca i32
%24 = alloca i32
%25 = alloca i32
%26 = alloca i32
%27 = alloca i32
%28 = alloca i32
%29 = alloca i32
%30 = alloca i32
%31 = alloca i32
%32 = alloca i32
%33 = alloca i32
%34 = alloca i32
%35 = alloca i32
%36 = alloca i32
%37 = alloca i32
%38 = alloca i32
%39 = alloca i32
%40 = alloca i32
%41 = alloca i32
%42 = alloca i32
store i32 %0, i32* %6
store i32 %1, i32* %7
store i8** %2, i8*** %8
store %struct.target* %3, %struct.target** %9
%43 = load i32, i32* %7
store i32 %43, i32* %11
%44 = load i32, i32* %7
%45 = add i32 %44, 4
store i32 %45, i32* %12
%46 = load i32, i32* %7
%47 = add i32 %46, 8
store i32 %47, i32* %13
%48 = load i32, i32* %7
%49 = add i32 %48, 16
store i32 %49, i32* %14
%50 = load i32, i32* %7
%51 = add i32 %50, 24
store i32 %51, i32* %15
%52 = load i32, i32* %7
%53 = add i32 %52, 32
store i32 %53, i32* %16
%54 = load i32, i32* %7
%55 = add i32 %54, 40
store i32 %55, i32* %17
%56 = load i32, i32* %7
%57 = add i32 %56, 40
store i32 %57, i32* %18
%58 = load i32, i32* %7
%59 = add i32 %58, 40
store i32 %59, i32* %19
%60 = load i32, i32* %7
%61 = add i32 %60, 40
store i32 %61, i32* %20
%62 = load i32, i32* %7
%63 = add i32 %62, 40
store i32 %63, i32* %21
%64 = load i32, i32* %7
%65 = add i32 %64, 40
store i32 %65, i32* %22
%66 = load i32, i32* %7
%67 = add i32 %66, 40
store i32 %67, i32* %23
%68 = load i32, i32* %7
%69 = add i32 %68, 40
store i32 %69, i32* %24
%70 = load i32, i32* %7
%71 = add i32 %70, 40
store i32 %71, i32* %25
%72 = load i32, i32* %7
%73 = add i32 %72, 40
store i32 %73, i32* %26
%74 = load i32, i32* %7
%75 = add i32 %74, 40
store i32 %75, i32* %27
%76 = load i32, i32* %7
%77 = add i32 %76, 40
store i32 %77, i32* %28
%78 = load i32, i32* %7
%79 = add i32 %78, 40
store i32 %79, i32* %29
%80 = load i32, i32* %7
%81 = add i32 %80, 40
store i32 %81, i32* %30
%82 = load i32, i32* %7
%83 = add i32 %82, 40
store i32 %83, i32* %31
%84 = load i32, i32* %7
%85 = add i32 %84, 40
store i32 %85, i32* %32
%86 = load i32, i32* %7
%87 = add i32 %86, 40
store i32 %87, i32* %33
%88 = load i32, i32* %7
%89 = add i32 %88, 40
store i32 %89, i32* %34
%90 = load i32, i32* %7
%91 = add i32 %90, 40
store i32 %91, i32* %35
%92 = load i32, i32* %7
%93 = add i32 %92, 40
store i32 %93, i32* %36
%94 = load i32, i32* %7
%95 = add i32 %94, 40
store i32 %95, i32* %37
%96 = load i32, i32* %7
%97 = add i32 %96, 48
store i32 %97, i32* %38
%98 = load i32, i32* %7
%99 = add i32 %98, 52
store i32 %99, i32* %39
%100 = load i32, i32* %7
%101 = add i32 %100, 56
store i32 %101, i32* %40
%102 = load i32, i32* %7
%103 = add i32 %102, 64
store i32 %103, i32* %41
store i32 0, i32* %42
%104 = load i32, i32* %6
%105 = icmp slt i32 %104, 0
br i1 %105, label %106, label %110
106: ; preds = %4
%107 = call i8* @malloc(i32 0)
%108 = load i8**, i8*** %8
store i8* %107, i8** %108
%109 = load i32, i32* %42
store i32 %109, i32* %5
br label %402
110: ; preds = %4
%111 = call i8* @malloc(i32 248)
%112 = bitcast i8* %111 to i8**
store i8** %112, i8*** %10
%113 = load i32, i32* %6
%114 = icmp sge i32 %113, 0
br i1 %114, label %115, label %395
115: ; preds = %110
%116 = load i32, i32* %11
%117 = load i8**, i8*** %10
%118 = getelementptr inbounds i8*, i8** %117, i64 0
%119 = load %struct.target*, %struct.target** %9
%120 = call i64 @dump_unsigned_int_from_mem(i32 %116, i8** %118, %struct.target* %119)
%121 = load i32, i32* %42
%122 = sext i32 %121 to i64
%123 = add nsw i64 %122, %120
%124 = trunc i64 %123 to i32
store i32 %124, i32* %42
%125 = load i32, i32* %12
%126 = load i8**, i8*** %10
%127 = getelementptr inbounds i8*, i8** %126, i64 1
%128 = load %struct.target*, %struct.target** %9
%129 = call i64 @dump_unsigned_int_from_mem(i32 %125, i8** %127, %struct.target* %128)
%130 = load i32, i32* %42
%131 = sext i32 %130 to i64
%132 = add nsw i64 %131, %129
%133 = trunc i64 %132 to i32
store i32 %133, i32* %42
%134 = load i32, i32* %13
%135 = load i8**, i8*** %10
%136 = getelementptr inbounds i8*, i8** %135, i64 2
%137 = load %struct.target*, %struct.target** %9
%138 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %134, i8** %136, %struct.target* %137)
%139 = load i32, i32* %42
%140 = sext i32 %139 to i64
%141 = add nsw i64 %140, %138
%142 = trunc i64 %141 to i32
store i32 %142, i32* %42
%143 = load i32, i32* %14
%144 = load i8**, i8*** %10
%145 = getelementptr inbounds i8*, i8** %144, i64 3
%146 = load %struct.target*, %struct.target** %9
%147 = call i64 @dump_n_bytes_from_mem(i32 %143, i8** %145, %struct.target* %146, i32 8)
%148 = load i32, i32* %42
%149 = sext i32 %148 to i64
%150 = add nsw i64 %149, %147
%151 = trunc i64 %150 to i32
store i32 %151, i32* %42
%152 = load i32, i32* %15
%153 = load i8**, i8*** %10
%154 = getelementptr inbounds i8*, i8** %153, i64 4
%155 = load %struct.target*, %struct.target** %9
%156 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %152, i8** %154, %struct.target* %155)
%157 = load i32, i32* %42
%158 = sext i32 %157 to i64
%159 = add nsw i64 %158, %156
%160 = trunc i64 %159 to i32
store i32 %160, i32* %42
%161 = load i32, i32* %16
%162 = load i8**, i8*** %10
%163 = getelementptr inbounds i8*, i8** %162, i64 5
%164 = load %struct.target*, %struct.target** %9
%165 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %161, i8** %163, %struct.target* %164)
%166 = load i32, i32* %42
%167 = sext i32 %166 to i64
%168 = add nsw i64 %167, %165
%169 = trunc i64 %168 to i32
store i32 %169, i32* %42
%170 = load i32, i32* %17
%171 = load i8**, i8*** %10
%172 = getelementptr inbounds i8*, i8** %171, i64 6
%173 = load %struct.target*, %struct.target** %9
%174 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %170, i8** %172, %struct.target* %173)
%175 = load i32, i32* %42
%176 = sext i32 %175 to i64
%177 = add nsw i64 %176, %174
%178 = trunc i64 %177 to i32
store i32 %178, i32* %42
%179 = load i32, i32* %18
%180 = load i8**, i8*** %10
%181 = getelementptr inbounds i8*, i8** %180, i64 7
%182 = load %struct.target*, %struct.target** %9
%183 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %179, i8** %181, %struct.target* %182)
%184 = load i32, i32* %42
%185 = sext i32 %184 to i64
%186 = add nsw i64 %185, %183
%187 = trunc i64 %186 to i32
store i32 %187, i32* %42
%188 = load i32, i32* %19
%189 = load i8**, i8*** %10
%190 = getelementptr inbounds i8*, i8** %189, i64 8
%191 = load %struct.target*, %struct.target** %9
%192 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %188, i8** %190, %struct.target* %191)
%193 = load i32, i32* %42
%194 = sext i32 %193 to i64
%195 = add nsw i64 %194, %192
%196 = trunc i64 %195 to i32
store i32 %196, i32* %42
%197 = load i32, i32* %20
%198 = load i8**, i8*** %10
%199 = getelementptr inbounds i8*, i8** %198, i64 9
%200 = load %struct.target*, %struct.target** %9
%201 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %197, i8** %199, %struct.target* %200)
%202 = load i32, i32* %42
%203 = sext i32 %202 to i64
%204 = add nsw i64 %203, %201
%205 = trunc i64 %204 to i32
store i32 %205, i32* %42
%206 = load i32, i32* %21
%207 = load i8**, i8*** %10
%208 = getelementptr inbounds i8*, i8** %207, i64 10
%209 = load %struct.target*, %struct.target** %9
%210 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %206, i8** %208, %struct.target* %209)
%211 = load i32, i32* %42
%212 = sext i32 %211 to i64
%213 = add nsw i64 %212, %210
%214 = trunc i64 %213 to i32
store i32 %214, i32* %42
%215 = load i32, i32* %22
%216 = load i8**, i8*** %10
%217 = getelementptr inbounds i8*, i8** %216, i64 11
%218 = load %struct.target*, %struct.target** %9
%219 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %215, i8** %217, %struct.target* %218)
%220 = load i32, i32* %42
%221 = sext i32 %220 to i64
%222 = add nsw i64 %221, %219
%223 = trunc i64 %222 to i32
store i32 %223, i32* %42
%224 = load i32, i32* %23
%225 = load i8**, i8*** %10
%226 = getelementptr inbounds i8*, i8** %225, i64 12
%227 = load %struct.target*, %struct.target** %9
%228 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %224, i8** %226, %struct.target* %227)
%229 = load i32, i32* %42
%230 = sext i32 %229 to i64
%231 = add nsw i64 %230, %228
%232 = trunc i64 %231 to i32
store i32 %232, i32* %42
%233 = load i32, i32* %24
%234 = load i8**, i8*** %10
%235 = getelementptr inbounds i8*, i8** %234, i64 13
%236 = load %struct.target*, %struct.target** %9
%237 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %233, i8** %235, %struct.target* %236)
%238 = load i32, i32* %42
%239 = sext i32 %238 to i64
%240 = add nsw i64 %239, %237
%241 = trunc i64 %240 to i32
store i32 %241, i32* %42
%242 = load i32, i32* %25
%243 = load i8**, i8*** %10
%244 = getelementptr inbounds i8*, i8** %243, i64 14
%245 = load %struct.target*, %struct.target** %9
%246 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %242, i8** %244, %struct.target* %245)
%247 = load i32, i32* %42
%248 = sext i32 %247 to i64
%249 = add nsw i64 %248, %246
%250 = trunc i64 %249 to i32
store i32 %250, i32* %42
%251 = load i32, i32* %26
%252 = load i8**, i8*** %10
%253 = getelementptr inbounds i8*, i8** %252, i64 15
%254 = load %struct.target*, %struct.target** %9
%255 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %251, i8** %253, %struct.target* %254)
%256 = load i32, i32* %42
%257 = sext i32 %256 to i64
%258 = add nsw i64 %257, %255
%259 = trunc i64 %258 to i32
store i32 %259, i32* %42
%260 = load i32, i32* %27
%261 = load i8**, i8*** %10
%262 = getelementptr inbounds i8*, i8** %261, i64 16
%263 = load %struct.target*, %struct.target** %9
%264 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %260, i8** %262, %struct.target* %263)
%265 = load i32, i32* %42
%266 = sext i32 %265 to i64
%267 = add nsw i64 %266, %264
%268 = trunc i64 %267 to i32
store i32 %268, i32* %42
%269 = load i32, i32* %28
%270 = load i8**, i8*** %10
%271 = getelementptr inbounds i8*, i8** %270, i64 17
%272 = load %struct.target*, %struct.target** %9
%273 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %269, i8** %271, %struct.target* %272)
%274 = load i32, i32* %42
%275 = sext i32 %274 to i64
%276 = add nsw i64 %275, %273
%277 = trunc i64 %276 to i32
store i32 %277, i32* %42
%278 = load i32, i32* %29
%279 = load i8**, i8*** %10
%280 = getelementptr inbounds i8*, i8** %279, i64 18
%281 = load %struct.target*, %struct.target** %9
%282 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %278, i8** %280, %struct.target* %281)
%283 = load i32, i32* %42
%284 = sext i32 %283 to i64
%285 = add nsw i64 %284, %282
%286 = trunc i64 %285 to i32
store i32 %286, i32* %42
%287 = load i32, i32* %30
%288 = load i8**, i8*** %10
%289 = getelementptr inbounds i8*, i8** %288, i64 19
%290 = load %struct.target*, %struct.target** %9
%291 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %287, i8** %289, %struct.target* %290)
%292 = load i32, i32* %42
%293 = sext i32 %292 to i64
%294 = add nsw i64 %293, %291
%295 = trunc i64 %294 to i32
store i32 %295, i32* %42
%296 = load i32, i32* %31
%297 = load i8**, i8*** %10
%298 = getelementptr inbounds i8*, i8** %297, i64 20
%299 = load %struct.target*, %struct.target** %9
%300 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %296, i8** %298, %struct.target* %299)
%301 = load i32, i32* %42
%302 = sext i32 %301 to i64
%303 = add nsw i64 %302, %300
%304 = trunc i64 %303 to i32
store i32 %304, i32* %42
%305 = load i32, i32* %32
%306 = load i8**, i8*** %10
%307 = getelementptr inbounds i8*, i8** %306, i64 21
%308 = load %struct.target*, %struct.target** %9
%309 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %305, i8** %307, %struct.target* %308)
%310 = load i32, i32* %42
%311 = sext i32 %310 to i64
%312 = add nsw i64 %311, %309
%313 = trunc i64 %312 to i32
store i32 %313, i32* %42
%314 = load i32, i32* %33
%315 = load i8**, i8*** %10
%316 = getelementptr inbounds i8*, i8** %315, i64 22
%317 = load %struct.target*, %struct.target** %9
%318 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %314, i8** %316, %struct.target* %317)
%319 = load i32, i32* %42
%320 = sext i32 %319 to i64
%321 = add nsw i64 %320, %318
%322 = trunc i64 %321 to i32
store i32 %322, i32* %42
%323 = load i32, i32* %34
%324 = load i8**, i8*** %10
%325 = getelementptr inbounds i8*, i8** %324, i64 23
%326 = load %struct.target*, %struct.target** %9
%327 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %323, i8** %325, %struct.target* %326)
%328 = load i32, i32* %42
%329 = sext i32 %328 to i64
%330 = add nsw i64 %329, %327
%331 = trunc i64 %330 to i32
store i32 %331, i32* %42
%332 = load i32, i32* %35
%333 = load i8**, i8*** %10
%334 = getelementptr inbounds i8*, i8** %333, i64 24
%335 = load %struct.target*, %struct.target** %9
%336 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %332, i8** %334, %struct.target* %335)
%337 = load i32, i32* %42
%338 = sext i32 %337 to i64
%339 = add nsw i64 %338, %336
%340 = trunc i64 %339 to i32
store i32 %340, i32* %42
%341 = load i32, i32* %36
%342 = load i8**, i8*** %10
%343 = getelementptr inbounds i8*, i8** %342, i64 25
%344 = load %struct.target*, %struct.target** %9
%345 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %341, i8** %343, %struct.target* %344)
%346 = load i32, i32* %42
%347 = sext i32 %346 to i64
%348 = add nsw i64 %347, %345
%349 = trunc i64 %348 to i32
store i32 %349, i32* %42
%350 = load i32, i32* %37
%351 = load i8**, i8*** %10
%352 = getelementptr inbounds i8*, i8** %351, i64 26
%353 = load %struct.target*, %struct.target** %9
%354 = call i64 @dump_long_long_unsigned_int_from_mem(i32 %350, i8** %352, %struct.target* %353)
%355 = load i32, i32* %42
%356 = sext i32 %355 to i64
%357 = add nsw i64 %356, %354
%358 = trunc i64 %357 to i32
store i32 %358, i32* %42
%359 = load i32, i32* %38
%360 = load i8**, i8*** %10
%361 = getelementptr inbounds i8*, i8** %360, i64 27
%362 = load %struct.target*, %struct.target** %9
%363 = call i64 @dump_n_bytes_from_mem(i32 %359, i8** %361, %struct.target* %362, i32 4)
%364 = load i32, i32* %42
%365 = sext i32 %364 to i64
%366 = add nsw i64 %365, %363
%367 = trunc i64 %366 to i32
store i32 %367, i32* %42
%368 = load i32, i32* %39
%369 = load i8**, i8*** %10
%370 = getelementptr inbounds i8*, i8** %369, i64 28
%371 = load %struct.target*, %struct.target** %9
%372 = call i64 @dump_unsigned_int_from_mem(i32 %368, i8** %370, %struct.target* %371)
%373 = load i32, i32* %42
%374 = sext i32 %373 to i64
%375 = add nsw i64 %374, %372
%376 = trunc i64 %375 to i32
store i32 %376, i32* %42
%377 = load i32, i32* %40
%378 = load i8**, i8*** %10
%379 = getelementptr inbounds i8*, i8** %378, i64 29
%380 = load %struct.target*, %struct.target** %9
%381 = call i64 @dump_n_bytes_from_mem(i32 %377, i8** %379, %struct.target* %380, i32 8)
%382 = load i32, i32* %42
%383 = sext i32 %382 to i64
%384 = add nsw i64 %383, %381
%385 = trunc i64 %384 to i32
store i32 %385, i32* %42
%386 = load i32, i32* %41
%387 = load i8**, i8*** %10
%388 = getelementptr inbounds i8*, i8** %387, i64 30
%389 = load %struct.target*, %struct.target** %9
%390 = call i64 @dump_n_bytes_from_mem(i32 %386, i8** %388, %struct.target* %389, i32 8)
%391 = load i32, i32* %42
%392 = sext i32 %391 to i64
%393 = add nsw i64 %392, %390
%394 = trunc i64 %393 to i32
store i32 %394, i32* %42
br label %395
395: ; preds = %115, %110
%396 = load i8**, i8*** %10
%397 = call i8* @copy_params(i8** %396, i32 31, i32* %42)
%398 = load i8**, i8*** %8
store i8* %397, i8** %398
%399 = load i8**, i8*** %10
%400 = call i32 @free_dumped_params(i8** %399, i32 31)
%401 = load i32, i32* %42
store i32 %401, i32* %5
br label %402
402: ; preds = %395, %106
%403 = load i32, i32* %5
ret i32 %403
}

LLVM IR (-O2):
%struct.target = type { i32 }
define i32 @dump_perf_event_attr(i32 %0, i32 %1, i8** nocapture writeonly %2, %struct.target* %3) {
%5 = alloca i32
%6 = add i32 %1, 40
%7 = bitcast i32* %5 to i8*
%8 = icmp slt i32 %0, 0
br i1 %8, label %9, label %11
9: ; preds = %4
%10 = tail call i8* @malloc(i32 0)
store i8* %10, i8** %2
br label %148
11: ; preds = %4
%12 = add i32 %1, 64
%13 = add i32 %1, 56
%14 = add i32 %1, 52
%15 = add i32 %1, 48
%16 = add i32 %1, 32
%17 = add i32 %1, 24
%18 = add i32 %1, 16
%19 = add i32 %1, 8
%20 = add i32 %1, 4
%21 = tail call dereferenceable_or_null(248) i8* @malloc(i32 248)
%22 = bitcast i8* %21 to i8**
%23 = tail call i64 @dump_unsigned_int_from_mem(i32 %1, i8** %22, %struct.target* %3)
%24 = trunc i64 %23 to i32
%25 = getelementptr inbounds i8*, i8** %22, i64 1
%26 = tail call i64 @dump_unsigned_int_from_mem(i32 %20, i8** %25, %struct.target* %3)
%27 = trunc i64 %26 to i32
%28 = add i32 %24, %27
%29 = getelementptr inbounds i8*, i8** %22, i64 2
%30 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %19, i8** %29, %struct.target* %3)
%31 = trunc i64 %30 to i32
%32 = add i32 %28, %31
%33 = getelementptr inbounds i8*, i8** %22, i64 3
%34 = tail call i64 @dump_n_bytes_from_mem(i32 %18, i8** %33, %struct.target* %3, i32 8)
%35 = trunc i64 %34 to i32
%36 = add i32 %32, %35
%37 = getelementptr inbounds i8*, i8** %22, i64 4
%38 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %17, i8** %37, %struct.target* %3)
%39 = trunc i64 %38 to i32
%40 = add i32 %36, %39
%41 = getelementptr inbounds i8*, i8** %22, i64 5
%42 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %16, i8** %41, %struct.target* %3)
%43 = trunc i64 %42 to i32
%44 = add i32 %40, %43
%45 = getelementptr inbounds i8*, i8** %22, i64 6
%46 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %45, %struct.target* %3)
%47 = trunc i64 %46 to i32
%48 = add i32 %44, %47
%49 = getelementptr inbounds i8*, i8** %22, i64 7
%50 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %49, %struct.target* %3)
%51 = trunc i64 %50 to i32
%52 = add i32 %48, %51
%53 = getelementptr inbounds i8*, i8** %22, i64 8
%54 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %53, %struct.target* %3)
%55 = trunc i64 %54 to i32
%56 = add i32 %52, %55
%57 = getelementptr inbounds i8*, i8** %22, i64 9
%58 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %57, %struct.target* %3)
%59 = trunc i64 %58 to i32
%60 = add i32 %56, %59
%61 = getelementptr inbounds i8*, i8** %22, i64 10
%62 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %61, %struct.target* %3)
%63 = trunc i64 %62 to i32
%64 = add i32 %60, %63
%65 = getelementptr inbounds i8*, i8** %22, i64 11
%66 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %65, %struct.target* %3)
%67 = trunc i64 %66 to i32
%68 = add i32 %64, %67
%69 = getelementptr inbounds i8*, i8** %22, i64 12
%70 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %69, %struct.target* %3)
%71 = trunc i64 %70 to i32
%72 = add i32 %68, %71
%73 = getelementptr inbounds i8*, i8** %22, i64 13
%74 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %73, %struct.target* %3)
%75 = trunc i64 %74 to i32
%76 = add i32 %72, %75
%77 = getelementptr inbounds i8*, i8** %22, i64 14
%78 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %77, %struct.target* %3)
%79 = trunc i64 %78 to i32
%80 = add i32 %76, %79
%81 = getelementptr inbounds i8*, i8** %22, i64 15
%82 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %81, %struct.target* %3)
%83 = trunc i64 %82 to i32
%84 = add i32 %80, %83
%85 = getelementptr inbounds i8*, i8** %22, i64 16
%86 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %85, %struct.target* %3)
%87 = trunc i64 %86 to i32
%88 = add i32 %84, %87
%89 = getelementptr inbounds i8*, i8** %22, i64 17
%90 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %89, %struct.target* %3)
%91 = trunc i64 %90 to i32
%92 = add i32 %88, %91
%93 = getelementptr inbounds i8*, i8** %22, i64 18
%94 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %93, %struct.target* %3)
%95 = trunc i64 %94 to i32
%96 = add i32 %92, %95
%97 = getelementptr inbounds i8*, i8** %22, i64 19
%98 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %97, %struct.target* %3)
%99 = trunc i64 %98 to i32
%100 = add i32 %96, %99
%101 = getelementptr inbounds i8*, i8** %22, i64 20
%102 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %101, %struct.target* %3)
%103 = trunc i64 %102 to i32
%104 = add i32 %100, %103
%105 = getelementptr inbounds i8*, i8** %22, i64 21
%106 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %105, %struct.target* %3)
%107 = trunc i64 %106 to i32
%108 = add i32 %104, %107
%109 = getelementptr inbounds i8*, i8** %22, i64 22
%110 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %109, %struct.target* %3)
%111 = trunc i64 %110 to i32
%112 = add i32 %108, %111
%113 = getelementptr inbounds i8*, i8** %22, i64 23
%114 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %113, %struct.target* %3)
%115 = trunc i64 %114 to i32
%116 = add i32 %112, %115
%117 = getelementptr inbounds i8*, i8** %22, i64 24
%118 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %117, %struct.target* %3)
%119 = trunc i64 %118 to i32
%120 = add i32 %116, %119
%121 = getelementptr inbounds i8*, i8** %22, i64 25
%122 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %121, %struct.target* %3)
%123 = trunc i64 %122 to i32
%124 = add i32 %120, %123
%125 = getelementptr inbounds i8*, i8** %22, i64 26
%126 = tail call i64 @dump_long_long_unsigned_int_from_mem(i32 %6, i8** %125, %struct.target* %3)
%127 = trunc i64 %126 to i32
%128 = add i32 %124, %127
%129 = getelementptr inbounds i8*, i8** %22, i64 27
%130 = tail call i64 @dump_n_bytes_from_mem(i32 %15, i8** %129, %struct.target* %3, i32 4)
%131 = trunc i64 %130 to i32
%132 = add i32 %128, %131
%133 = getelementptr inbounds i8*, i8** %22, i64 28
%134 = tail call i64 @dump_unsigned_int_from_mem(i32 %14, i8** %133, %struct.target* %3)
%135 = trunc i64 %134 to i32
%136 = add i32 %132, %135
%137 = getelementptr inbounds i8*, i8** %22, i64 29
%138 = tail call i64 @dump_n_bytes_from_mem(i32 %13, i8** %137, %struct.target* %3, i32 8)
%139 = trunc i64 %138 to i32
%140 = add i32 %136, %139
%141 = getelementptr inbounds i8*, i8** %22, i64 30
%142 = tail call i64 @dump_n_bytes_from_mem(i32 %12, i8** %141, %struct.target* %3, i32 8)
%143 = trunc i64 %142 to i32
%144 = add i32 %140, %143
store i32 %144, i32* %5
%145 = call i8* @copy_params(i8** %22, i32 31, i32* %5)
store i8* %145, i8** %2
%146 = call i32 @free_dumped_params(i8** %22, i32 31)
%147 = load i32, i32* %5
br label %148
148: ; preds = %11, %9
%149 = phi i32 [ %147, %11 ], [ 0, %9 ]
ret i32 %149
}