#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 */
typedef struct TYPE_5__ TYPE_2__;
typedef struct TYPE_4__ TYPE_1__;

/* Type definitions */
struct TYPE_4__ {
  int /*<<< orphan*/ height;
  int /*<<< orphan*/ width;
  int /*<<< orphan*/ y;
  int /*<<< orphan*/ x;
};
typedef TYPE_1__ XWindowAttributes;
typedef int /*<<< orphan*/ XEvent;
struct TYPE_5__ {
  int /*<<< orphan*/ override_redirect;
  int /*<<< orphan*/ above;
  scalar_t__ border_width;
  int /*<<< orphan*/ height;
  int /*<<< orphan*/ width;
  int /*<<< orphan*/ y;
  int /*<<< orphan*/ x;
  void *window;
  void *event;
  int /*<<< orphan*/ *display;
  int /*<<< orphan*/ type;
};
typedef TYPE_2__ XConfigureEvent;
typedef void *Window;
typedef int /*<<< orphan*/ Display;

/* Variables and functions */
int /*<<< orphan*/ ConfigureNotify;
int /*<<< orphan*/ False;
int /*<<< orphan*/ None;
int /*<<< orphan*/ StructureNotifyMask;
int /*<<< orphan*/ XSendEvent(int /*<<< orphan*/ *, void *, int /*<<< orphan*/,
                              int /*<<< orphan*/, int /*<<< orphan*/ *);
void configure(Display *d, Window *w, XWindowAttributes *wa) {
  XConfigureEvent ce;
  ce.type = ConfigureNotify;
  ce.display = d;
  ce.event = *w;
  ce.window = *w;
  ce.x = wa->x;
  ce.y = wa->y;
  ce.width = wa->width;
  ce.height = wa->height;
  ce.border_width = 0;
  ce.above = None;
  ce.override_redirect = False;
  XSendEvent(d, *w, False, StructureNotifyMask, (XEvent *)&ce);
}


x86 assembly (clang, -O0):
<configure>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    0x2ead(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x20(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x28(%rbp)
mov    -0x10(%rbp),%rax
mov    (%rax),%rax
mov    %rax,-0x30(%rbp)
mov    -0x10(%rbp),%rax
mov    (%rax),%rax
mov    %rax,-0x38(%rbp)
mov    -0x18(%rbp),%rax
mov    0xc(%rax),%eax
mov    %eax,-0x3c(%rbp)
mov    -0x18(%rbp),%rax
mov    0x8(%rax),%eax
mov    %eax,-0x40(%rbp)
mov    -0x18(%rbp),%rax
mov    0x4(%rax),%eax
mov    %eax,-0x44(%rbp)
mov    -0x18(%rbp),%rax
mov    (%rax),%eax
mov    %eax,-0x48(%rbp)
movq   $0x0,-0x50(%rbp)
mov    0x2e5c(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x54(%rbp)
mov    0x2e58(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x58(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rax
mov    (%rax),%rsi
mov    0x2e41(%rip),%rax
mov    (%rax),%edx
mov    0x2e18(%rip),%rax
mov    (%rax),%ecx
lea    -0x58(%rbp),%r8
call   1030 <XSendEvent@plt>
add    $0x60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<configure>:
sub    $0x48,%rsp
mov    0x2ebd(%rip),%rax
mov    (%rax),%eax
mov    %eax,0x40(%rsp)
mov    %rdi,0x38(%rsp)
mov    (%rsi),%rsi
mov    %rsi,0x30(%rsp)
mov    %rsi,0x28(%rsp)
movups (%rdx),%xmm0
movups %xmm0,0x18(%rsp)
movq   $0x0,0x10(%rsp)
mov    0x2e95(%rip),%rax
mov    (%rax),%eax
mov    %eax,0xc(%rsp)
mov    0x2e90(%rip),%rax
mov    (%rax),%edx
mov    %edx,0x8(%rsp)
mov    0x2e63(%rip),%rax
mov    (%rax),%ecx
lea    0x8(%rsp),%r8
call   1030 <XSendEvent@plt>
add    $0x48,%rsp
ret

LLVM IR (-O0):
%struct.TYPE_4__ = type { i32, i32, i32, i32 }
%struct.TYPE_5__ = type { i32, i32, i64, i32, i32, i32, i32, i8*, i8*, i32*, i32 }
@ConfigureNotify = global i32 0
@None = global i32 0
@False = global i32 0
@StructureNotifyMask = global i32 0
define void @configure(i32* %0, i8** %1, %struct.TYPE_4__* %2) {
%4 = alloca i32*
%5 = alloca i8**
%6 = alloca %struct.TYPE_4__*
%7 = alloca %struct.TYPE_5__
store i32* %0, i32** %4
store i8** %1, i8*** %5
store %struct.TYPE_4__* %2, %struct.TYPE_4__** %6
%8 = load i32, i32* @ConfigureNotify
%9 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %7, i32 0, i32 10
store i32 %8, i32* %9
%10 = load i32*, i32** %4
%11 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %7, i32 0, i32 9
store i32* %10, i32** %11
%12 = load i8**, i8*** %5
%13 = load i8*, i8** %12
%14 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %7, i32 0, i32 8
store i8* %13, i8** %14
%15 = load i8**, i8*** %5
%16 = load i8*, i8** %15
%17 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %7, i32 0, i32 7
store i8* %16, i8** %17
%18 = load %struct.TYPE_4__*, %struct.TYPE_4__** %6
%19 = getelementptr inbounds %struct.TYPE_4__, %struct.TYPE_4__* %18, i32 0, i32 3
%20 = load i32, i32* %19
%21 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %7, i32 0, i32 6
store i32 %20, i32* %21
%22 = load %struct.TYPE_4__*, %struct.TYPE_4__** %6
%23 = getelementptr inbounds %struct.TYPE_4__, %struct.TYPE_4__* %22, i32 0, i32 2
%24 = load i32, i32* %23
%25 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %7, i32 0, i32 5
store i32 %24, i32* %25
%26 = load %struct.TYPE_4__*, %struct.TYPE_4__** %6
%27 = getelementptr inbounds %struct.TYPE_4__, %struct.TYPE_4__* %26, i32 0, i32 1
%28 = load i32, i32* %27
%29 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %7, i32 0, i32 4
store i32 %28, i32* %29
%30 = load %struct.TYPE_4__*, %struct.TYPE_4__** %6
%31 = getelementptr inbounds %struct.TYPE_4__, %struct.TYPE_4__* %30, i32 0, i32 0
%32 = load i32, i32* %31
%33 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %7, i32 0, i32 3
store i32 %32, i32* %33
%34 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %7, i32 0, i32 2
store i64 0, i64* %34
%35 = load i32, i32* @None
%36 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %7, i32 0, i32 1
store i32 %35, i32* %36
%37 = load i32, i32* @False
%38 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %7, i32 0, i32 0
store i32 %37, i32* %38
%39 = load i32*, i32** %4
%40 = load i8**, i8*** %5
%41 = load i8*, i8** %40
%42 = load i32, i32* @False
%43 = load i32, i32* @StructureNotifyMask
%44 = bitcast %struct.TYPE_5__* %7 to i32*
%45 = call i32 @XSendEvent(i32* %39, i8* %41, i32 %42, i32 %43, i32* %44)
ret void
}

LLVM IR (-O2):
%struct.TYPE_4__ = type { i32, i32, i32, i32 }
%struct.TYPE_5__ = type { i32, i32, i64, i32, i32, i32, i32, i8*, i8*, i32*, i32 }
@ConfigureNotify = global i32 0
@None = global i32 0
@False = global i32 0
@StructureNotifyMask = global i32 0
define void @configure(i32* %0, i8** nocapture %1, %struct.TYPE_4__* nocapture %2) {
%4 = alloca %struct.TYPE_5__
%5 = bitcast %struct.TYPE_5__* %4 to i8*
%6 = load i32, i32* @ConfigureNotify
%7 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %4, i64 0, i32 10
store i32 %6, i32* %7
%8 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %4, i64 0, i32 9
store i32* %0, i32** %8
%9 = load i8*, i8** %1
%10 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %4, i64 0, i32 8
store i8* %9, i8** %10
%11 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %4, i64 0, i32 7
store i8* %9, i8** %11
%12 = bitcast %struct.TYPE_4__* %2 to <4 x i32>*
%13 = load <4 x i32>, <4 x i32>* %12
%14 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %4, i64 0, i32 3
%15 = bitcast i32* %14 to <4 x i32>*
store <4 x i32> %13, <4 x i32>* %15
%16 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %4, i64 0, i32 2
store i64 0, i64* %16
%17 = load i32, i32* @None
%18 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %4, i64 0, i32 1
store i32 %17, i32* %18
%19 = load i32, i32* @False
%20 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %4, i64 0, i32 0
store i32 %19, i32* %20
%21 = load i32, i32* @StructureNotifyMask
%22 = call i32 @XSendEvent(i32* %0, i8* %9, i32 %19, i32 %21, i32* %20)
ret void
}