#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 */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int /*<<< orphan*/ fclose(int /*<<< orphan*/ *);
int /*<<< orphan*/ *fopen(char *, char *);
int /*<<< orphan*/ fscanf(int /*<<< orphan*/ *, char *, ...);
double pow(double, int);
int /*<<< orphan*/ printf(char *, int);
int main() {
  FILE *fin = fopen("heart.in", "r");
  int times, t;
  fscanf(fin, "%d", &times);
  for (t = 1; t <= times; t++) {
    double x, y;
    fscanf(fin, "%lf %lf", &x, &y);
    double inequality = pow(x * x + y * y - 1, 3.) - x * x * y * y * y;
    if (inequality < 0) {
      printf("Point #%d: You give love a bad name.\n", t);
    } else {
      printf("Point #%d: Let it rock!\n", t);
    }
  }
  fclose(fin);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xea2(%rip),%rdi
lea    0xea4(%rip),%rsi
call   1060 <fopen@plt>
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
lea    0xe92(%rip),%rsi
lea    -0x14(%rbp),%rdx
mov    $0x0,%al
call   1050 <fscanf@plt>
movl   $0x1,-0x18(%rbp)
mov    -0x18(%rbp),%eax
cmp    -0x14(%rbp),%eax
jg     126f <main+0x11f>
mov    -0x10(%rbp),%rdi
lea    0xe6c(%rip),%rsi
lea    -0x20(%rbp),%rdx
lea    -0x28(%rbp),%rcx
mov    $0x0,%al
call   1050 <fscanf@plt>
movsd  -0x20(%rbp),%xmm0
movsd  -0x20(%rbp),%xmm2
movsd  -0x28(%rbp),%xmm1
mulsd  -0x28(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  0xe23(%rip),%xmm1
subsd  %xmm1,%xmm0
mov    $0x3,%edi
call   1070 <pow@plt>
movaps %xmm0,%xmm1
movsd  -0x20(%rbp),%xmm0
mulsd  -0x20(%rbp),%xmm0
mulsd  -0x28(%rbp),%xmm0
mulsd  -0x28(%rbp),%xmm0
movsd  -0x28(%rbp),%xmm2
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x30(%rbp)
xorps  %xmm0,%xmm0
ucomisd -0x30(%rbp),%xmm0
jbe    124d <main+0xfd>
mov    -0x18(%rbp),%esi
lea    0xddb(%rip),%rdi
call   1040 <printf@plt>
jmp    125c <main+0x10c>
mov    -0x18(%rbp),%esi
lea    0xded(%rip),%rdi
call   1040 <printf@plt>
jmp    1261 <main+0x111>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
jmp    1193 <main+0x43>
mov    -0x10(%rbp),%rdi
call   1030 <fclose@plt>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
lea    0xeab(%rip),%rdi
lea    0xead(%rip),%rsi
call   1060 <fopen@plt>
mov    %rax,%r15
lea    0xea0(%rip),%rsi
lea    0x4(%rsp),%rdx
mov    %rax,%rdi
xor    %eax,%eax
call   1050 <fscanf@plt>
cmpl   $0x0,0x4(%rsp)
jle    1248 <main+0xf8>
mov    $0x1,%ebx
lea    0xe7d(%rip),%r14
lea    0x10(%rsp),%r12
lea    0x8(%rsp),%r13
lea    0xe74(%rip),%rbp
jmp    11d2 <main+0x82>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
mov    %ebx,%esi
call   1040 <printf@plt>
lea    0x1(%rbx),%eax
cmp    0x4(%rsp),%ebx
mov    %eax,%ebx
jge    1248 <main+0xf8>
mov    %r15,%rdi
mov    %r14,%rsi
mov    %r12,%rdx
mov    %r13,%rcx
xor    %eax,%eax
call   1050 <fscanf@plt>
movsd  0x10(%rsp),%xmm0
movsd  0x8(%rsp),%xmm1
mulsd  %xmm1,%xmm1
mulsd  %xmm0,%xmm0
addsd  %xmm1,%xmm0
addsd  0xdfb(%rip),%xmm0
mov    $0x3,%edi
call   1070 <pow@plt>
movsd  0x10(%rsp),%xmm1
movsd  0x8(%rsp),%xmm2
mulsd  %xmm1,%xmm1
mulsd  %xmm2,%xmm1
mulsd  %xmm2,%xmm1
mulsd  %xmm2,%xmm1
subsd  %xmm1,%xmm0
xorpd  %xmm1,%xmm1
ucomisd %xmm0,%xmm1
mov    %rbp,%rdi
ja     11c0 <main+0x70>
lea    0xe09(%rip),%rdi
jmp    11c0 <main+0x70>
mov    %r15,%rdi
call   1030 <fclose@plt>
xor    %eax,%eax
add    $0x18,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [9 x i8] c"heart.in\00"
@.str.1 = [2 x i8] c"r\00"
@.str.2 = [3 x i8] c"%d\00"
@.str.3 = [8 x i8] c"%lf %lf\00"
@.str.4 = [38 x i8] c"Point #%d: You give love a bad name.\0A\00"
@.str.5 = [25 x i8] c"Point #%d: Let it rock!\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32*
%3 = alloca i32
%4 = alloca i32
%5 = alloca double
%6 = alloca double
%7 = alloca double
store i32 0, i32* %1
%8 = call i32* @fopen(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store i32* %8, i32** %2
%9 = load i32*, i32** %2
%10 = call i32 (i32*, i8*, ...) @fscanf(i32* %9, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32* %3)
store i32 1, i32* %4
br label %11
11: ; preds = %45, %0
%12 = load i32, i32* %4
%13 = load i32, i32* %3
%14 = icmp sle i32 %12, %13
br i1 %14, label %15, label %48
15: ; preds = %11
%16 = load i32*, i32** %2
%17 = call i32 (i32*, i8*, ...) @fscanf(i32* %16, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.3, i64 0, i64 0), double* %5, double* %6)
%18 = load double, double* %5
%19 = load double, double* %5
%20 = load double, double* %6
%21 = load double, double* %6
%22 = fmul double %20, %21
%23 = call double @llvm.fmuladd.f64(double %18, double %19, double %22)
%24 = fsub double %23, 1.000000e+00
%25 = call double @pow(double %24, i32 3)
%26 = load double, double* %5
%27 = load double, double* %5
%28 = fmul double %26, %27
%29 = load double, double* %6
%30 = fmul double %28, %29
%31 = load double, double* %6
%32 = fmul double %30, %31
%33 = load double, double* %6
%34 = fneg double %32
%35 = call double @llvm.fmuladd.f64(double %34, double %33, double %25)
store double %35, double* %7
%36 = load double, double* %7
%37 = fcmp olt double %36, 0.000000e+00
br i1 %37, label %38, label %41
38: ; preds = %15
%39 = load i32, i32* %4
%40 = call i32 @printf(i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str.4, i64 0, i64 0), i32 %39)
br label %44
41: ; preds = %15
%42 = load i32, i32* %4
%43 = call i32 @printf(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.5, i64 0, i64 0), i32 %42)
br label %44
44: ; preds = %41, %38
br label %45
45: ; preds = %44
%46 = load i32, i32* %4
%47 = add nsw i32 %46, 1
store i32 %47, i32* %4
br label %11
48: ; preds = %11
%49 = load i32*, i32** %2
%50 = call i32 @fclose(i32* %49)
ret i32 0
}

LLVM IR (-O2):
@.str = [9 x i8] c"heart.in\00"
@.str.1 = [2 x i8] c"r\00"
@.str.2 = [3 x i8] c"%d\00"
@.str.3 = [8 x i8] c"%lf %lf\00"
@.str.4 = [38 x i8] c"Point #%d: You give love a bad name.\0A\00"
@.str.5 = [25 x i8] c"Point #%d: Let it rock!\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca double
%3 = alloca double
%4 = tail call i32* @fopen(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%5 = bitcast i32* %1 to i8*
%6 = call i32 (i32*, i8*, ...) @fscanf(i32* %4, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32* %1)
%7 = load i32, i32* %1
%8 = icmp slt i32 %7, 1
br i1 %8, label %34, label %9
9: ; preds = %0
%10 = bitcast double* %2 to i8*
%11 = bitcast double* %3 to i8*
br label %12
12: ; preds = %9, %12
%13 = phi i32 [ 1, %9 ], [ %31, %12 ]
%14 = call i32 (i32*, i8*, ...) @fscanf(i32* %4, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.3, i64 0, i64 0), double* %2, double* %3)
%15 = load double, double* %2
%16 = load double, double* %3
%17 = fmul double %16, %16
%18 = call double @llvm.fmuladd.f64(double %15, double %15, double %17)
%19 = fadd double %18, -1.000000e+00
%20 = call double @pow(double %19, i32 3)
%21 = load double, double* %2
%22 = load double, double* %3
%23 = fneg double %21
%24 = fmul double %21, %23
%25 = fmul double %24, %22
%26 = fmul double %22, %25
%27 = call double @llvm.fmuladd.f64(double %26, double %22, double %20)
%28 = fcmp olt double %27, 0.000000e+00
%29 = select i1 %28, i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.5, i64 0, i64 0)
%30 = call i32 @printf(i8* %29, i32 %13)
%31 = add nuw nsw i32 %13, 1
%32 = load i32, i32* %1
%33 = icmp slt i32 %13, %32
br i1 %33, label %12, label %34
34: ; preds = %12, %0
%35 = call i32 @fclose(i32* %4)
ret i32 0
}