Skip to content

Commit

Permalink
Inline: Convert test to generated checks
Browse files Browse the repository at this point in the history
  • Loading branch information
arsenm committed May 24, 2023
1 parent 7d7c82a commit abf1abb
Showing 1 changed file with 14 additions and 7 deletions.
21 changes: 14 additions & 7 deletions llvm/test/Transforms/Inline/inline_inv_group.ll
Original file line number Diff line number Diff line change
@@ -1,19 +1,26 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 2
; RUN: opt < %s -passes=inline -S | FileCheck %s

target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

define ptr @callee() alwaysinline {
; CHECK-LABEL: define ptr @callee()
%1 = call ptr @llvm.strip.invariant.group.p0(ptr null)
ret ptr %1
; CHECK-LABEL: define ptr @callee
; CHECK-SAME: () #[[ATTR0:[0-9]+]] {
; CHECK-NEXT: [[TMP1:%.*]] = call ptr @llvm.strip.invariant.group.p0(ptr null)
; CHECK-NEXT: ret ptr [[TMP1]]
;
%1 = call ptr @llvm.strip.invariant.group.p0(ptr null)
ret ptr %1
}

define ptr @caller() {
; CHECK-LABEL: define ptr @caller()
; CHECK-NEXT: call ptr @llvm.strip.invariant.group.p0(ptr null)
%1 = call ptr @callee()
ret ptr %1
; CHECK-LABEL: define ptr @caller() {
; CHECK-NEXT: [[TMP1:%.*]] = call ptr @llvm.strip.invariant.group.p0(ptr null)
; CHECK-NEXT: ret ptr [[TMP1]]
;
%1 = call ptr @callee()
ret ptr %1
}

declare ptr @llvm.strip.invariant.group.p0(ptr)

0 comments on commit abf1abb

Please sign in to comment.