; RUN: llc < %s -march=bpf -verify-machineinstrs | FileCheck %s ; Source code: ; struct xdp_md { ; unsigned data; ; unsigned data_end; ; }; ; ; int gbl; ; int xdp_dummy(struct xdp_md *xdp) ; { ; char tmp; ; long addr; ; ; if (gbl) { ; long addr1 = (long)xdp->data; ; tmp = *(char *)addr1; ; if (tmp == 1) ; return 3; ; } else { ; tmp = *(volatile char *)(long)xdp->data_end; ; if (tmp == 1) ; return 2; ; } ; addr = (long)xdp->data; ; tmp = *(volatile char *)addr; ; if (tmp == 0) ; return 1; ; return 0; ; } ; ; unsigned int rol32(unsigned int word, unsigned int shift) ; { ; return (word << shift) | (word >> ((-shift) & 31)); ; } %struct.xdp_md = type { i32, i32 } @gbl = common local_unnamed_addr global i32 0, align 4 ; Function Attrs: norecurse nounwind define i32 @xdp_dummy(%struct.xdp_md* nocapture readonly) local_unnamed_addr #0 { %2 = load i32, i32* @gbl, align 4 %3 = icmp eq i32 %2, 0 br i1 %3, label %11, label %4 ;