1 ; RUN: llc -O2 < %s | FileCheck %s
2 target triple = "powerpc64le-linux-gnu"
4 define void @foo(i32 %v, i16* %p) {
5 %1 = and i32 %v, -65536
6 %2 = tail call i32 @llvm.bswap.i32(i32 %1)
7 %conv = trunc i32 %2 to i16
8 store i16 %conv, i16* %p
16 declare i32 @llvm.bswap.i32(i32)