annotate test/CodeGen/BPF/mem_offset.ll @ 128:c347d3398279 default tip

fix
author mir3636
date Wed, 06 Dec 2017 14:37:17 +0900
parents 803732b1fca8
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
121
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
1 ; RUN: llc -march=bpfel -show-mc-encoding < %s | FileCheck %s
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
2
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
3 ; Function Attrs: nounwind
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
4 define i32 @bpf_prog1(i8* nocapture readnone) local_unnamed_addr #0 {
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
5 ; CHECK: r1 += -1879113726 # encoding: [0x07,0x01,0x00,0x00,0x02,0x00,0xff,0x8f]
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
6 ; CHECK: r0 = *(u64 *)(r1 + 0) # encoding: [0x79,0x10,0x00,0x00,0x00,0x00,0x00,0x00]
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
7 %2 = alloca i64, align 8
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
8 %3 = bitcast i64* %2 to i8*
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
9 store volatile i64 590618314553, i64* %2, align 8
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
10 %4 = load volatile i64, i64* %2, align 8
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
11 %5 = add i64 %4, -1879113726
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
12 %6 = inttoptr i64 %5 to i64*
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
13 %7 = load i64, i64* %6, align 8
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
14 %8 = trunc i64 %7 to i32
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
15 ret i32 %8
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
16 }
803732b1fca8 LLVM 5.0
kono
parents:
diff changeset
17