brintos

brintos / llvm-project-archived public Read only

0
0
Text · 719 B · 97ac8f5 Raw
21 lines · plain
1; RUN: llc -mtriple=powerpc64le-unknown-linux-gnu %s -o - | FileCheck %s2 3; Check that codegen for an addrspace cast succeeds without error.4define <4 x ptr addrspace(1)> @f (<4 x ptr> %x) {5  %1 = addrspacecast <4 x ptr> %x to <4 x ptr addrspace(1)>6  ret <4 x ptr addrspace(1)> %17  ; CHECK-LABEL: @f8}9 10; Check that fairly complicated addrspace cast and operations succeed without error.11%struct = type opaque12define void @g (ptr %x) {13  %1 = load ptr addrspace(10), ptr %x14  %2 = addrspacecast ptr addrspace(10) %1 to ptr addrspace(11)15  %3 = getelementptr i8, ptr addrspace(11) %2, i64 1616  %4 = load ptr addrspace(10), ptr addrspace(11) %317  store ptr addrspace(10) %4, ptr undef18  ret void19  ; CHECK-LABEL: @g20}21