#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 */
typedef int /*<<< orphan*/ xcb_window_t;
typedef int /*<<< orphan*/ xcb_void_cookie_t;
typedef int /*<<< orphan*/ xcb_connection_t;
typedef int /*<<< orphan*/ uint32_t;

/* Variables and functions */
int /*<<< orphan*/ XCB_ATOM_STRING;
int /*<<< orphan*/ XCB_ATOM_WM_CLASS;
int /*<<< orphan*/ XCB_PROP_MODE_REPLACE;
int /*<<< orphan*/ xcb_change_property(int /*<<< orphan*/ *, int /*<<< orphan*/,
                                       int /*<<< orphan*/, int /*<<< orphan*/,
                                       int /*<<< orphan*/, int,
                                       int /*<<< orphan*/, char const *);
xcb_void_cookie_t xcb_icccm_set_wm_class(xcb_connection_t *c,
                                         xcb_window_t window,
                                         uint32_t class_len,
                                         const char *class) {
  return xcb_change_property(c, XCB_PROP_MODE_REPLACE, window,
                             XCB_ATOM_WM_CLASS, XCB_ATOM_STRING, 8, class_len,
                             class);
}


x86 assembly (clang, -O0):
<xcb_icccm_set_wm_class>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
mov    %rcx,-0x18(%rbp)
mov    -0x8(%rbp),%rdi
mov    0x2ea7(%rip),%rax
mov    (%rax),%esi
mov    -0xc(%rbp),%edx
mov    0x2e8b(%rip),%rax
mov    (%rax),%ecx
mov    0x2eaa(%rip),%rax
mov    (%rax),%r8d
mov    -0x10(%rbp),%r10d
mov    -0x18(%rbp),%rax
mov    $0x8,%r9d
mov    %r10d,(%rsp)
mov    %rax,0x8(%rsp)
call   1030 <xcb_change_property@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<xcb_icccm_set_wm_class>:
push   %rax
mov    %rcx,%r11
mov    %edx,%r10d
mov    %esi,%edx
mov    0x2eb8(%rip),%rcx
mov    (%rcx),%esi
mov    0x2e9f(%rip),%rcx
mov    (%rcx),%ecx
mov    0x2ebe(%rip),%rax
mov    (%rax),%r8d
mov    $0x8,%r9d
push   %r11
push   %r10
call   1030 <xcb_change_property@plt>
add    $0x10,%rsp
pop    %rcx
ret

LLVM IR (-O0):
@XCB_PROP_MODE_REPLACE = global i32 0
@XCB_ATOM_WM_CLASS = global i32 0
@XCB_ATOM_STRING = global i32 0
define i32 @xcb_icccm_set_wm_class(i32* %0, i32 %1, i32 %2, i8* %3) {
%5 = alloca i32*
%6 = alloca i32
%7 = alloca i32
%8 = alloca i8*
store i32* %0, i32** %5
store i32 %1, i32* %6
store i32 %2, i32* %7
store i8* %3, i8** %8
%9 = load i32*, i32** %5
%10 = load i32, i32* @XCB_PROP_MODE_REPLACE
%11 = load i32, i32* %6
%12 = load i32, i32* @XCB_ATOM_WM_CLASS
%13 = load i32, i32* @XCB_ATOM_STRING
%14 = load i32, i32* %7
%15 = load i8*, i8** %8
%16 = call i32 @xcb_change_property(i32* %9, i32 %10, i32 %11, i32 %12, i32 %13, i32 8, i32 %14, i8* %15)
ret i32 %16
}

LLVM IR (-O2):
@XCB_PROP_MODE_REPLACE = global i32 0
@XCB_ATOM_WM_CLASS = global i32 0
@XCB_ATOM_STRING = global i32 0
define i32 @xcb_icccm_set_wm_class(i32* %0, i32 %1, i32 %2, i8* %3) {
%5 = load i32, i32* @XCB_PROP_MODE_REPLACE
%6 = load i32, i32* @XCB_ATOM_WM_CLASS
%7 = load i32, i32* @XCB_ATOM_STRING
%8 = tail call i32 @xcb_change_property(i32* %0, i32 %5, i32 %1, i32 %6, i32 %7, i32 8, i32 %2, i8* %3)
ret i32 %8
}