#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 *);
void main() {
  float sueldo;
  printf("Ingrese su salario\n");
  scanf("%f", &sueldo);
  if (sueldo < 6000) {
    sueldo = sueldo + sueldo * .10;
  } else {
    sueldo = sueldo + sueldo * .05;
  }
  printf("Su sueldo final sera: %.2f\n", sueldo);
  return;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    0xee9(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xeef(%rip),%rdi
lea    -0x4(%rbp),%rsi
call   1040 <scanf@plt>
movss  0xeb2(%rip),%xmm0
ucomiss -0x4(%rbp),%xmm0
jbe    1188 <main+0x68>
movss  -0x4(%rbp),%xmm0
cvtss2sd %xmm0,%xmm1
movss  -0x4(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xe9e(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0x4(%rbp)
jmp    11b3 <main+0x93>
movss  -0x4(%rbp),%xmm0
cvtss2sd %xmm0,%xmm1
movss  -0x4(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xe66(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xe6c(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xeff(%rip),%rdi
call   1030 <puts@plt>
lea    0xed4(%rip),%rdi
lea    0x4(%rsp),%rsi
call   1050 <scanf@plt>
movss  0x4(%rsp),%xmm0
movss  0xea4(%rip),%xmm1
xor    %eax,%eax
ucomiss %xmm0,%xmm1
seta   %al
cvtss2sd %xmm0,%xmm0
lea    0xe99(%rip),%rcx
movsd  (%rcx,%rax,8),%xmm1
mulsd  %xmm0,%xmm1
addsd  %xmm0,%xmm1
xorps  %xmm0,%xmm0
cvtsd2ss %xmm1,%xmm0
movss  %xmm0,0x4(%rsp)
cvtss2sd %xmm0,%xmm0
lea    0xe87(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
pop    %rax
ret

LLVM IR (-O0):
@.str = [20 x i8] c"Ingrese su salario\0A\00"
@.str.1 = [3 x i8] c"%f\00"
@.str.2 = [28 x i8] c"Su sueldo final sera: %.2f\0A\00"
define void @main() {
%1 = alloca float
%2 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str, i64 0, i64 0))
%3 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %1)
%4 = load float, float* %1
%5 = fcmp olt float %4, 6.000000e+03
br i1 %5, label %6, label %13
6: ; preds = %0
%7 = load float, float* %1
%8 = fpext float %7 to double
%9 = load float, float* %1
%10 = fpext float %9 to double
%11 = call double @llvm.fmuladd.f64(double %10, double 1.000000e-01, double %8)
%12 = fptrunc double %11 to float
store float %12, float* %1
br label %20
13: ; preds = %0
%14 = load float, float* %1
%15 = fpext float %14 to double
%16 = load float, float* %1
%17 = fpext float %16 to double
%18 = call double @llvm.fmuladd.f64(double %17, double 5.000000e-02, double %15)
%19 = fptrunc double %18 to float
store float %19, float* %1
br label %20
20: ; preds = %13, %6
%21 = load float, float* %1
%22 = fpext float %21 to double
%23 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.2, i64 0, i64 0), double %22)
ret void
}

LLVM IR (-O2):
@.str.1 = [3 x i8] c"%f\00"
@.str.2 = [28 x i8] c"Su sueldo final sera: %.2f\0A\00"
@str = [19 x i8] c"Ingrese su salario\00"
define void @main() {
%1 = alloca float
%2 = bitcast float* %1 to i8*
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 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 = fcmp olt float %5, 6.000000e+03
%7 = fpext float %5 to double
%8 = call double @llvm.fmuladd.f64(double %7, double 5.000000e-02, double %7)
%9 = call double @llvm.fmuladd.f64(double %7, double 1.000000e-01, double %7)
%10 = select i1 %6, double %9, double %8
%11 = fptrunc double %10 to float
store float %11, float* %1
%12 = fpext float %11 to double
%13 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([28 x i8], [28 x i8]* @.str.2, i64 0, i64 0), double %12)
ret void
}