#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*/ cutarray(char *, int, int, int);
int /*<<< orphan*/ printarbin(char *, int);
int /*<<< orphan*/ printbinary(unsigned char);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ shiftarray(char *, int, int);
int main(void) {
  unsigned char chet = 0xAA;
  unsigned char nechet = 0x55;
  unsigned char zero = 0x00;
  unsigned char full = 0xFF;
  unsigned char one = 0x01;
  printf("chet 0x%02X\n", chet);
  printf("~chet 0x%02hhX\n", ~chet);
  printf("chet >> 1 0x%02X\n", chet >> 1);
  printf("nechet 0x%02X\n", nechet);
  printf("~nechet 0x%02hhX\n", ~nechet);
  printf("nechet << 1 0x%02X\n", nechet << 1);
  printf("chet & nechet 0x%02X\n", chet & nechet);
  printf("chet | nechet 0x%02X\n", chet | nechet);
  printf("zero 0x%02X\n", zero);
  printf("~zero 0x%02hhX\n", ~zero);
  printf("full 0x%02X\n", full);
  printf("~full 0x%02hhX\n", ~full);
  printf("full >> 1 0x%02X\n", full >> 1);
  printf("one 0x%02X\n", one);
  printf("~one 0x%02hhX\n", ~one);
  printf("one << 1 0x%02X\n", one << 1);
  printbinary(full);
  printf("\n");
  printbinary(zero);
  printf("\n");
  printbinary(one);
  printf("\n");
  printbinary(chet);
  printf("\n");
  printbinary(nechet);
  printf("\n");
  printarbin("hello", 5);
  printf("\n");
  shiftarray("hello", 5, 1);
  printf("\n");
  shiftarray("hello", 5, 2);
  printf("\n");
  shiftarray("hello", 5, 3);
  printf("\n");
  shiftarray("hello", 5, 4);
  printf("\n");
  shiftarray("hello", 5, 5);
  printf("\n");
  shiftarray("hello", 5, 6);
  printf("\n");
  shiftarray("hello", 5, 7);
  printf("\n");
  shiftarray("hello", 5, 8);
  printf("\n");
  shiftarray("hello", 5, 9);
  printf("\n");
  shiftarray("hello", 5, 10);
  printf("\n");
  shiftarray("hello", 5, 11);
  printf("\n");
  cutarray("hello", 5, 11, 11);
  printf("\n");
  cutarray("hello", 5, 11, 10);
  printf("\n");
  cutarray("hello", 5, 11, 9);
  printf("\n");
  cutarray("hello", 5, 11, 8);
  printf("\n");
  cutarray("hello", 5, 11, 7);
  printf("\n");
  cutarray("hello", 5, 11, 6);
  printf("\n");
  cutarray("hello", 5, 11, 5);
  printf("\n");
  cutarray("hello", 5, 11, 4);
  printf("\n");
  cutarray("hello", 5, 11, 3);
  printf("\n");
  cutarray("hello", 5, 11, 2);
  printf("\n");
  cutarray("hello", 5, 11, 1);
  printf("\n");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movb   $0xaa,-0x5(%rbp)
movb   $0x55,-0x6(%rbp)
movb   $0x0,-0x7(%rbp)
movb   $0xff,-0x8(%rbp)
movb   $0x1,-0x9(%rbp)
movzbl -0x5(%rbp),%esi
lea    0xed3(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x5(%rbp),%esi
xor    $0xffffffff,%esi
lea    0xe6d(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x5(%rbp),%esi
sar    $0x1,%esi
lea    0xe68(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x6(%rbp),%esi
lea    0xe95(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x6(%rbp),%esi
xor    $0xffffffff,%esi
lea    0xe53(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x6(%rbp),%esi
shl    $0x1,%esi
lea    0xe50(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x5(%rbp),%esi
movzbl -0x6(%rbp),%eax
and    %eax,%esi
lea    0xe4c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x5(%rbp),%esi
movzbl -0x6(%rbp),%eax
or     %eax,%esi
lea    0xe4a(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x7(%rbp),%esi
lea    0xe4e(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x7(%rbp),%esi
xor    $0xffffffff,%esi
lea    0xe46(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x8(%rbp),%esi
lea    0xe44(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x8(%rbp),%esi
xor    $0xffffffff,%esi
lea    0xe3c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x8(%rbp),%esi
sar    $0x1,%esi
lea    0xe37(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x9(%rbp),%esi
lea    0xe37(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x9(%rbp),%esi
xor    $0xffffffff,%esi
lea    0xe2e(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x9(%rbp),%esi
shl    $0x1,%esi
lea    0xe28(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x8(%rbp),%edi
call   1060 <printbinary@plt>
lea    0xe20(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x7(%rbp),%edi
call   1060 <printbinary@plt>
lea    0xe09(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x9(%rbp),%edi
call   1060 <printbinary@plt>
lea    0xdf2(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x5(%rbp),%edi
call   1060 <printbinary@plt>
lea    0xddb(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movzbl -0x6(%rbp),%edi
call   1060 <printbinary@plt>
lea    0xdc4(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xdb8(%rip),%rdi
mov    $0x5,%esi
call   1070 <printarbin@plt>
lea    0xda5(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xd99(%rip),%rdi
mov    $0x5,%esi
mov    $0x1,%edx
call   1050 <shiftarray@plt>
lea    0xd81(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xd75(%rip),%rdi
mov    $0x5,%esi
mov    $0x2,%edx
call   1050 <shiftarray@plt>
lea    0xd5d(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xd51(%rip),%rdi
mov    $0x5,%esi
mov    $0x3,%edx
call   1050 <shiftarray@plt>
lea    0xd39(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xd2d(%rip),%rdi
mov    $0x5,%esi
mov    $0x4,%edx
call   1050 <shiftarray@plt>
lea    0xd15(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xd09(%rip),%rdi
mov    $0x5,%edx
mov    %edx,%esi
call   1050 <shiftarray@plt>
lea    0xcf4(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xce8(%rip),%rdi
mov    $0x5,%esi
mov    $0x6,%edx
call   1050 <shiftarray@plt>
lea    0xcd0(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xcc4(%rip),%rdi
mov    $0x5,%esi
mov    $0x7,%edx
call   1050 <shiftarray@plt>
lea    0xcac(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xca0(%rip),%rdi
mov    $0x5,%esi
mov    $0x8,%edx
call   1050 <shiftarray@plt>
lea    0xc88(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xc7c(%rip),%rdi
mov    $0x5,%esi
mov    $0x9,%edx
call   1050 <shiftarray@plt>
lea    0xc64(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xc58(%rip),%rdi
mov    $0x5,%esi
mov    $0xa,%edx
call   1050 <shiftarray@plt>
lea    0xc40(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xc34(%rip),%rdi
mov    $0x5,%esi
mov    $0xb,%edx
call   1050 <shiftarray@plt>
lea    0xc1c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xc10(%rip),%rdi
mov    $0x5,%esi
mov    $0xb,%ecx
mov    %ecx,%edx
call   1040 <cutarray@plt>
lea    0xbf6(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xbea(%rip),%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0xa,%ecx
call   1040 <cutarray@plt>
lea    0xbcd(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xbc1(%rip),%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x9,%ecx
call   1040 <cutarray@plt>
lea    0xba4(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xb98(%rip),%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x8,%ecx
call   1040 <cutarray@plt>
lea    0xb7b(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xb6f(%rip),%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x7,%ecx
call   1040 <cutarray@plt>
lea    0xb52(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xb46(%rip),%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x6,%ecx
call   1040 <cutarray@plt>
lea    0xb29(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xb1d(%rip),%rdi
mov    $0x5,%ecx
mov    $0xb,%edx
mov    %ecx,%esi
call   1040 <cutarray@plt>
lea    0xb03(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xaf7(%rip),%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x4,%ecx
call   1040 <cutarray@plt>
lea    0xada(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xace(%rip),%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x3,%ecx
call   1040 <cutarray@plt>
lea    0xab1(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xaa5(%rip),%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x2,%ecx
call   1040 <cutarray@plt>
lea    0xa88(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xa7c(%rip),%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x1,%ecx
call   1040 <cutarray@plt>
lea    0xa5f(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
lea    0xee9(%rip),%rdi
mov    $0xaa,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe85(%rip),%rdi
mov    $0xffffff55,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe82(%rip),%rdi
mov    $0x55,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xeae(%rip),%rdi
mov    $0x55,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe6e(%rip),%rdi
mov    $0xffffffaa,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe6d(%rip),%rdi
mov    $0xaa,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe6e(%rip),%rdi
xor    %esi,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe74(%rip),%rdi
mov    $0xff,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe77(%rip),%rdi
xor    %esi,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe74(%rip),%rdi
mov    $0xffffffff,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe71(%rip),%rdi
mov    $0xff,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe6b(%rip),%rdi
mov    $0xffffff00,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe68(%rip),%rdi
mov    $0x7f,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe67(%rip),%rdi
mov    $0x1,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe60(%rip),%rdi
mov    $0xfffffffe,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe5c(%rip),%rdi
mov    $0x2,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0xff,%edi
call   1070 <printbinary@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
xor    %edi,%edi
call   1070 <printbinary@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0x1,%edi
call   1070 <printbinary@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xaa,%edi
call   1070 <printbinary@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0x55,%edi
call   1070 <printbinary@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    0xdf9(%rip),%rbx
mov    %rbx,%rdi
mov    $0x5,%esi
call   1080 <printarbin@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0x1,%edx
call   1060 <shiftarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0x2,%edx
call   1060 <shiftarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0x3,%edx
call   1060 <shiftarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0x4,%edx
call   1060 <shiftarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0x5,%edx
call   1060 <shiftarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0x6,%edx
call   1060 <shiftarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0x7,%edx
call   1060 <shiftarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0x8,%edx
call   1060 <shiftarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0x9,%edx
call   1060 <shiftarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0xa,%edx
call   1060 <shiftarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0xb,%edx
call   1060 <shiftarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0xb,%ecx
call   1050 <cutarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0xa,%ecx
call   1050 <cutarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x9,%ecx
call   1050 <cutarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x8,%ecx
call   1050 <cutarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x7,%ecx
call   1050 <cutarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x6,%ecx
call   1050 <cutarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x5,%ecx
call   1050 <cutarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x4,%ecx
call   1050 <cutarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x3,%ecx
call   1050 <cutarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x2,%ecx
call   1050 <cutarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
mov    $0xb,%edx
mov    $0x1,%ecx
call   1050 <cutarray@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [13 x i8] c"chet 0x%02X\0A\00"
@.str.1 = [16 x i8] c"~chet 0x%02hhX\0A\00"
@.str.2 = [18 x i8] c"chet >> 1 0x%02X\0A\00"
@.str.3 = [15 x i8] c"nechet 0x%02X\0A\00"
@.str.4 = [18 x i8] c"~nechet 0x%02hhX\0A\00"
@.str.5 = [20 x i8] c"nechet << 1 0x%02X\0A\00"
@.str.6 = [22 x i8] c"chet & nechet 0x%02X\0A\00"
@.str.7 = [22 x i8] c"chet | nechet 0x%02X\0A\00"
@.str.8 = [13 x i8] c"zero 0x%02X\0A\00"
@.str.9 = [16 x i8] c"~zero 0x%02hhX\0A\00"
@.str.10 = [13 x i8] c"full 0x%02X\0A\00"
@.str.11 = [16 x i8] c"~full 0x%02hhX\0A\00"
@.str.12 = [18 x i8] c"full >> 1 0x%02X\0A\00"
@.str.13 = [12 x i8] c"one 0x%02X\0A\00"
@.str.14 = [15 x i8] c"~one 0x%02hhX\0A\00"
@.str.15 = [17 x i8] c"one << 1 0x%02X\0A\00"
@.str.16 = [2 x i8] c"\0A\00"
@.str.17 = [6 x i8] c"hello\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i8
%3 = alloca i8
%4 = alloca i8
%5 = alloca i8
%6 = alloca i8
store i32 0, i32* %1
store i8 -86, i8* %2
store i8 85, i8* %3
store i8 0, i8* %4
store i8 -1, i8* %5
store i8 1, i8* %6
%7 = load i8, i8* %2
%8 = zext i8 %7 to i32
%9 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 %8)
%10 = load i8, i8* %2
%11 = zext i8 %10 to i32
%12 = xor i32 %11, -1
%13 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.1, i64 0, i64 0), i32 %12)
%14 = load i8, i8* %2
%15 = zext i8 %14 to i32
%16 = ashr i32 %15, 1
%17 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.2, i64 0, i64 0), i32 %16)
%18 = load i8, i8* %3
%19 = zext i8 %18 to i32
%20 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.3, i64 0, i64 0), i32 %19)
%21 = load i8, i8* %3
%22 = zext i8 %21 to i32
%23 = xor i32 %22, -1
%24 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.4, i64 0, i64 0), i32 %23)
%25 = load i8, i8* %3
%26 = zext i8 %25 to i32
%27 = shl i32 %26, 1
%28 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.5, i64 0, i64 0), i32 %27)
%29 = load i8, i8* %2
%30 = zext i8 %29 to i32
%31 = load i8, i8* %3
%32 = zext i8 %31 to i32
%33 = and i32 %30, %32
%34 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.6, i64 0, i64 0), i32 %33)
%35 = load i8, i8* %2
%36 = zext i8 %35 to i32
%37 = load i8, i8* %3
%38 = zext i8 %37 to i32
%39 = or i32 %36, %38
%40 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.7, i64 0, i64 0), i32 %39)
%41 = load i8, i8* %4
%42 = zext i8 %41 to i32
%43 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.8, i64 0, i64 0), i32 %42)
%44 = load i8, i8* %4
%45 = zext i8 %44 to i32
%46 = xor i32 %45, -1
%47 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.9, i64 0, i64 0), i32 %46)
%48 = load i8, i8* %5
%49 = zext i8 %48 to i32
%50 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.10, i64 0, i64 0), i32 %49)
%51 = load i8, i8* %5
%52 = zext i8 %51 to i32
%53 = xor i32 %52, -1
%54 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.11, i64 0, i64 0), i32 %53)
%55 = load i8, i8* %5
%56 = zext i8 %55 to i32
%57 = ashr i32 %56, 1
%58 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.12, i64 0, i64 0), i32 %57)
%59 = load i8, i8* %6
%60 = zext i8 %59 to i32
%61 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.13, i64 0, i64 0), i32 %60)
%62 = load i8, i8* %6
%63 = zext i8 %62 to i32
%64 = xor i32 %63, -1
%65 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.14, i64 0, i64 0), i32 %64)
%66 = load i8, i8* %6
%67 = zext i8 %66 to i32
%68 = shl i32 %67, 1
%69 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.15, i64 0, i64 0), i32 %68)
%70 = load i8, i8* %5
%71 = call i32 @printbinary(i8 zeroext %70)
%72 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%73 = load i8, i8* %4
%74 = call i32 @printbinary(i8 zeroext %73)
%75 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%76 = load i8, i8* %6
%77 = call i32 @printbinary(i8 zeroext %76)
%78 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%79 = load i8, i8* %2
%80 = call i32 @printbinary(i8 zeroext %79)
%81 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%82 = load i8, i8* %3
%83 = call i32 @printbinary(i8 zeroext %82)
%84 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%85 = call i32 @printarbin(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5)
%86 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%87 = call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 1)
%88 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%89 = call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 2)
%90 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%91 = call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 3)
%92 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%93 = call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 4)
%94 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%95 = call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 5)
%96 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%97 = call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 6)
%98 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%99 = call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 7)
%100 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%101 = call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 8)
%102 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%103 = call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 9)
%104 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%105 = call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 10)
%106 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%107 = call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11)
%108 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%109 = call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 11)
%110 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%111 = call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 10)
%112 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%113 = call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 9)
%114 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%115 = call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 8)
%116 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%117 = call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 7)
%118 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%119 = call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 6)
%120 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%121 = call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 5)
%122 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%123 = call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 4)
%124 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%125 = call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 3)
%126 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%127 = call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 2)
%128 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
%129 = call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 1)
%130 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.16, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@.str = [13 x i8] c"chet 0x%02X\0A\00"
@.str.1 = [16 x i8] c"~chet 0x%02hhX\0A\00"
@.str.2 = [18 x i8] c"chet >> 1 0x%02X\0A\00"
@.str.3 = [15 x i8] c"nechet 0x%02X\0A\00"
@.str.4 = [18 x i8] c"~nechet 0x%02hhX\0A\00"
@.str.5 = [20 x i8] c"nechet << 1 0x%02X\0A\00"
@.str.6 = [22 x i8] c"chet & nechet 0x%02X\0A\00"
@.str.7 = [22 x i8] c"chet | nechet 0x%02X\0A\00"
@.str.8 = [13 x i8] c"zero 0x%02X\0A\00"
@.str.9 = [16 x i8] c"~zero 0x%02hhX\0A\00"
@.str.10 = [13 x i8] c"full 0x%02X\0A\00"
@.str.11 = [16 x i8] c"~full 0x%02hhX\0A\00"
@.str.12 = [18 x i8] c"full >> 1 0x%02X\0A\00"
@.str.13 = [12 x i8] c"one 0x%02X\0A\00"
@.str.14 = [15 x i8] c"~one 0x%02hhX\0A\00"
@.str.15 = [17 x i8] c"one << 1 0x%02X\0A\00"
@.str.17 = [6 x i8] c"hello\00"
define i32 @main() {
%1 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 170)
%2 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @.str.1, i64 0, i64 0), i32 -171)
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @.str.2, i64 0, i64 0), i32 85)
%4 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @.str.3, i64 0, i64 0), i32 85)
%5 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @.str.4, i64 0, i64 0), i32 -86)
%6 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.5, i64 0, i64 0), i32 170)
%7 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @.str.6, i64 0, i64 0), i32 0)
%8 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @.str.7, i64 0, i64 0), i32 255)
%9 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @.str.8, i64 0, i64 0), i32 0)
%10 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @.str.9, i64 0, i64 0), i32 -1)
%11 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @.str.10, i64 0, i64 0), i32 255)
%12 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @.str.11, i64 0, i64 0), i32 -256)
%13 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @.str.12, i64 0, i64 0), i32 127)
%14 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.13, i64 0, i64 0), i32 1)
%15 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @.str.14, i64 0, i64 0), i32 -2)
%16 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @.str.15, i64 0, i64 0), i32 2)
%17 = tail call i32 @printbinary(i8 zeroext -1)
%18 = tail call i32 @putchar(i32 10)
%19 = tail call i32 @printbinary(i8 zeroext 0)
%20 = tail call i32 @putchar(i32 10)
%21 = tail call i32 @printbinary(i8 zeroext 1)
%22 = tail call i32 @putchar(i32 10)
%23 = tail call i32 @printbinary(i8 zeroext -86)
%24 = tail call i32 @putchar(i32 10)
%25 = tail call i32 @printbinary(i8 zeroext 85)
%26 = tail call i32 @putchar(i32 10)
%27 = tail call i32 @printarbin(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5)
%28 = tail call i32 @putchar(i32 10)
%29 = tail call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 1)
%30 = tail call i32 @putchar(i32 10)
%31 = tail call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 2)
%32 = tail call i32 @putchar(i32 10)
%33 = tail call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 3)
%34 = tail call i32 @putchar(i32 10)
%35 = tail call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 4)
%36 = tail call i32 @putchar(i32 10)
%37 = tail call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 5)
%38 = tail call i32 @putchar(i32 10)
%39 = tail call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 6)
%40 = tail call i32 @putchar(i32 10)
%41 = tail call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 7)
%42 = tail call i32 @putchar(i32 10)
%43 = tail call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 8)
%44 = tail call i32 @putchar(i32 10)
%45 = tail call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 9)
%46 = tail call i32 @putchar(i32 10)
%47 = tail call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 10)
%48 = tail call i32 @putchar(i32 10)
%49 = tail call i32 @shiftarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11)
%50 = tail call i32 @putchar(i32 10)
%51 = tail call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 11)
%52 = tail call i32 @putchar(i32 10)
%53 = tail call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 10)
%54 = tail call i32 @putchar(i32 10)
%55 = tail call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 9)
%56 = tail call i32 @putchar(i32 10)
%57 = tail call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 8)
%58 = tail call i32 @putchar(i32 10)
%59 = tail call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 7)
%60 = tail call i32 @putchar(i32 10)
%61 = tail call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 6)
%62 = tail call i32 @putchar(i32 10)
%63 = tail call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 5)
%64 = tail call i32 @putchar(i32 10)
%65 = tail call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 4)
%66 = tail call i32 @putchar(i32 10)
%67 = tail call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 3)
%68 = tail call i32 @putchar(i32 10)
%69 = tail call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 2)
%70 = tail call i32 @putchar(i32 10)
%71 = tail call i32 @cutarray(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i64 0, i64 0), i32 5, i32 11, i32 1)
%72 = tail call i32 @putchar(i32 10)
ret i32 0
}