#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 convert_units_from_THz(double *, char const *);
int convert_units_from_eV(double *, char const *);
int convert_units_from_um(double *, char const *);
scalar_t__ strcmp(char const *, char const *);
int convert_units(double *value, const char *from_units, const char *to_units) {
  if (NULL == value) {
    return -1;
  }
  if (NULL == from_units) {
    return -2;
  }
  if (NULL == to_units) {
    return -3;
  }
  if (0 == strcmp(from_units, to_units)) {
    return 0;
  } else if (0 == strcmp(from_units, "um")) {
    return convert_units_from_um(value, to_units);
  } else if (0 == strcmp(from_units, "nm")) {
    *value *= 1e-3;
    return convert_units_from_um(value, to_units);
  } else if (0 == strcmp(from_units, "m")) {
    *value *= 1e6;
    return convert_units_from_um(value, to_units);
  } else if (0 == strcmp(from_units, "cm")) {
    *value *= 1e4;
    return convert_units_from_um(value, to_units);
  } else if (0 == strcmp(from_units, "mm")) {
    *value *= 1e3;
    return convert_units_from_um(value, to_units);
  } else if (0 == strcmp(from_units, "eV")) {
    return convert_units_from_eV(value, to_units);
  } else if (0 == strcmp(from_units, "J")) {
    *value *= 6.241506363094027e18;
    return convert_units_from_eV(value, to_units);
  } else if (0 == strcmp(from_units, "THz")) {
    return convert_units_from_THz(value, to_units);
  } else if (0 == strcmp(from_units, "GHz")) {
    *value *= 1e-3;
    return convert_units_from_THz(value, to_units);
  } else if (0 == strcmp(from_units, "Hz")) {
    *value *= 1e-12;
    return convert_units_from_THz(value, to_units);
  } else if (0 == strcmp(from_units, "rad/s")) {
    *value *= 1.5915494309189535e-13;
    return convert_units_from_THz(value, to_units);
  } else {
    return 1;
  }
}


x86 assembly (clang, -O0):
<convert_units>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    %rdx,-0x20(%rbp)
xor    %eax,%eax
cmp    -0x10(%rbp),%rax
jne    116c <convert_units+0x2c>
movl   $0xffffffff,-0x4(%rbp)
jmp    149b <convert_units+0x35b>
xor    %eax,%eax
cmp    -0x18(%rbp),%rax
jne    1184 <convert_units+0x44>
movl   $0xfffffffe,-0x4(%rbp)
jmp    149b <convert_units+0x35b>
xor    %eax,%eax
cmp    -0x20(%rbp),%rax
jne    119c <convert_units+0x5c>
movl   $0xfffffffd,-0x4(%rbp)
jmp    149b <convert_units+0x35b>
mov    -0x18(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1050 <strcmp@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    %rcx,%rax
jne    11c3 <convert_units+0x83>
movl   $0x0,-0x4(%rbp)
jmp    149b <convert_units+0x35b>
mov    -0x18(%rbp),%rdi
lea    0xe6a(%rip),%rsi
call   1050 <strcmp@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    %rcx,%rax
jne    11f6 <convert_units+0xb6>
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1040 <convert_units_from_um@plt>
mov    %eax,-0x4(%rbp)
jmp    149b <convert_units+0x35b>
mov    -0x18(%rbp),%rdi
lea    0xe3a(%rip),%rsi
call   1050 <strcmp@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    %rcx,%rax
jne    123d <convert_units+0xfd>
mov    -0x10(%rbp),%rax
movsd  0xdf0(%rip),%xmm0
mulsd  (%rax),%xmm0
movsd  %xmm0,(%rax)
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1040 <convert_units_from_um@plt>
mov    %eax,-0x4(%rbp)
jmp    149b <convert_units+0x35b>
mov    -0x18(%rbp),%rdi
lea    0xdf7(%rip),%rsi
call   1050 <strcmp@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    %rcx,%rax
jne    1284 <convert_units+0x144>
mov    -0x10(%rbp),%rax
movsd  0xdc9(%rip),%xmm0
mulsd  (%rax),%xmm0
movsd  %xmm0,(%rax)
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1040 <convert_units_from_um@plt>
mov    %eax,-0x4(%rbp)
jmp    149b <convert_units+0x35b>
mov    -0x18(%rbp),%rdi
lea    0xdaf(%rip),%rsi
call   1050 <strcmp@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    %rcx,%rax
jne    12cb <convert_units+0x18b>
mov    -0x10(%rbp),%rax
movsd  0xd7a(%rip),%xmm0
mulsd  (%rax),%xmm0
movsd  %xmm0,(%rax)
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1040 <convert_units_from_um@plt>
mov    %eax,-0x4(%rbp)
jmp    149b <convert_units+0x35b>
mov    -0x18(%rbp),%rdi
lea    0xd6b(%rip),%rsi
call   1050 <strcmp@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    %rcx,%rax
jne    1312 <convert_units+0x1d2>
mov    -0x10(%rbp),%rax
movsd  0xd2b(%rip),%xmm0
mulsd  (%rax),%xmm0
movsd  %xmm0,(%rax)
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1040 <convert_units_from_um@plt>
mov    %eax,-0x4(%rbp)
jmp    149b <convert_units+0x35b>
mov    -0x18(%rbp),%rdi
lea    0xd27(%rip),%rsi
call   1050 <strcmp@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    %rcx,%rax
jne    1345 <convert_units+0x205>
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1060 <convert_units_from_eV@plt>
mov    %eax,-0x4(%rbp)
jmp    149b <convert_units+0x35b>
mov    -0x18(%rbp),%rdi
lea    0xcf7(%rip),%rsi
call   1050 <strcmp@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    %rcx,%rax
jne    138c <convert_units+0x24c>
mov    -0x10(%rbp),%rax
movsd  0xca9(%rip),%xmm0
mulsd  (%rax),%xmm0
movsd  %xmm0,(%rax)
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1060 <convert_units_from_eV@plt>
mov    %eax,-0x4(%rbp)
jmp    149b <convert_units+0x35b>
mov    -0x18(%rbp),%rdi
lea    0xcb2(%rip),%rsi
call   1050 <strcmp@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    %rcx,%rax
jne    13bf <convert_units+0x27f>
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1030 <convert_units_from_THz@plt>
mov    %eax,-0x4(%rbp)
jmp    149b <convert_units+0x35b>
mov    -0x18(%rbp),%rdi
lea    0xc83(%rip),%rsi
call   1050 <strcmp@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    %rcx,%rax
jne    1406 <convert_units+0x2c6>
mov    -0x10(%rbp),%rax
movsd  0xc27(%rip),%xmm0
mulsd  (%rax),%xmm0
movsd  %xmm0,(%rax)
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1030 <convert_units_from_THz@plt>
mov    %eax,-0x4(%rbp)
jmp    149b <convert_units+0x35b>
mov    -0x18(%rbp),%rdi
lea    0xc3d(%rip),%rsi
call   1050 <strcmp@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    %rcx,%rax
jne    144d <convert_units+0x30d>
mov    -0x10(%rbp),%rax
movsd  0xbd8(%rip),%xmm0
mulsd  (%rax),%xmm0
movsd  %xmm0,(%rax)
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1030 <convert_units_from_THz@plt>
mov    %eax,-0x4(%rbp)
jmp    149b <convert_units+0x35b>
mov    -0x18(%rbp),%rdi
lea    0xbf9(%rip),%rsi
call   1050 <strcmp@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    %rcx,%rax
jne    1494 <convert_units+0x354>
mov    -0x10(%rbp),%rax
movsd  0xb89(%rip),%xmm0
mulsd  (%rax),%xmm0
movsd  %xmm0,(%rax)
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1030 <convert_units_from_THz@plt>
mov    %eax,-0x4(%rbp)
jmp    149b <convert_units+0x35b>
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<convert_units>:
push   %r15
push   %r14
push   %rbx
test   %rdi,%rdi
je     129b <convert_units+0x15b>
mov    %rsi,%rbx
test   %rsi,%rsi
je     12a2 <convert_units+0x162>
mov    %rdx,%r14
test   %rdx,%rdx
je     12a9 <convert_units+0x169>
mov    %rdi,%r15
mov    %rbx,%rdi
mov    %r14,%rsi
call   1050 <strcmp@plt>
test   %rax,%rax
je     12b0 <convert_units+0x170>
lea    0xeb4(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %rax,%rax
je     12f7 <convert_units+0x1b7>
lea    0xe9f(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %rax,%rax
je     12b8 <convert_units+0x178>
lea    0xe8b(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %rax,%rax
je     12c7 <convert_units+0x187>
lea    0xe72(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %rax,%rax
je     12d6 <convert_units+0x196>
lea    0xe5d(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %rax,%rax
je     12e5 <convert_units+0x1a5>
lea    0xe48(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %rax,%rax
je     1319 <convert_units+0x1d9>
lea    0xe33(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %rax,%rax
je     1307 <convert_units+0x1c7>
lea    0xe1d(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %rax,%rax
je     134a <convert_units+0x20a>
lea    0xe09(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %rax,%rax
je     1329 <convert_units+0x1e9>
lea    0xdf2(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %rax,%rax
je     1338 <convert_units+0x1f8>
lea    0xddd(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
mov    %rax,%rcx
mov    $0x1,%eax
test   %rcx,%rcx
jne    12b2 <convert_units+0x172>
movsd  (%r15),%xmm0
mulsd  0xd6a(%rip),%xmm0
jmp    1345 <convert_units+0x205>
mov    $0xffffffff,%eax
jmp    12b2 <convert_units+0x172>
mov    $0xfffffffe,%eax
jmp    12b2 <convert_units+0x172>
mov    $0xfffffffd,%eax
jmp    12b2 <convert_units+0x172>
xor    %eax,%eax
pop    %rbx
pop    %r14
pop    %r15
ret
movsd  (%r15),%xmm0
mulsd  0xd4b(%rip),%xmm0
jmp    12f2 <convert_units+0x1b2>
movsd  (%r15),%xmm0
mulsd  0xd5c(%rip),%xmm0
jmp    12f2 <convert_units+0x1b2>
movsd  (%r15),%xmm0
mulsd  0xd45(%rip),%xmm0
jmp    12f2 <convert_units+0x1b2>
movsd  (%r15),%xmm0
mulsd  0xd2e(%rip),%xmm0
movsd  %xmm0,(%r15)
mov    %r15,%rdi
mov    %r14,%rsi
pop    %rbx
pop    %r14
pop    %r15
jmp    1040 <convert_units_from_um@plt>
movsd  (%r15),%xmm0
mulsd  0xd04(%rip),%xmm0
movsd  %xmm0,(%r15)
mov    %r15,%rdi
mov    %r14,%rsi
pop    %rbx
pop    %r14
pop    %r15
jmp    1060 <convert_units_from_eV@plt>
movsd  (%r15),%xmm0
mulsd  0xcda(%rip),%xmm0
jmp    1345 <convert_units+0x205>
movsd  (%r15),%xmm0
mulsd  0xcc3(%rip),%xmm0
movsd  %xmm0,(%r15)
mov    %r15,%rdi
mov    %r14,%rsi
pop    %rbx
pop    %r14
pop    %r15
jmp    1030 <convert_units_from_THz@plt>

LLVM IR (-O0):
@.str = [3 x i8] c"um\00"
@.str.1 = [3 x i8] c"nm\00"
@.str.2 = [2 x i8] c"m\00"
@.str.3 = [3 x i8] c"cm\00"
@.str.4 = [3 x i8] c"mm\00"
@.str.5 = [3 x i8] c"eV\00"
@.str.6 = [2 x i8] c"J\00"
@.str.7 = [4 x i8] c"THz\00"
@.str.8 = [4 x i8] c"GHz\00"
@.str.9 = [3 x i8] c"Hz\00"
@.str.10 = [6 x i8] c"rad/s\00"
define i32 @convert_units(double* %0, i8* %1, i8* %2) {
%4 = alloca i32
%5 = alloca double*
%6 = alloca i8*
%7 = alloca i8*
store double* %0, double** %5
store i8* %1, i8** %6
store i8* %2, i8** %7
%8 = load double*, double** %5
%9 = icmp eq double* null, %8
br i1 %9, label %10, label %11
10: ; preds = %3
store i32 -1, i32* %4
br label %138
11: ; preds = %3
%12 = load i8*, i8** %6
%13 = icmp eq i8* null, %12
br i1 %13, label %14, label %15
14: ; preds = %11
store i32 -2, i32* %4
br label %138
15: ; preds = %11
%16 = load i8*, i8** %7
%17 = icmp eq i8* null, %16
br i1 %17, label %18, label %19
18: ; preds = %15
store i32 -3, i32* %4
br label %138
19: ; preds = %15
%20 = load i8*, i8** %6
%21 = load i8*, i8** %7
%22 = call i64 @strcmp(i8* %20, i8* %21)
%23 = icmp eq i64 0, %22
br i1 %23, label %24, label %25
24: ; preds = %19
store i32 0, i32* %4
br label %138
25: ; preds = %19
%26 = load i8*, i8** %6
%27 = call i64 @strcmp(i8* %26, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0))
%28 = icmp eq i64 0, %27
br i1 %28, label %29, label %33
29: ; preds = %25
%30 = load double*, double** %5
%31 = load i8*, i8** %7
%32 = call i32 @convert_units_from_um(double* %30, i8* %31)
store i32 %32, i32* %4
br label %138
33: ; preds = %25
%34 = load i8*, i8** %6
%35 = call i64 @strcmp(i8* %34, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
%36 = icmp eq i64 0, %35
br i1 %36, label %37, label %44
37: ; preds = %33
%38 = load double*, double** %5
%39 = load double, double* %38
%40 = fmul double %39, 1.000000e-03
store double %40, double* %38
%41 = load double*, double** %5
%42 = load i8*, i8** %7
%43 = call i32 @convert_units_from_um(double* %41, i8* %42)
store i32 %43, i32* %4
br label %138
44: ; preds = %33
%45 = load i8*, i8** %6
%46 = call i64 @strcmp(i8* %45, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%47 = icmp eq i64 0, %46
br i1 %47, label %48, label %55
48: ; preds = %44
%49 = load double*, double** %5
%50 = load double, double* %49
%51 = fmul double %50, 1.000000e+06
store double %51, double* %49
%52 = load double*, double** %5
%53 = load i8*, i8** %7
%54 = call i32 @convert_units_from_um(double* %52, i8* %53)
store i32 %54, i32* %4
br label %138
55: ; preds = %44
%56 = load i8*, i8** %6
%57 = call i64 @strcmp(i8* %56, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
%58 = icmp eq i64 0, %57
br i1 %58, label %59, label %66
59: ; preds = %55
%60 = load double*, double** %5
%61 = load double, double* %60
%62 = fmul double %61, 1.000000e+04
store double %62, double* %60
%63 = load double*, double** %5
%64 = load i8*, i8** %7
%65 = call i32 @convert_units_from_um(double* %63, i8* %64)
store i32 %65, i32* %4
br label %138
66: ; preds = %55
%67 = load i8*, i8** %6
%68 = call i64 @strcmp(i8* %67, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.4, i64 0, i64 0))
%69 = icmp eq i64 0, %68
br i1 %69, label %70, label %77
70: ; preds = %66
%71 = load double*, double** %5
%72 = load double, double* %71
%73 = fmul double %72, 1.000000e+03
store double %73, double* %71
%74 = load double*, double** %5
%75 = load i8*, i8** %7
%76 = call i32 @convert_units_from_um(double* %74, i8* %75)
store i32 %76, i32* %4
br label %138
77: ; preds = %66
%78 = load i8*, i8** %6
%79 = call i64 @strcmp(i8* %78, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0))
%80 = icmp eq i64 0, %79
br i1 %80, label %81, label %85
81: ; preds = %77
%82 = load double*, double** %5
%83 = load i8*, i8** %7
%84 = call i32 @convert_units_from_eV(double* %82, i8* %83)
store i32 %84, i32* %4
br label %138
85: ; preds = %77
%86 = load i8*, i8** %6
%87 = call i64 @strcmp(i8* %86, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.6, i64 0, i64 0))
%88 = icmp eq i64 0, %87
br i1 %88, label %89, label %96
89: ; preds = %85
%90 = load double*, double** %5
%91 = load double, double* %90
%92 = fmul double %91, 0x43D5A7923DF8E3D3
store double %92, double* %90
%93 = load double*, double** %5
%94 = load i8*, i8** %7
%95 = call i32 @convert_units_from_eV(double* %93, i8* %94)
store i32 %95, i32* %4
br label %138
96: ; preds = %85
%97 = load i8*, i8** %6
%98 = call i64 @strcmp(i8* %97, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.7, i64 0, i64 0))
%99 = icmp eq i64 0, %98
br i1 %99, label %100, label %104
100: ; preds = %96
%101 = load double*, double** %5
%102 = load i8*, i8** %7
%103 = call i32 @convert_units_from_THz(double* %101, i8* %102)
store i32 %103, i32* %4
br label %138
104: ; preds = %96
%105 = load i8*, i8** %6
%106 = call i64 @strcmp(i8* %105, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.8, i64 0, i64 0))
%107 = icmp eq i64 0, %106
br i1 %107, label %108, label %115
108: ; preds = %104
%109 = load double*, double** %5
%110 = load double, double* %109
%111 = fmul double %110, 1.000000e-03
store double %111, double* %109
%112 = load double*, double** %5
%113 = load i8*, i8** %7
%114 = call i32 @convert_units_from_THz(double* %112, i8* %113)
store i32 %114, i32* %4
br label %138
115: ; preds = %104
%116 = load i8*, i8** %6
%117 = call i64 @strcmp(i8* %116, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.9, i64 0, i64 0))
%118 = icmp eq i64 0, %117
br i1 %118, label %119, label %126
119: ; preds = %115
%120 = load double*, double** %5
%121 = load double, double* %120
%122 = fmul double %121, 0x3D719799812DEA11
store double %122, double* %120
%123 = load double*, double** %5
%124 = load i8*, i8** %7
%125 = call i32 @convert_units_from_THz(double* %123, i8* %124)
store i32 %125, i32* %4
br label %138
126: ; preds = %115
%127 = load i8*, i8** %6
%128 = call i64 @strcmp(i8* %127, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.10, i64 0, i64 0))
%129 = icmp eq i64 0, %128
br i1 %129, label %130, label %137
130: ; preds = %126
%131 = load double*, double** %5
%132 = load double, double* %131
%133 = fmul double %132, 0x3D466629406B8B6D
store double %133, double* %131
%134 = load double*, double** %5
%135 = load i8*, i8** %7
%136 = call i32 @convert_units_from_THz(double* %134, i8* %135)
store i32 %136, i32* %4
br label %138
137: ; preds = %126
store i32 1, i32* %4
br label %138
138: ; preds = %137, %130, %119, %108, %100, %89, %81, %70, %59, %48, %37, %29, %24, %18, %14, %10
%139 = load i32, i32* %4
ret i32 %139
}

LLVM IR (-O2):
@.str = [3 x i8] c"um\00"
@.str.1 = [3 x i8] c"nm\00"
@.str.2 = [2 x i8] c"m\00"
@.str.3 = [3 x i8] c"cm\00"
@.str.4 = [3 x i8] c"mm\00"
@.str.5 = [3 x i8] c"eV\00"
@.str.6 = [2 x i8] c"J\00"
@.str.7 = [4 x i8] c"THz\00"
@.str.8 = [4 x i8] c"GHz\00"
@.str.9 = [3 x i8] c"Hz\00"
@.str.10 = [6 x i8] c"rad/s\00"
define i32 @convert_units(double* %0, i8* %1, i8* %2) {
%4 = icmp eq double* %0, null
br i1 %4, label %83, label %5
5: ; preds = %3
%6 = icmp eq i8* %1, null
br i1 %6, label %83, label %7
7: ; preds = %5
%8 = icmp eq i8* %2, null
br i1 %8, label %83, label %9
9: ; preds = %7
%10 = tail call i64 @strcmp(i8* %1, i8* %2)
%11 = icmp eq i64 %10, 0
br i1 %11, label %83, label %12
12: ; preds = %9
%13 = tail call i64 @strcmp(i8* %1, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0))
%14 = icmp eq i64 %13, 0
br i1 %14, label %15, label %17
15: ; preds = %12
%16 = tail call i32 @convert_units_from_um(double* %0, i8* %2)
br label %83
17: ; preds = %12
%18 = tail call i64 @strcmp(i8* %1, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
%19 = icmp eq i64 %18, 0
br i1 %19, label %20, label %24
20: ; preds = %17
%21 = load double, double* %0
%22 = fmul double %21, 1.000000e-03
store double %22, double* %0
%23 = tail call i32 @convert_units_from_um(double* %0, i8* %2)
br label %83
24: ; preds = %17
%25 = tail call i64 @strcmp(i8* %1, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%26 = icmp eq i64 %25, 0
br i1 %26, label %27, label %31
27: ; preds = %24
%28 = load double, double* %0
%29 = fmul double %28, 1.000000e+06
store double %29, double* %0
%30 = tail call i32 @convert_units_from_um(double* %0, i8* %2)
br label %83
31: ; preds = %24
%32 = tail call i64 @strcmp(i8* %1, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
%33 = icmp eq i64 %32, 0
br i1 %33, label %34, label %38
34: ; preds = %31
%35 = load double, double* %0
%36 = fmul double %35, 1.000000e+04
store double %36, double* %0
%37 = tail call i32 @convert_units_from_um(double* %0, i8* %2)
br label %83
38: ; preds = %31
%39 = tail call i64 @strcmp(i8* %1, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.4, i64 0, i64 0))
%40 = icmp eq i64 %39, 0
br i1 %40, label %41, label %45
41: ; preds = %38
%42 = load double, double* %0
%43 = fmul double %42, 1.000000e+03
store double %43, double* %0
%44 = tail call i32 @convert_units_from_um(double* %0, i8* %2)
br label %83
45: ; preds = %38
%46 = tail call i64 @strcmp(i8* %1, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0))
%47 = icmp eq i64 %46, 0
br i1 %47, label %48, label %50
48: ; preds = %45
%49 = tail call i32 @convert_units_from_eV(double* %0, i8* %2)
br label %83
50: ; preds = %45
%51 = tail call i64 @strcmp(i8* %1, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.6, i64 0, i64 0))
%52 = icmp eq i64 %51, 0
br i1 %52, label %53, label %57
53: ; preds = %50
%54 = load double, double* %0
%55 = fmul double %54, 0x43D5A7923DF8E3D3
store double %55, double* %0
%56 = tail call i32 @convert_units_from_eV(double* %0, i8* %2)
br label %83
57: ; preds = %50
%58 = tail call i64 @strcmp(i8* %1, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.7, i64 0, i64 0))
%59 = icmp eq i64 %58, 0
br i1 %59, label %60, label %62
60: ; preds = %57
%61 = tail call i32 @convert_units_from_THz(double* %0, i8* %2)
br label %83
62: ; preds = %57
%63 = tail call i64 @strcmp(i8* %1, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.8, i64 0, i64 0))
%64 = icmp eq i64 %63, 0
br i1 %64, label %65, label %69
65: ; preds = %62
%66 = load double, double* %0
%67 = fmul double %66, 1.000000e-03
store double %67, double* %0
%68 = tail call i32 @convert_units_from_THz(double* %0, i8* %2)
br label %83
69: ; preds = %62
%70 = tail call i64 @strcmp(i8* %1, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.9, i64 0, i64 0))
%71 = icmp eq i64 %70, 0
br i1 %71, label %72, label %76
72: ; preds = %69
%73 = load double, double* %0
%74 = fmul double %73, 0x3D719799812DEA11
store double %74, double* %0
%75 = tail call i32 @convert_units_from_THz(double* %0, i8* %2)
br label %83
76: ; preds = %69
%77 = tail call i64 @strcmp(i8* %1, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.10, i64 0, i64 0))
%78 = icmp eq i64 %77, 0
br i1 %78, label %79, label %83
79: ; preds = %76
%80 = load double, double* %0
%81 = fmul double %80, 0x3D466629406B8B6D
store double %81, double* %0
%82 = tail call i32 @convert_units_from_THz(double* %0, i8* %2)
br label %83
83: ; preds = %76, %9, %7, %5, %3, %79, %72, %65, %60, %53, %48, %41, %34, %27, %20, %15
%84 = phi i32 [ %16, %15 ], [ %23, %20 ], [ %30, %27 ], [ %37, %34 ], [ %44, %41 ], [ %49, %48 ], [ %56, %53 ], [ %61, %60 ], [ %68, %65 ], [ %75, %72 ], [ %82, %79 ], [ -1, %3 ], [ -2, %5 ], [ -3, %7 ], [ 0, %9 ], [ 1, %76 ]
ret i32 %84
}