void getnames(buf, file, word) char *buf, *file, *word;
{
  char *temp;
  temp = buf;
  while (*temp != 0) {
    switch (*temp) {
    case '>':
      strcpy(file, getstring(++temp));
      break;
    case '<':
      if (*(++temp) == '<')
        ++temp;
      strcpy(word, getstring(temp));
      break;
    default:
      temp++;
    }
  }
}


x86 assembly (clang, -O0):
<getnames>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x20(%rbp)
mov    -0x20(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x0,%eax
je     11fe <getnames+0xde>
mov    -0x20(%rbp),%rax
movsbl (%rax),%eax
mov    %eax,-0x24(%rbp)
sub    $0x3c,%eax
je     11a1 <getnames+0x81>
jmp    1164 <getnames+0x44>
mov    -0x24(%rbp),%eax
sub    $0x3e,%eax
jne    11ed <getnames+0xcd>
jmp    1175 <getnames+0x55>
mov    -0x10(%rbp),%rax
mov    %rax,-0x30(%rbp)
mov    -0x20(%rbp),%rdi
add    $0x1,%rdi
mov    %rdi,-0x20(%rbp)
mov    $0x0,%al
call   1030 <getstring@plt>
mov    -0x30(%rbp),%rdi
movslq %eax,%rsi
call   1040 <strcpy@plt>
jmp    11f9 <getnames+0xd9>
mov    -0x20(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x20(%rbp)
movsbl 0x1(%rax),%eax
cmp    $0x3c,%eax
jne    11c9 <getnames+0xa9>
mov    -0x20(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x20(%rbp)
mov    -0x18(%rbp),%rax
mov    %rax,-0x38(%rbp)
mov    -0x20(%rbp),%rdi
mov    $0x0,%al
call   1030 <getstring@plt>
mov    -0x38(%rbp),%rdi
movslq %eax,%rsi
call   1040 <strcpy@plt>
jmp    11f9 <getnames+0xd9>
mov    -0x20(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x20(%rbp)
jmp    113c <getnames+0x1c>
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<getnames>:
push   %r15
push   %r14
push   %rbx
mov    (%rdi),%al
test   %al,%al
je     118c <getnames+0x6c>
mov    %rdx,%r14
mov    %rsi,%r15
mov    %rdi,%rbx
jmp    1156 <getnames+0x36>
add    $0x1,%rbx
mov    %rbx,%rdi
xor    %eax,%eax
call   1030 <getstring@plt>
movslq %eax,%rsi
mov    %r14,%rdi
call   1040 <strcpy@plt>
movzbl (%rbx),%eax
test   %al,%al
je     118c <getnames+0x6c>
movsbl %al,%eax
cmp    $0x3c,%eax
je     1180 <getnames+0x60>
add    $0x1,%rbx
cmp    $0x3e,%eax
jne    114f <getnames+0x2f>
mov    %rbx,%rdi
xor    %eax,%eax
call   1030 <getstring@plt>
movslq %eax,%rsi
mov    %r15,%rdi
jmp    114a <getnames+0x2a>
nopl   0x0(%rax)
cmpb   $0x3c,0x1(%rbx)
jne    1136 <getnames+0x16>
add    $0x2,%rbx
jmp    113a <getnames+0x1a>
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
define void @getnames(i8* %0, i8* %1, i8* %2) {
%4 = alloca i8*
%5 = alloca i8*
%6 = alloca i8*
%7 = alloca i8*
store i8* %0, i8** %4
store i8* %1, i8** %5
store i8* %2, i8** %6
%8 = load i8*, i8** %4
store i8* %8, i8** %7
br label %9
9: ; preds = %45, %3
%10 = load i8*, i8** %7
%11 = load i8, i8* %10
%12 = sext i8 %11 to i32
%13 = icmp ne i32 %12, 0
br i1 %13, label %14, label %46
14: ; preds = %9
%15 = load i8*, i8** %7
%16 = load i8, i8* %15
%17 = sext i8 %16 to i32
switch i32 %17, label %42 [
i32 62, label %18
i32 60, label %26
]
18: ; preds = %14
%19 = load i8*, i8** %5
%20 = load i8*, i8** %7
%21 = getelementptr inbounds i8, i8* %20, i32 1
store i8* %21, i8** %7
%22 = call i32 (i8*, ...) bitcast (i32 (...)* @getstring to i32 (i8*, ...)*)(i8* %21)
%23 = sext i32 %22 to i64
%24 = inttoptr i64 %23 to i8*
%25 = call i8* @strcpy(i8* %19, i8* %24)
br label %45
26: ; preds = %14
%27 = load i8*, i8** %7
%28 = getelementptr inbounds i8, i8* %27, i32 1
store i8* %28, i8** %7
%29 = load i8, i8* %28
%30 = sext i8 %29 to i32
%31 = icmp eq i32 %30, 60
br i1 %31, label %32, label %35
32: ; preds = %26
%33 = load i8*, i8** %7
%34 = getelementptr inbounds i8, i8* %33, i32 1
store i8* %34, i8** %7
br label %35
35: ; preds = %32, %26
%36 = load i8*, i8** %6
%37 = load i8*, i8** %7
%38 = call i32 (i8*, ...) bitcast (i32 (...)* @getstring to i32 (i8*, ...)*)(i8* %37)
%39 = sext i32 %38 to i64
%40 = inttoptr i64 %39 to i8*
%41 = call i8* @strcpy(i8* %36, i8* %40)
br label %45
42: ; preds = %14
%43 = load i8*, i8** %7
%44 = getelementptr inbounds i8, i8* %43, i32 1
store i8* %44, i8** %7
br label %45
45: ; preds = %42, %35, %18
br label %9
46: ; preds = %9
ret void
}

LLVM IR (-O2):
define void @getnames(i8* %0, i8* %1, i8* %2) {
%4 = load i8, i8* %0
%5 = icmp eq i8 %4, 0
br i1 %5, label %32, label %6
6: ; preds = %3, %28
%7 = phi i8 [ %30, %28 ], [ %4, %3 ]
%8 = phi i8* [ %29, %28 ], [ %0, %3 ]
%9 = sext i8 %7 to i32
switch i32 %9, label %26 [
i32 62, label %10
i32 60, label %16
]
10: ; preds = %6
%11 = getelementptr inbounds i8, i8* %8, i64 1
%12 = tail call i32 (i8*, ...) bitcast (i32 (...)* @getstring to i32 (i8*, ...)*)(i8* %11)
%13 = sext i32 %12 to i64
%14 = inttoptr i64 %13 to i8*
%15 = tail call i8* @strcpy(i8* dereferenceable(1) %1, i8* dereferenceable(1) %14)
br label %28
16: ; preds = %6
%17 = getelementptr inbounds i8, i8* %8, i64 1
%18 = load i8, i8* %17
%19 = icmp eq i8 %18, 60
%20 = getelementptr inbounds i8, i8* %8, i64 2
%21 = select i1 %19, i8* %20, i8* %17
%22 = tail call i32 (i8*, ...) bitcast (i32 (...)* @getstring to i32 (i8*, ...)*)(i8* %21)
%23 = sext i32 %22 to i64
%24 = inttoptr i64 %23 to i8*
%25 = tail call i8* @strcpy(i8* dereferenceable(1) %2, i8* dereferenceable(1) %24)
br label %28
26: ; preds = %6
%27 = getelementptr inbounds i8, i8* %8, i64 1
br label %28
28: ; preds = %26, %16, %10
%29 = phi i8* [ %27, %26 ], [ %21, %16 ], [ %11, %10 ]
%30 = load i8, i8* %29
%31 = icmp eq i8 %30, 0
br i1 %31, label %32, label %6
32: ; preds = %28, %3
ret void
}