#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 */
char *dcngettext(char const *, char const *, char const *, unsigned long, int);
const char *npgettext_aux(const char *domain, const char *msg_ctxt_id,
                          const char *msgid, const char *msgid_plural,
                          unsigned long int n, int category) {
  const char *translation =
      dcngettext(domain, msg_ctxt_id, msgid_plural, n, category);
  if (translation == msg_ctxt_id || translation == msgid_plural)
    return (n == 1 ? msgid : msgid_plural);
  else
    return translation;
}


x86 assembly (clang, -O0):
<npgettext_aux>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    %rdx,-0x20(%rbp)
mov    %rcx,-0x28(%rbp)
mov    %r8,-0x30(%rbp)
mov    %r9d,-0x34(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    -0x28(%rbp),%rdx
mov    -0x30(%rbp),%rcx
mov    -0x34(%rbp),%r8d
call   1030 <dcngettext@plt>
mov    %rax,-0x40(%rbp)
mov    -0x40(%rbp),%rax
cmp    -0x18(%rbp),%rax
je     1169 <npgettext_aux+0x59>
mov    -0x40(%rbp),%rax
cmp    -0x28(%rbp),%rax
jne    1196 <npgettext_aux+0x86>
cmpq   $0x1,-0x30(%rbp)
jne    1181 <npgettext_aux+0x71>
mov    -0x20(%rbp),%rax
mov    %rax,-0x48(%rbp)
jmp    1189 <npgettext_aux+0x79>
mov    -0x28(%rbp),%rax
mov    %rax,-0x48(%rbp)
mov    -0x48(%rbp),%rax
mov    %rax,-0x8(%rbp)
jmp    119e <npgettext_aux+0x8e>
mov    -0x40(%rbp),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<npgettext_aux>:
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
mov    %r8,%r14
mov    %rcx,%r15
mov    %rdx,%rbx
mov    %rsi,%r12
mov    %rcx,%rdx
mov    %r8,%rcx
mov    %r9d,%r8d
call   1030 <dcngettext@plt>
cmp    $0x1,%r14
cmovne %r15,%rbx
cmp    %r15,%rax
mov    %rax,%rcx
cmove  %rbx,%rcx
cmp    %r12,%rax
cmove  %rbx,%rcx
mov    %rcx,%rax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
define i8* @npgettext_aux(i8* %0, i8* %1, i8* %2, i8* %3, i64 %4, i32 %5) {
%7 = alloca i8*
%8 = alloca i8*
%9 = alloca i8*
%10 = alloca i8*
%11 = alloca i8*
%12 = alloca i64
%13 = alloca i32
%14 = alloca i8*
store i8* %0, i8** %8
store i8* %1, i8** %9
store i8* %2, i8** %10
store i8* %3, i8** %11
store i64 %4, i64* %12
store i32 %5, i32* %13
%15 = load i8*, i8** %8
%16 = load i8*, i8** %9
%17 = load i8*, i8** %11
%18 = load i64, i64* %12
%19 = load i32, i32* %13
%20 = call i8* @dcngettext(i8* %15, i8* %16, i8* %17, i64 %18, i32 %19)
store i8* %20, i8** %14
%21 = load i8*, i8** %14
%22 = load i8*, i8** %9
%23 = icmp eq i8* %21, %22
br i1 %23, label %28, label %24
24: ; preds = %6
%25 = load i8*, i8** %14
%26 = load i8*, i8** %11
%27 = icmp eq i8* %25, %26
br i1 %27, label %28, label %37
28: ; preds = %24, %6
%29 = load i64, i64* %12
%30 = icmp eq i64 %29, 1
br i1 %30, label %31, label %33
31: ; preds = %28
%32 = load i8*, i8** %10
br label %35
33: ; preds = %28
%34 = load i8*, i8** %11
br label %35
35: ; preds = %33, %31
%36 = phi i8* [ %32, %31 ], [ %34, %33 ]
store i8* %36, i8** %7
br label %39
37: ; preds = %24
%38 = load i8*, i8** %14
store i8* %38, i8** %7
br label %39
39: ; preds = %37, %35
%40 = load i8*, i8** %7
ret i8* %40
}

LLVM IR (-O2):
define i8* @npgettext_aux(i8* %0, i8* %1, i8* readnone %2, i8* %3, i64 %4, i32 %5) {
%7 = tail call i8* @dcngettext(i8* %0, i8* %1, i8* %3, i64 %4, i32 %5)
%8 = icmp eq i8* %7, %1
%9 = icmp eq i8* %7, %3
%10 = or i1 %8, %9
%11 = icmp eq i64 %4, 1
%12 = select i1 %11, i8* %2, i8* %3
%13 = select i1 %10, i8* %12, i8* %7
ret i8* %13
}