[PATCH] D135497: [NFC][3/n] Remove enable-new-pm from Inline tests

Sebastian Peryt via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Oct 7 16:16:21 PDT 2022


speryt created this revision.
Herald added a project: All.
speryt requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

This change is updating remaining Inline tests
by removing -enable-new-pm=0 flag and adjusting CHECKs
where it is required.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D135497

Files:
  llvm/test/Transforms/Inline/alloca-dbgdeclare-merge.ll
  llvm/test/Transforms/Inline/externally_available.ll
  llvm/test/Transforms/Inline/inline-cold.ll
  llvm/test/Transforms/Inline/null-function.ll


Index: llvm/test/Transforms/Inline/null-function.ll
===================================================================
--- llvm/test/Transforms/Inline/null-function.ll
+++ /dev/null
@@ -1,9 +0,0 @@
-; RUN: opt -print-before=always-inline -always-inline -enable-new-pm=0 < %s -o /dev/null 2>&1 | FileCheck %s
-
-define i32 @main() #0 {
-entry:
-  ret i32 0
-}
-
-; CHECK: *** IR Dump Before Inliner for always_inline functions (always-inline) ***
-; CHECK: Printing <null> Function
Index: llvm/test/Transforms/Inline/inline-cold.ll
===================================================================
--- llvm/test/Transforms/Inline/inline-cold.ll
+++ llvm/test/Transforms/Inline/inline-cold.ll
@@ -2,7 +2,7 @@
 ; Test that functions with attribute Cold are not inlined while the 
 ; same function without attribute Cold will be inlined.
 
-; RUN: opt < %s -passes='require<profile-summary>,cgscc(inline)' -S -inline-threshold=600 -enable-new-pm=0 | FileCheck %s -check-prefix=OVERRIDE
+; RUN: opt < %s -passes='require<profile-summary>,cgscc(inline)' -S -inline-threshold=600 | FileCheck %s -check-prefix=OVERRIDE
 ; The command line argument for inline-threshold should override
 ; the default cold threshold, so a cold function with size bigger
 ; than the default cold threshold (225) will be inlined.
Index: llvm/test/Transforms/Inline/externally_available.ll
===================================================================
--- llvm/test/Transforms/Inline/externally_available.ll
+++ llvm/test/Transforms/Inline/externally_available.ll
@@ -1,4 +1,4 @@
-; RUN: opt < %s -inline -S -enable-new-pm=0 | FileCheck %s
+; RUN: opt < %s -inline -S | FileCheck %s
 
 define available_externally i32 @test_function() {
 ; CHECK-NOT: @test_function
Index: llvm/test/Transforms/Inline/alloca-dbgdeclare-merge.ll
===================================================================
--- llvm/test/Transforms/Inline/alloca-dbgdeclare-merge.ll
+++ llvm/test/Transforms/Inline/alloca-dbgdeclare-merge.ll
@@ -18,19 +18,20 @@
 ;  g();
 ;}
 ;
-; RUN: opt -always-inline -S -enable-new-pm=0 < %s | FileCheck %s
+; RUN: opt -passes='always-inline' -S < %s | FileCheck %s
 
-; FIXME: Why does the dbg.declare for "aaa" occur later in @h than the
-; dbg.declare for "bbb"? I'd expect the opposite, given @f is inlined earlier.
-;
 ; CHECK:      define void @h()
 ; CHECK-NEXT: entry:
+; CHECK-NEXT:   %[[BI:.*]] = alloca [100 x i8]
 ; CHECK-NEXT:   %[[AI:.*]] = alloca [100 x i8]
-; CHECK-NEXT:   call void @llvm.dbg.declare(metadata [100 x i8]* %[[AI]], metadata [[BBB:![0-9]+]]
-; CHECK-NEXT:   bitcast
+; CHECK-NEXT:   bitcast [100 x i8]* %[[AI]]
 ; CHECK-NEXT:   llvm.lifetime.start
 ; CHECK-NEXT:   call void @llvm.dbg.declare(metadata [100 x i8]* %[[AI]], metadata [[AAA:![0-9]+]]
 
+; CHECK:        bitcast [100 x i8]* %[[BI]]
+; CHECK-NEXT:   llvm.lifetime.start
+; CHECK-NEXT:   call void @llvm.dbg.declare(metadata [100 x i8]* %[[BI]], metadata [[BBB:![0-9]+]]
+
 ; CHECK: [[AAA]] = !DILocalVariable(name: "aaa"
 ; CHECK: [[BBB]] = !DILocalVariable(name: "bbb"
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D135497.466215.patch
Type: text/x-patch
Size: 3056 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20221007/7febd08a/attachment.bin>


More information about the llvm-commits mailing list