bpf: fix test failures due to previous bpf change of assembly code syntax

Signed-off-by: Yonghong Song <yhs@fb.com>
llvm-svn: 312840
This commit is contained in:
Yonghong Song 2017-09-09 00:11:13 +00:00
parent 285d2fb85c
commit 6807778e52
5 changed files with 6 additions and 6 deletions

View File

@ -55,7 +55,7 @@ entry:
tail call void inttoptr (i64 4 to void (i64, i32)*)(i64 %call, i32 4) #2
ret i32 0
; CHECK-LABEL: ld_pseudo:
; CHECK: ld_pseudo r1, 2, 3 # encoding: [0x18,0x21,0x00,0x00,0x03,0x00
; CHECK: ld_pseudo r1, 2, 3ll # encoding: [0x18,0x21,0x00,0x00,0x03,0x00
}
declare i64 @llvm.bpf.pseudo(i64, i64) #2

View File

@ -35,12 +35,12 @@ define i32 @test() local_unnamed_addr #0 {
entry:
tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds (%struct.test_t1, %struct.test_t1* @g1, i64 0, i32 0), i8* getelementptr inbounds (%struct.test_t1, %struct.test_t1* @test.t1, i64 0, i32 0), i64 3, i32 1, i1 false)
tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* bitcast (%struct.test_t2* @g2 to i8*), i8* bitcast (%struct.test_t2* @test.t2 to i8*), i64 20, i32 4, i1 false)
; CHECK: r1 = <MCOperand Expr:(g1)>ll
; CHECK: r1 = g1
; CHECK: r2 = 0
; CHECK: *(u8 *)(r1 + 1) = r2
; CHECK: r3 = 1
; CHECK: *(u8 *)(r1 + 2) = r3
; CHECK: r1 = <MCOperand Expr:(g2)>ll
; CHECK: r1 = g2
; CHECK: *(u32 *)(r1 + 8) = r3
ret i32 0
}

View File

@ -32,7 +32,7 @@ define i32 @test() local_unnamed_addr #0 {
entry:
tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* getelementptr inbounds (%struct.test_t2, %struct.test_t2* @g, i64 0, i32 0), i8* getelementptr inbounds (%struct.test_t2, %struct.test_t2* @test.t2, i64 0, i32 0), i64 32, i32 4, i1 false)
; CHECK: r1 = <MCOperand Expr:(g)>ll
; CHECK: r1 = g
; CHECK: r2 = 0
; CHECK: *(u32 *)(r1 + 28) = r2
; CHECK: r3 = 3

View File

@ -18,7 +18,7 @@ entry:
%tobool = icmp eq i32 %0, 0
%1 = load i32, i32* @c, align 4
%. = select i1 %tobool, i32 0, i32 %1
; CHECK: r1 = <MCOperand Expr:(b)>ll
; CHECK: r1 = b
; CHECK: r1 = *(u32 *)(r1 + 0)
; CHECK: if r1 == 0 goto
ret i32 %.

View File

@ -40,7 +40,7 @@ define i32 @ebpf_filter(%struct.__sk_buff* nocapture readnone %ebpf_packet) #0 s
; CHECK: r2 = r10
; CHECK: r2 += -8
; CHECK: r1 = <MCOperand Expr:(routing)>ll
; CHECK: r1 = routing
; CHECK: call bpf_map_lookup_elem
; CHECK: exit
%key = alloca %struct.routing_key_2, align 1