aboutsummaryrefslogtreecommitdiff
path: root/llvm/test/CodeGen/WebAssembly/fast-isel-simd128.ll
blob: df14e1054d91b7d89dcd9f6c6f2c42d82b05bf4c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 6
; RUN: llc < %s -fast-isel -fast-isel-abort=0 -mattr=+simd128 -verify-machineinstrs | FileCheck %s

target triple = "wasm32-unknown-unknown"

define i8 @pr165438(<4 x i32> %0) {
; CHECK-LABEL: pr165438:
; CHECK:         .functype pr165438 (v128) -> (i32)
; CHECK-NEXT:  # %bb.0: # %entry
; CHECK-NEXT:    local.get 0
; CHECK-NEXT:    local.get 0
; CHECK-NEXT:    i8x16.shuffle 0, 4, 8, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
; CHECK-NEXT:    i8x16.extract_lane_u 0
; CHECK-NEXT:    # fallthrough-return
entry:
  %conv = trunc <4 x i32> %0 to <4 x i8>
  br label %cond.true


cond.true:                                        ; preds = %entry
  %vecext = extractelement <4 x i8> %conv, i32 0
  ret i8 %vecext
}