const char *DEC_MODE(int s) {
  return ((s & (0x04 | 0x02 | 0x01)) == (0x04 | 0x02 | 0x01))
             ? "128(adv.cons.)"
             : (((s & (0x04 | 0x02 | 0x01)) == 0x04)
                    ? "28(adv.cons.)"
                    : (((s & (0x04 | 0x02 | 0x01)) == (0x02 | 0x01))
                           ? "128"
                           : (((s & (0x04 | 0x02 | 0x01)) == 0x02)
                                  ? "14"
                                  : (((s & (0x04 | 0x02 | 0x01)) == 0x01)
                                         ? "28(motorola)"
                                         : "28"))));
}


x86 assembly (clang, -O0):
<DEC_MODE>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%eax
and    $0x7,%eax
cmp    $0x7,%eax
jne    1126 <DEC_MODE+0x26>
lea    0xee3(%rip),%rax
mov    %rax,-0x10(%rbp)
jmp    11ba <DEC_MODE+0xba>
mov    -0x4(%rbp),%eax
and    $0x7,%eax
cmp    $0x4,%eax
jne    1145 <DEC_MODE+0x45>
lea    0xec5(%rip),%rax
mov    %rax,-0x18(%rbp)
jmp    11b2 <DEC_MODE+0xb2>
mov    -0x4(%rbp),%eax
and    $0x7,%eax
cmp    $0x3,%eax
jne    1164 <DEC_MODE+0x64>
lea    0xeb4(%rip),%rax
mov    %rax,-0x20(%rbp)
jmp    11aa <DEC_MODE+0xaa>
mov    -0x4(%rbp),%eax
and    $0x7,%eax
cmp    $0x2,%eax
jne    1183 <DEC_MODE+0x83>
lea    0xe99(%rip),%rax
mov    %rax,-0x28(%rbp)
jmp    11a2 <DEC_MODE+0xa2>
mov    -0x4(%rbp),%edx
and    $0x7,%edx
lea    0xe80(%rip),%rax
lea    0xe7f(%rip),%rcx
cmp    $0x1,%edx
cmove  %rcx,%rax
mov    %rax,-0x28(%rbp)
mov    -0x28(%rbp),%rax
mov    %rax,-0x20(%rbp)
mov    -0x20(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<DEC_MODE>:
and    $0x7,%edi
lea    -0x2(%rdi),%eax
cmp    $0x6,%eax
jae    1115 <DEC_MODE+0x15>
mov    $0x27,%ecx
bt     %eax,%ecx
jb     112b <DEC_MODE+0x2b>
cmp    $0x1,%edi
lea    0xef7(%rip),%rcx
lea    0xeea(%rip),%rax
cmove  %rcx,%rax
ret
cltq
lea    0xef0(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
ret

LLVM IR (-O0):
@.str = [15 x i8] c"128(adv.cons.)\00"
@.str.1 = [14 x i8] c"28(adv.cons.)\00"
@.str.2 = [4 x i8] c"128\00"
@.str.3 = [3 x i8] c"14\00"
@.str.4 = [13 x i8] c"28(motorola)\00"
@.str.5 = [3 x i8] c"28\00"
define i8* @DEC_MODE(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = and i32 %3, 7
%5 = icmp eq i32 %4, 7
br i1 %5, label %6, label %7
6: ; preds = %1
br label %34
7: ; preds = %1
%8 = load i32, i32* %2
%9 = and i32 %8, 7
%10 = icmp eq i32 %9, 4
br i1 %10, label %11, label %12
11: ; preds = %7
br label %32
12: ; preds = %7
%13 = load i32, i32* %2
%14 = and i32 %13, 7
%15 = icmp eq i32 %14, 3
br i1 %15, label %16, label %17
16: ; preds = %12
br label %30
17: ; preds = %12
%18 = load i32, i32* %2
%19 = and i32 %18, 7
%20 = icmp eq i32 %19, 2
br i1 %20, label %21, label %22
21: ; preds = %17
br label %28
22: ; preds = %17
%23 = load i32, i32* %2
%24 = and i32 %23, 7
%25 = icmp eq i32 %24, 1
%26 = zext i1 %25 to i64
%27 = select i1 %25, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0)
br label %28
28: ; preds = %22, %21
%29 = phi i8* [ getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), %21 ], [ %27, %22 ]
br label %30
30: ; preds = %28, %16
%31 = phi i8* [ getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), %16 ], [ %29, %28 ]
br label %32
32: ; preds = %30, %11
%33 = phi i8* [ getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0), %11 ], [ %31, %30 ]
br label %34
34: ; preds = %32, %6
%35 = phi i8* [ getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), %6 ], [ %33, %32 ]
ret i8* %35
}

LLVM IR (-O2):
@.str = [15 x i8] c"128(adv.cons.)\00"
@.str.1 = [14 x i8] c"28(adv.cons.)\00"
@.str.2 = [4 x i8] c"128\00"
@.str.3 = [3 x i8] c"14\00"
@.str.4 = [13 x i8] c"28(motorola)\00"
@.str.5 = [3 x i8] c"28\00"
@reltable.DEC_MODE = [6 x i32] [i32 trunc (i64 sub (i64 ptrtoint ([3 x i8]* @.str.3 to i64), i64 ptrtoint ([6 x i32]* @reltable.DEC_MODE to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([4 x i8]* @.str.2 to i64), i64 ptrtoint ([6 x i32]* @reltable.DEC_MODE to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([14 x i8]* @.str.1 to i64), i64 ptrtoint ([6 x i32]* @reltable.DEC_MODE to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([15 x i8]* @.str to i64), i64 ptrtoint ([6 x i32]* @reltable.DEC_MODE to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([15 x i8]* @.str to i64), i64 ptrtoint ([6 x i32]* @reltable.DEC_MODE to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([15 x i8]* @.str to i64), i64 ptrtoint ([6 x i32]* @reltable.DEC_MODE to i64)) to i32)]
define i8* @DEC_MODE(i32 %0) {
%2 = and i32 %0, 7
%3 = add nsw i32 %2, -2
%4 = icmp ult i32 %3, 6
br i1 %4, label %8, label %5
5: ; preds = %8, %1
%6 = icmp eq i32 %2, 1
%7 = select i1 %6, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0)
br label %17
8: ; preds = %1
%9 = trunc i32 %3 to i8
%10 = lshr i8 39, %9
%11 = and i8 %10, 1
%12 = icmp eq i8 %11, 0
br i1 %12, label %5, label %13
13: ; preds = %8
%14 = sext i32 %3 to i64
%15 = shl i64 %14, 2
%16 = call i8* @llvm.load.relative.i64(i8* bitcast ([6 x i32]* @reltable.DEC_MODE to i8*), i64 %15)
br label %17
17: ; preds = %13, %5
%18 = phi i8* [ %7, %5 ], [ %16, %13 ]
ret i8* %18
}