#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 /*<<< orphan*/ scanf(char *, float *);
int main() {
  float hora;
  printf("Insira as horas formatada 0.00: ");
  scanf("%f", &hora);
  float min = hora;
  hora = (int)hora;
  min = (min - hora) * 100;
  hora = hora * 60 + min;
  printf("%2.0f minutos", hora);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    0xed9(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xeec(%rip),%rdi
lea    -0x4(%rbp),%rsi
call   1040 <scanf@plt>
movss  -0x4(%rbp),%xmm0
movss  %xmm0,-0x8(%rbp)
cvttss2si -0x4(%rbp),%eax
cvtsi2ss %eax,%xmm0
movss  %xmm0,-0x4(%rbp)
movss  -0x8(%rbp),%xmm0
subss  -0x4(%rbp),%xmm0
movss  0xe94(%rip),%xmm1
mulss  %xmm1,%xmm0
movss  %xmm0,-0x8(%rbp)
movss  -0x4(%rbp),%xmm0
movss  -0x8(%rbp),%xmm1
movss  0xe75(%rip),%xmm2
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xe84(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xee0(%rip),%rdi
xor    %eax,%eax
call   1030 <printf@plt>
lea    0xef3(%rip),%rdi
lea    0x4(%rsp),%rsi
call   1040 <scanf@plt>
movss  0x4(%rsp),%xmm0
cvttps2dq %xmm0,%xmm1
cvtdq2ps %xmm1,%xmm1
subss  %xmm1,%xmm0
mulss  0xea7(%rip),%xmm0
mulss  0xea3(%rip),%xmm1
addss  %xmm0,%xmm1
movss  %xmm1,0x4(%rsp)
xorps  %xmm0,%xmm0
cvtss2sd %xmm1,%xmm0
lea    0xeb3(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [33 x i8] c"Insira as horas formatada 0.00: \00"
@.str.1 = [3 x i8] c"%f\00"
@.str.2 = [14 x i8] c"%2.0f minutos\00"
define i32 @main() {
%1 = alloca float
%2 = alloca float
%3 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str, i64 0, i64 0))
%4 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %1)
%5 = load float, float* %1
store float %5, float* %2
%6 = load float, float* %1
%7 = fptosi float %6 to i32
%8 = sitofp i32 %7 to float
store float %8, float* %1
%9 = load float, float* %2
%10 = load float, float* %1
%11 = fsub float %9, %10
%12 = fmul float %11, 1.000000e+02
store float %12, float* %2
%13 = load float, float* %1
%14 = load float, float* %2
%15 = call float @llvm.fmuladd.f32(float %13, float 6.000000e+01, float %14)
store float %15, float* %1
%16 = load float, float* %1
%17 = fpext float %16 to double
%18 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.2, i64 0, i64 0), double %17)
ret i32 0
}

LLVM IR (-O2):
@.str = [33 x i8] c"Insira as horas formatada 0.00: \00"
@.str.1 = [3 x i8] c"%f\00"
@.str.2 = [14 x i8] c"%2.0f minutos\00"
define i32 @main() {
%1 = alloca float
%2 = bitcast float* %1 to i8*
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([33 x i8], [33 x i8]* @.str, i64 0, i64 0))
%4 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %1)
%5 = load float, float* %1
%6 = fptosi float %5 to i32
%7 = sitofp i32 %6 to float
%8 = fsub float %5, %7
%9 = fmul float %8, 1.000000e+02
%10 = call float @llvm.fmuladd.f32(float %7, float 6.000000e+01, float %9)
store float %10, float* %1
%11 = fpext float %10 to double
%12 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @.str.2, i64 0, i64 0), double %11)
ret i32 0
}