xref: /llvm-project/llvm/test/CodeGen/Hexagon/simple-types-mem.ll (revision 8177bf5022c6dfc48d236082fa02076feedd60df)
1; RUN: llc -march=hexagon < %s
2; REQUIRES: asserts
3
4; Only simple types memory accesses are handled.
5
6target triple = "hexagon"
7
8%struct.hoge = type { i320 }
9
10define dso_local void @widget() {
11bb:
12  %tmp = alloca %struct.hoge, align 1
13  %tmp1 = bitcast %struct.hoge* %tmp to i320*
14  %tmp2 = load i320, i320* %tmp1, align 1
15  %tmp3 = and i320 %tmp2, -18446744073709551616
16  %tmp4 = or i320 %tmp3, 0
17  store i320 %tmp4, i320* %tmp1, align 1
18  call void @llvm.trap()
19  unreachable
20}
21
22declare void @llvm.trap()
23