unsigned char *llib_led_edit_next_word(unsigned char *word) {
  while (*word && *word != '|' && *word != '=' && *word != ':')
    ++word;
  if (*word == '|')
    ++word;
  return word;
}


x86 assembly (clang, -O0):
<llib_led_edit_next_word>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
movzbl (%rax),%ecx
xor    %eax,%eax
cmp    $0x0,%ecx
mov    %al,-0x9(%rbp)
je     1157 <llib_led_edit_next_word+0x57>
mov    -0x8(%rbp),%rax
movzbl (%rax),%ecx
xor    %eax,%eax
cmp    $0x7c,%ecx
mov    %al,-0x9(%rbp)
je     1157 <llib_led_edit_next_word+0x57>
mov    -0x8(%rbp),%rax
movzbl (%rax),%ecx
xor    %eax,%eax
cmp    $0x3d,%ecx
mov    %al,-0x9(%rbp)
je     1157 <llib_led_edit_next_word+0x57>
mov    -0x8(%rbp),%rax
movzbl (%rax),%eax
cmp    $0x3a,%eax
setne  %al
mov    %al,-0x9(%rbp)
mov    -0x9(%rbp),%al
test   $0x1,%al
jne    1167 <llib_led_edit_next_word+0x67>
jmp    1178 <llib_led_edit_next_word+0x78>
mov    -0x8(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x8(%rbp)
jmp    1108 <llib_led_edit_next_word+0x8>
mov    -0x8(%rbp),%rax
movzbl (%rax),%eax
cmp    $0x7c,%eax
jne    1194 <llib_led_edit_next_word+0x94>
mov    -0x8(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<llib_led_edit_next_word>:
mov    %rdi,%rax
movabs $0x2400000000000001,%rcx
nopl   (%rax)
movzbl (%rax),%edx
cmp    $0x3d,%rdx
ja     111f <llib_led_edit_next_word+0x1f>
bt     %rdx,%rcx
jb     112a <llib_led_edit_next_word+0x2a>
cmp    $0x7c,%dl
je     112a <llib_led_edit_next_word+0x2a>
add    $0x1,%rax
jmp    1110 <llib_led_edit_next_word+0x10>
xor    %ecx,%ecx
cmp    $0x7c,%dl
sete   %cl
add    %rcx,%rax
ret

LLVM IR (-O0):
define i8* @llib_led_edit_next_word(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
br label %3
3: ; preds = %25, %1
%4 = load i8*, i8** %2
%5 = load i8, i8* %4
%6 = zext i8 %5 to i32
%7 = icmp ne i32 %6, 0
br i1 %7, label %8, label %23
8: ; preds = %3
%9 = load i8*, i8** %2
%10 = load i8, i8* %9
%11 = zext i8 %10 to i32
%12 = icmp ne i32 %11, 124
br i1 %12, label %13, label %23
13: ; preds = %8
%14 = load i8*, i8** %2
%15 = load i8, i8* %14
%16 = zext i8 %15 to i32
%17 = icmp ne i32 %16, 61
br i1 %17, label %18, label %23
18: ; preds = %13
%19 = load i8*, i8** %2
%20 = load i8, i8* %19
%21 = zext i8 %20 to i32
%22 = icmp ne i32 %21, 58
br label %23
23: ; preds = %18, %13, %8, %3
%24 = phi i1 [ false, %13 ], [ false, %8 ], [ false, %3 ], [ %22, %18 ]
br i1 %24, label %25, label %28
25: ; preds = %23
%26 = load i8*, i8** %2
%27 = getelementptr inbounds i8, i8* %26, i32 1
store i8* %27, i8** %2
br label %3
28: ; preds = %23
%29 = load i8*, i8** %2
%30 = load i8, i8* %29
%31 = zext i8 %30 to i32
%32 = icmp eq i32 %31, 124
br i1 %32, label %33, label %36
33: ; preds = %28
%34 = load i8*, i8** %2
%35 = getelementptr inbounds i8, i8* %34, i32 1
store i8* %35, i8** %2
br label %36
36: ; preds = %33, %28
%37 = load i8*, i8** %2
ret i8* %37
}

LLVM IR (-O2):
define i8* @llib_led_edit_next_word(i8* %0) {
br label %2
2: ; preds = %5, %1
%3 = phi i8* [ %0, %1 ], [ %6, %5 ]
%4 = load i8, i8* %3
switch i8 %4, label %5 [
i8 0, label %7
i8 124, label %7
i8 61, label %7
i8 58, label %7
]
5: ; preds = %2
%6 = getelementptr inbounds i8, i8* %3, i64 1
br label %2
7: ; preds = %2, %2, %2, %2
%8 = icmp eq i8 %4, 124
%9 = zext i1 %8 to i64
%10 = getelementptr i8, i8* %3, i64 %9
ret i8* %10
}