#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*/ printf(char *, int);
int /*<<< orphan*/ scanf(char *, int *, int *);
int main() {
  int x, y;
  scanf("%d %d", &x, &y);
  while (x != y) {
    printf("%d ", x);
    if (x > y) {
      x--;
    } else {
      x++;
    }
  }
  printf("%d", x);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeca(%rip),%rdi
lea    -0x8(%rbp),%rsi
lea    -0xc(%rbp),%rdx
call   1040 <scanf@plt>
mov    -0x8(%rbp),%eax
cmp    -0xc(%rbp),%eax
je     1186 <main+0x66>
mov    -0x8(%rbp),%esi
lea    0xead(%rip),%rdi
call   1030 <printf@plt>
mov    -0x8(%rbp),%eax
cmp    -0xc(%rbp),%eax
jle    1178 <main+0x58>
mov    -0x8(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x8(%rbp)
jmp    1181 <main+0x61>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1143 <main+0x23>
mov    -0x8(%rbp),%esi
lea    0xe73(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x10,%rsp
lea    0xed4(%rip),%rdi
lea    0x8(%rsp),%rsi
lea    0xc(%rsp),%rdx
call   1040 <scanf@plt>
mov    0x8(%rsp),%eax
cmp    0xc(%rsp),%eax
jne    1149 <main+0x29>
mov    %eax,%esi
jmp    1177 <main+0x57>
lea    0xeb6(%rip),%rbx
mov    %rbx,%rdi
mov    %eax,%esi
call   1030 <printf@plt>
mov    0x8(%rsp),%eax
mov    0xc(%rsp),%esi
xor    %ecx,%ecx
cmp    %esi,%eax
setle  %cl
lea    (%rax,%rcx,2),%eax
add    $0xffffffff,%eax
mov    %eax,0x8(%rsp)
cmp    %esi,%eax
jne    1150 <main+0x30>
lea    0xe85(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [6 x i8] c"%d %d\00"
@.str.1 = [4 x i8] c"%d \00"
@.str.2 = [3 x i8] c"%d\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
store i32 0, i32* %1
%4 = call i32 @scanf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32* %2, i32* %3)
br label %5
5: ; preds = %21, %0
%6 = load i32, i32* %2
%7 = load i32, i32* %3
%8 = icmp ne i32 %6, %7
br i1 %8, label %9, label %22
9: ; preds = %5
%10 = load i32, i32* %2
%11 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %10)
%12 = load i32, i32* %2
%13 = load i32, i32* %3
%14 = icmp sgt i32 %12, %13
br i1 %14, label %15, label %18
15: ; preds = %9
%16 = load i32, i32* %2
%17 = add nsw i32 %16, -1
store i32 %17, i32* %2
br label %21
18: ; preds = %9
%19 = load i32, i32* %2
%20 = add nsw i32 %19, 1
store i32 %20, i32* %2
br label %21
21: ; preds = %18, %15
br label %5
22: ; preds = %5
%23 = load i32, i32* %2
%24 = call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32 %23)
ret i32 0
}

LLVM IR (-O2):
@.str = [6 x i8] c"%d %d\00"
@.str.1 = [4 x i8] c"%d \00"
@.str.2 = [3 x i8] c"%d\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = bitcast i32* %1 to i8*
%4 = bitcast i32* %2 to i8*
%5 = call i32 @scanf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32* %1, i32* %2)
%6 = load i32, i32* %1
%7 = load i32, i32* %2
%8 = icmp eq i32 %6, %7
br i1 %8, label %18, label %9
9: ; preds = %0, %9
%10 = phi i32 [ %16, %9 ], [ %6, %0 ]
%11 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %10)
%12 = load i32, i32* %1
%13 = load i32, i32* %2
%14 = icmp sgt i32 %12, %13
%15 = select i1 %14, i32 -1, i32 1
%16 = add nsw i32 %15, %12
store i32 %16, i32* %1
%17 = icmp eq i32 %16, %13
br i1 %17, label %18, label %9
18: ; preds = %9, %0
%19 = phi i32 [ %6, %0 ], [ %13, %9 ]
%20 = call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32 %19)
ret i32 0
}