void transfer_RGBA8888_to_RGBA_FLOAT(float *(*output), unsigned char *input) {
  *(*output)++ = (float)*input++ / 0xff;
  *(*output)++ = (float)*input++ / 0xff;
  *(*output)++ = (float)*input++ / 0xff;
  *(*output)++ = (float)*input / 0xff;
}


x86 assembly (clang, -O0):
<transfer_RGBA8888_to_RGBA_FLOAT>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x10(%rbp)
movzbl (%rax),%eax
cvtsi2ss %eax,%xmm0
movss  0xed6(%rip),%xmm1
divss  %xmm1,%xmm0
mov    -0x8(%rbp),%rcx
mov    (%rcx),%rax
mov    %rax,%rdx
add    $0x4,%rdx
mov    %rdx,(%rcx)
movss  %xmm0,(%rax)
mov    -0x10(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x10(%rbp)
movzbl (%rax),%eax
cvtsi2ss %eax,%xmm0
divss  %xmm1,%xmm0
mov    -0x8(%rbp),%rcx
mov    (%rcx),%rax
mov    %rax,%rdx
add    $0x4,%rdx
mov    %rdx,(%rcx)
movss  %xmm0,(%rax)
mov    -0x10(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x10(%rbp)
movzbl (%rax),%eax
cvtsi2ss %eax,%xmm0
divss  %xmm1,%xmm0
mov    -0x8(%rbp),%rcx
mov    (%rcx),%rax
mov    %rax,%rdx
add    $0x4,%rdx
mov    %rdx,(%rcx)
movss  %xmm0,(%rax)
mov    -0x10(%rbp),%rax
movzbl (%rax),%eax
cvtsi2ss %eax,%xmm0
movss  0xe4c(%rip),%xmm1
divss  %xmm1,%xmm0
mov    -0x8(%rbp),%rcx
mov    (%rcx),%rax
mov    %rax,%rdx
add    $0x4,%rdx
mov    %rdx,(%rcx)
movss  %xmm0,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<transfer_RGBA8888_to_RGBA_FLOAT>:
movzbl (%rsi),%eax
cvtsi2ss %eax,%xmm0
movss  0xef1(%rip),%xmm1
divss  %xmm1,%xmm0
mov    (%rdi),%rax
lea    0x4(%rax),%rcx
mov    %rcx,(%rdi)
movss  %xmm0,(%rax)
movzbl 0x1(%rsi),%ecx
xorps  %xmm0,%xmm0
cvtsi2ss %ecx,%xmm0
divss  %xmm1,%xmm0
lea    0x8(%rax),%rcx
mov    %rcx,(%rdi)
movss  %xmm0,0x4(%rax)
movzbl 0x2(%rsi),%ecx
xorps  %xmm0,%xmm0
cvtsi2ss %ecx,%xmm0
divss  %xmm1,%xmm0
lea    0xc(%rax),%rcx
mov    %rcx,(%rdi)
movss  %xmm0,0x8(%rax)
movzbl 0x3(%rsi),%ecx
xorps  %xmm0,%xmm0
cvtsi2ss %ecx,%xmm0
divss  %xmm1,%xmm0
lea    0x10(%rax),%rcx
mov    %rcx,(%rdi)
movss  %xmm0,0xc(%rax)
ret

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

LLVM IR (-O2):
define void @transfer_RGBA8888_to_RGBA_FLOAT(float** nocapture %0, i8* nocapture %1) {
%3 = getelementptr inbounds i8, i8* %1, i64 1
%4 = load i8, i8* %1
%5 = uitofp i8 %4 to float
%6 = fdiv float %5, 2.550000e+02
%7 = load float*, float** %0
%8 = getelementptr inbounds float, float* %7, i64 1
store float* %8, float** %0
store float %6, float* %7
%9 = getelementptr inbounds i8, i8* %1, i64 2
%10 = load i8, i8* %3
%11 = uitofp i8 %10 to float
%12 = fdiv float %11, 2.550000e+02
%13 = getelementptr inbounds float, float* %7, i64 2
store float* %13, float** %0
store float %12, float* %8
%14 = getelementptr inbounds i8, i8* %1, i64 3
%15 = load i8, i8* %9
%16 = uitofp i8 %15 to float
%17 = fdiv float %16, 2.550000e+02
%18 = getelementptr inbounds float, float* %7, i64 3
store float* %18, float** %0
store float %17, float* %13
%19 = load i8, i8* %14
%20 = uitofp i8 %19 to float
%21 = fdiv float %20, 2.550000e+02
%22 = getelementptr inbounds float, float* %7, i64 4
store float* %22, float** %0
store float %21, float* %18
ret void
}