#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 */

/* Variables and functions */
int /*<<< orphan*/ UpnpResponse_Error(void *, int, char *);
int /*<<< orphan*/
UpnpResponse_MediaRenderer_AVTransport_GetDeviceCapabilities(void *, char *,
                                                             char *, char *);
void UpnpMediaRenderer_AVTransport_GetDeviceCapabilities(
    void *upnptoken, unsigned int InstanceID) {
  ;
  if (InstanceID != 0) {
    UpnpResponse_Error(upnptoken, 718, "Specified instance ID does not exist.");
    return;
  }
  UpnpResponse_MediaRenderer_AVTransport_GetDeviceCapabilities(
      upnptoken, "NETWORK", "NOT_IMPLEMENTED", "NOT_IMPLEMENTED");
}


x86 assembly (clang, -O0):
<UpnpMediaRenderer_AVTransport_GetDeviceCapabilities>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
cmpl   $0x0,-0xc(%rbp)
je     1153 <UpnpMediaRenderer_AVTransport_GetDeviceCapabilities+0x33>
mov    -0x8(%rbp),%rdi
mov    $0x2ce,%esi
lea    0xeb7(%rip),%rdx
call   1040 <UpnpResponse_Error@plt>
jmp    116d <UpnpMediaRenderer_AVTransport_GetDeviceCapabilities+0x4d>
mov    -0x8(%rbp),%rdi
lea    0xec8(%rip),%rsi
lea    0xec9(%rip),%rcx
mov    %rcx,%rdx
call   1030 <UpnpResponse_MediaRenderer_AVTransport_GetDeviceCapabilities@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<UpnpMediaRenderer_AVTransport_GetDeviceCapabilities>:
test   %esi,%esi
je     1135 <UpnpMediaRenderer_AVTransport_GetDeviceCapabilities+0x15>
lea    0xed5(%rip),%rdx
mov    $0x2ce,%esi
jmp    1040 <UpnpResponse_Error@plt>
lea    0xeea(%rip),%rsi
lea    0xeeb(%rip),%rcx
mov    %rcx,%rdx
jmp    1030 <UpnpResponse_MediaRenderer_AVTransport_GetDeviceCapabilities@plt>

LLVM IR (-O0):
@.str = [38 x i8] c"Specified instance ID does not exist.\00"
@.str.1 = [8 x i8] c"NETWORK\00"
@.str.2 = [16 x i8] c"NOT_IMPLEMENTED\00"
define void @UpnpMediaRenderer_AVTransport_GetDeviceCapabilities(i8* %0, i32 %1) {
%3 = alloca i8*
%4 = alloca i32
store i8* %0, i8** %3
store i32 %1, i32* %4
%5 = load i32, i32* %4
%6 = icmp ne i32 %5, 0
br i1 %6, label %7, label %10
7: ; preds = %2
%8 = load i8*, i8** %3
%9 = call i32 @UpnpResponse_Error(i8* %8, i32 718, i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str, i64 0, i64 0))
br label %13
10: ; preds = %2
%11 = load i8*, i8** %3
%12 = call i32 @UpnpResponse_MediaRenderer_AVTransport_GetDeviceCapabilities(i8* %11, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.2, i64 0, i64 0))
br label %13
13: ; preds = %10, %7
ret void
}

LLVM IR (-O2):
@.str = [38 x i8] c"Specified instance ID does not exist.\00"
@.str.1 = [8 x i8] c"NETWORK\00"
@.str.2 = [16 x i8] c"NOT_IMPLEMENTED\00"
define void @UpnpMediaRenderer_AVTransport_GetDeviceCapabilities(i8* %0, i32 %1) {
%3 = icmp eq i32 %1, 0
br i1 %3, label %6, label %4
4: ; preds = %2
%5 = tail call i32 @UpnpResponse_Error(i8* %0, i32 718, i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str, i64 0, i64 0))
br label %8
6: ; preds = %2
%7 = tail call i32 @UpnpResponse_MediaRenderer_AVTransport_GetDeviceCapabilities(i8* %0, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.2, i64 0, i64 0))
br label %8
8: ; preds = %6, %4
ret void
}