#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 */
unsigned char lighten(unsigned char, float);
void lightencolor(int *col, float power) {
  unsigned char *color;
  color = (unsigned char *)col;
  *color = lighten(*color, power);
  color++;
  *color = lighten(*color, power);
  color++;
  *color = lighten(*color, power);
  color++;
  *color = lighten(*color, power);
}


x86 assembly (clang, -O0):
<lightencolor>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
movss  %xmm0,-0xc(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
mov    (%rax),%al
movss  -0xc(%rbp),%xmm0
movzbl %al,%edi
call   1030 <lighten@plt>
mov    %al,%cl
mov    -0x18(%rbp),%rax
mov    %cl,(%rax)
mov    -0x18(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
mov    (%rax),%al
movss  -0xc(%rbp),%xmm0
movzbl %al,%edi
call   1030 <lighten@plt>
mov    %al,%cl
mov    -0x18(%rbp),%rax
mov    %cl,(%rax)
mov    -0x18(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
mov    (%rax),%al
movss  -0xc(%rbp),%xmm0
movzbl %al,%edi
call   1030 <lighten@plt>
mov    %al,%cl
mov    -0x18(%rbp),%rax
mov    %cl,(%rax)
mov    -0x18(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
mov    (%rax),%al
movss  -0xc(%rbp),%xmm0
movzbl %al,%edi
call   1030 <lighten@plt>
mov    %al,%cl
mov    -0x18(%rbp),%rax
mov    %cl,(%rax)
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<lightencolor>:
push   %rbx
sub    $0x10,%rsp
movss  %xmm0,0xc(%rsp)
mov    %rdi,%rbx
movzbl (%rdi),%edi
call   1030 <lighten@plt>
mov    %al,(%rbx)
movzbl 0x1(%rbx),%edi
movss  0xc(%rsp),%xmm0
call   1030 <lighten@plt>
mov    %al,0x1(%rbx)
movzbl 0x2(%rbx),%edi
movss  0xc(%rsp),%xmm0
call   1030 <lighten@plt>
mov    %al,0x2(%rbx)
movzbl 0x3(%rbx),%edi
movss  0xc(%rsp),%xmm0
call   1030 <lighten@plt>
mov    %al,0x3(%rbx)
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
define void @lightencolor(i32* %0, float %1) {
%3 = alloca i32*
%4 = alloca float
%5 = alloca i8*
store i32* %0, i32** %3
store float %1, float* %4
%6 = load i32*, i32** %3
%7 = bitcast i32* %6 to i8*
store i8* %7, i8** %5
%8 = load i8*, i8** %5
%9 = load i8, i8* %8
%10 = load float, float* %4
%11 = call zeroext i8 @lighten(i8 zeroext %9, float %10)
%12 = load i8*, i8** %5
store i8 %11, i8* %12
%13 = load i8*, i8** %5
%14 = getelementptr inbounds i8, i8* %13, i32 1
store i8* %14, i8** %5
%15 = load i8*, i8** %5
%16 = load i8, i8* %15
%17 = load float, float* %4
%18 = call zeroext i8 @lighten(i8 zeroext %16, float %17)
%19 = load i8*, i8** %5
store i8 %18, i8* %19
%20 = load i8*, i8** %5
%21 = getelementptr inbounds i8, i8* %20, i32 1
store i8* %21, i8** %5
%22 = load i8*, i8** %5
%23 = load i8, i8* %22
%24 = load float, float* %4
%25 = call zeroext i8 @lighten(i8 zeroext %23, float %24)
%26 = load i8*, i8** %5
store i8 %25, i8* %26
%27 = load i8*, i8** %5
%28 = getelementptr inbounds i8, i8* %27, i32 1
store i8* %28, i8** %5
%29 = load i8*, i8** %5
%30 = load i8, i8* %29
%31 = load float, float* %4
%32 = call zeroext i8 @lighten(i8 zeroext %30, float %31)
%33 = load i8*, i8** %5
store i8 %32, i8* %33
ret void
}

LLVM IR (-O2):
define void @lightencolor(i32* nocapture %0, float %1) {
%3 = bitcast i32* %0 to i8*
%4 = load i8, i8* %3
%5 = tail call zeroext i8 @lighten(i8 zeroext %4, float %1)
store i8 %5, i8* %3
%6 = getelementptr inbounds i8, i8* %3, i64 1
%7 = load i8, i8* %6
%8 = tail call zeroext i8 @lighten(i8 zeroext %7, float %1)
store i8 %8, i8* %6
%9 = getelementptr inbounds i8, i8* %3, i64 2
%10 = load i8, i8* %9
%11 = tail call zeroext i8 @lighten(i8 zeroext %10, float %1)
store i8 %11, i8* %9
%12 = getelementptr inbounds i8, i8* %3, i64 3
%13 = load i8, i8* %12
%14 = tail call zeroext i8 @lighten(i8 zeroext %13, float %1)
store i8 %14, i8* %12
ret void
}