#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(void) {
  float hora, value, sal, ir, inss, sd, sb, sl;
  printf("Insira a quantidade que você ganha por hora: \n");
  scanf("%f", &value);
  printf("Insira as horas trabalhadas no mês: \n");
  scanf("%f", &hora);
  sb = value * hora;
  inss = 8 * (sb / 100);
  ir = 11 * (sb / 100);
  sd = 5 * (sb / 100);
  sl = sb - (inss + ir + sd);
  printf("+ Salário Bruto = R$ %.2f\n", sb);
  printf("- INSS(8%) = %.2f\n", inss);
  printf("- IR(11%) = %.2f\n", ir);
  printf("- Sindicato(5%) = %.2f\n", sd);
  printf("= Salário Líquido: R$ %.2f\n", sl);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeda(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xefc(%rip),%rdi
lea    -0xc(%rbp),%rsi
call   1040 <scanf@plt>
lea    0xeef(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xede(%rip),%rdi
lea    -0x8(%rbp),%rsi
call   1040 <scanf@plt>
movss  -0xc(%rbp),%xmm0
mulss  -0x8(%rbp),%xmm0
movss  %xmm0,-0x20(%rbp)
movss  -0x20(%rbp),%xmm1
movss  0xe7d(%rip),%xmm0
divss  %xmm0,%xmm1
movss  0xe79(%rip),%xmm0
mulss  %xmm1,%xmm0
movss  %xmm0,-0x18(%rbp)
movss  -0x20(%rbp),%xmm1
movss  0xe5b(%rip),%xmm0
divss  %xmm0,%xmm1
movss  0xe53(%rip),%xmm0
mulss  %xmm1,%xmm0
movss  %xmm0,-0x14(%rbp)
movss  -0x20(%rbp),%xmm1
movss  0xe39(%rip),%xmm0
divss  %xmm0,%xmm1
movss  0xe29(%rip),%xmm0
mulss  %xmm1,%xmm0
movss  %xmm0,-0x1c(%rbp)
movss  -0x20(%rbp),%xmm0
movss  -0x18(%rbp),%xmm1
addss  -0x14(%rbp),%xmm1
addss  -0x1c(%rbp),%xmm1
subss  %xmm1,%xmm0
movss  %xmm0,-0x24(%rbp)
movss  -0x20(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xe5d(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
movss  -0x18(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xe62(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
movss  -0x14(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xe5e(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
movss  -0x1c(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xe59(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
movss  -0x24(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xe5a(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x20,%rsp
lea    0xf4e(%rip),%rdi
call   1030 <puts@plt>
lea    0xec8(%rip),%rbx
lea    0x18(%rsp),%rsi
mov    %rbx,%rdi
call   1050 <scanf@plt>
lea    0xf5d(%rip),%rdi
call   1030 <puts@plt>
lea    0x1c(%rsp),%rsi
mov    %rbx,%rdi
call   1050 <scanf@plt>
movss  0x18(%rsp),%xmm0
mulss  0x1c(%rsp),%xmm0
movaps %xmm0,%xmm3
movaps %xmm0,%xmm2
divss  0xe78(%rip),%xmm3
movss  0xe74(%rip),%xmm1
mulss  %xmm3,%xmm1
movss  %xmm1,0x8(%rsp)
movss  0xe66(%rip),%xmm0
mulss  %xmm3,%xmm0
movss  %xmm0,0xc(%rsp)
mulss  0xe58(%rip),%xmm3
movss  %xmm3,0x10(%rsp)
addss  %xmm0,%xmm1
addss  %xmm3,%xmm1
xorps  %xmm0,%xmm0
cvtss2sd %xmm2,%xmm0
subss  %xmm1,%xmm2
movss  %xmm2,0x14(%rsp)
lea    0xe39(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
movss  0x8(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xe3d(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
movss  0xc(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xe38(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
movss  0x10(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xe32(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
movss  0x14(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xe32(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [48 x i8] c"Insira a quantidade que voc\C3\AA ganha por hora: \0A\00"
@.str.1 = [3 x i8] c"%f\00"
@.str.2 = [39 x i8] c"Insira as horas trabalhadas no m\C3\AAs: \0A\00"
@.str.3 = [28 x i8] c"+ Sal\C3\A1rio Bruto = R$ %.2f\0A\00"
@.str.4 = [19 x i8] c"- INSS(8%) = %.2f\0A\00"
@.str.5 = [18 x i8] c"- IR(11%) = %.2f\0A\00"
@.str.6 = [24 x i8] c"- Sindicato(5%) = %.2f\0A\00"
@.str.7 = [30 x i8] c"= Sal\C3\A1rio L\C3\ADquido: R$ %.2f\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca float
%3 = alloca float
%4 = alloca float
%5 = alloca float
%6 = alloca float
%7 = alloca float
%8 = alloca float
%9 = alloca float
store i32 0, i32* %1
%10 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str, i64 0, i64 0))
%11 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %3)
%12 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.2, i64 0, i64 0))
%13 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %2)
%14 = load float, float* %3
%15 = load float, float* %2
%16 = fmul float %14, %15
store float %16, float* %8
%17 = load float, float* %8
%18 = fdiv float %17, 1.000000e+02
%19 = fmul float 8.000000e+00, %18
store float %19, float* %6
%20 = load float, float* %8
%21 = fdiv float %20, 1.000000e+02
%22 = fmul float 1.100000e+01, %21
store float %22, float* %5
%23 = load float, float* %8
%24 = fdiv float %23, 1.000000e+02
%25 = fmul float 5.000000e+00, %24
store float %25, float* %7
%26 = load float, float* %8
%27 = load float, float* %6
%28 = load float, float* %5
%29 = fadd float %27, %28
%30 = load float, float* %7
%31 = fadd float %29, %30
%32 = fsub float %26, %31
store float %32, float* %9
%33 = load float, float* %8
%34 = fpext float %33 to double
%35 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.3, i64 0, i64 0), double %34)
%36 = load float, float* %6
%37 = fpext float %36 to double
%38 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0), double %37)
%39 = load float, float* %5
%40 = fpext float %39 to double
%41 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.5, i64 0, i64 0), double %40)
%42 = load float, float* %7
%43 = fpext float %42 to double
%44 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.6, i64 0, i64 0), double %43)
%45 = load float, float* %9
%46 = fpext float %45 to double
%47 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.7, i64 0, i64 0), double %46)
ret i32 0
}

LLVM IR (-O2):
@.str.1 = [3 x i8] c"%f\00"
@.str.3 = [28 x i8] c"+ Sal\C3\A1rio Bruto = R$ %.2f\0A\00"
@.str.4 = [19 x i8] c"- INSS(8%) = %.2f\0A\00"
@.str.5 = [18 x i8] c"- IR(11%) = %.2f\0A\00"
@.str.6 = [24 x i8] c"- Sindicato(5%) = %.2f\0A\00"
@.str.7 = [30 x i8] c"= Sal\C3\A1rio L\C3\ADquido: R$ %.2f\0A\00"
@str = [47 x i8] c"Insira a quantidade que voc\C3\AA ganha por hora: \00"
@str.8 = [38 x i8] c"Insira as horas trabalhadas no m\C3\AAs: \00"
define i32 @main() {
%1 = alloca float
%2 = alloca float
%3 = bitcast float* %1 to i8*
%4 = bitcast float* %2 to i8*
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([47 x i8], [47 x i8]* @str, i64 0, i64 0))
%6 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %2)
%7 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([38 x i8], [38 x i8]* @str.8, i64 0, i64 0))
%8 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %1)
%9 = load float, float* %2
%10 = load float, float* %1
%11 = fmul float %9, %10
%12 = fdiv float %11, 1.000000e+02
%13 = fmul float %12, 8.000000e+00
%14 = fmul float %12, 1.100000e+01
%15 = fmul float %12, 5.000000e+00
%16 = fadd float %13, %14
%17 = fadd float %15, %16
%18 = fsub float %11, %17
%19 = fpext float %11 to double
%20 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([28 x i8], [28 x i8]* @.str.3, i64 0, i64 0), double %19)
%21 = fpext float %13 to double
%22 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0), double %21)
%23 = fpext float %14 to double
%24 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @.str.5, i64 0, i64 0), double %23)
%25 = fpext float %15 to double
%26 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([24 x i8], [24 x i8]* @.str.6, i64 0, i64 0), double %25)
%27 = fpext float %18 to double
%28 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([30 x i8], [30 x i8]* @.str.7, i64 0, i64 0), double %27)
ret i32 0
}