1 ; RUN: llc -mtriple=i686-unknown-linux-gnu -o - %s | FileCheck %s
3 declare void @f(i16 signext)
4 declare void @g(i32 signext)
7 define void @flags_match(i16 signext %x) {
9 tail call void @f(i16 signext %x)
12 ; The parameter flags match; do the tail call.
13 ; CHECK-LABEL: flags_match:
17 define void @flags_mismatch(i16 zeroext %x) {
19 tail call void @f(i16 signext %x)
22 ; The parameter flags mismatch. %x has not been sign-extended,
23 ; so tail call is not possible.
24 ; CHECK-LABEL: flags_mismatch:
30 define void @mismatch_doesnt_matter(i32 zeroext %x) {
32 tail call void @g(i32 signext %x)
35 ; The parameter flags mismatch, but the type is wide enough that
36 ; no extension takes place in practice, so do the tail call.
38 ; CHECK-LABEL: mismatch_doesnt_matter: