1; RUN: llc -O0 -mtriple=amdgcn--amdhsa -mcpu=fiji -verify-machineinstrs < %s | FileCheck -check-prefix=GCN -check-prefix=VI -check-prefix=OPTNONE %s 2 3; GCN-LABEL: {{^}}store_to_undef: 4 5; -O0 should assume spilling, so the input scratch resource descriptor 6; -should be used directly without any copies. 7 8; OPTNONE-NOT: s_mov_b32 9; OPTNONE: buffer_store_dword v{{[0-9]+}}, v{{[0-9]+}}, s[0:3], s7 offen{{$}} 10define void @store_to_undef() #0 { 11 store volatile i32 0, i32* undef 12 ret void 13} 14 15; GCN-LABEL: {{^}}store_to_inttoptr: 16define void @store_to_inttoptr() #0 { 17 store volatile i32 0, i32* inttoptr (i32 123 to i32*) 18 ret void 19} 20 21; GCN-LABEL: {{^}}load_from_undef: 22define void @load_from_undef() #0 { 23 %ld = load volatile i32, i32* undef 24 ret void 25} 26 27; GCN-LABEL: {{^}}load_from_inttoptr: 28define void @load_from_inttoptr() #0 { 29 %ld = load volatile i32, i32* inttoptr (i32 123 to i32*) 30 ret void 31} 32 33attributes #0 = { nounwind } 34