From 9eacda51fa23abf4f6503ff533dcb70071cbe569 Mon Sep 17 00:00:00 2001 From: Chris Jackson Date: Tue, 26 May 2020 22:33:59 +0100 Subject: [PATCH] [debuginfo] Fix broken tests from MachineLICM salvaging fix Previous commit: bd7ff5d94f - Added missing x86 triples - Added missing asserts --- llvm/test/DebugInfo/MIR/X86/mlicm-hoist-post-regalloc.mir | 4 +++- llvm/test/DebugInfo/MIR/X86/mlicm-hoist-pre-regalloc.mir | 3 ++- llvm/test/DebugInfo/MIR/X86/mlicm-sink.mir | 1 + 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/llvm/test/DebugInfo/MIR/X86/mlicm-hoist-post-regalloc.mir b/llvm/test/DebugInfo/MIR/X86/mlicm-hoist-post-regalloc.mir index 97cdea090c9c..8b6e160cd92a 100644 --- a/llvm/test/DebugInfo/MIR/X86/mlicm-hoist-post-regalloc.mir +++ b/llvm/test/DebugInfo/MIR/X86/mlicm-hoist-post-regalloc.mir @@ -1,5 +1,6 @@ --- | - ; RUN: llc -start-before=phi-node-elimination -stop-after=machinelicm -o - %s | FileCheck %s + ; REQUIRES: asserts + ; RUN: llc -start-before=phi-node-elimination -stop-after=machinelicm -debug-only=machinelicm -o - %s | FileCheck %s ; Ensure we execute machinelicm post register allocation. ; Line numbers should not be retained when loop invariant instructions are hoisted. ; @@ -7,6 +8,7 @@ ; CHECK: MOV64rm $rip, 1, $noreg, target-flags(x86-gotpcrel) @x, $noreg :: (load 8 from got) ; CHECK-LABEL: bb.1.while.body: ; + target triple = "x86_64-unknown-linux-gnu" @x = common local_unnamed_addr global i32 0, align 4, !dbg !0 diff --git a/llvm/test/DebugInfo/MIR/X86/mlicm-hoist-pre-regalloc.mir b/llvm/test/DebugInfo/MIR/X86/mlicm-hoist-pre-regalloc.mir index 8c0eb376eb40..fa5da8f1fe4c 100644 --- a/llvm/test/DebugInfo/MIR/X86/mlicm-hoist-pre-regalloc.mir +++ b/llvm/test/DebugInfo/MIR/X86/mlicm-hoist-pre-regalloc.mir @@ -1,4 +1,4 @@ ---- | +--- | ; RUN: llc -run-pass=machinelicm -o - %s | FileCheck %s ; Line numbers should not be retained when loop invariant instructions are hoisted. ; Doing so causes poor stepping bevavior. @@ -23,6 +23,7 @@ ; ; ModuleID = 'tx.ll' source_filename = "t.c" + target triple = "x86_64-unknown-linux-gnu" @x = common local_unnamed_addr global i32 0, align 4, !dbg !0 diff --git a/llvm/test/DebugInfo/MIR/X86/mlicm-sink.mir b/llvm/test/DebugInfo/MIR/X86/mlicm-sink.mir index 7b5a19ffa9e7..24fbe71b2a34 100644 --- a/llvm/test/DebugInfo/MIR/X86/mlicm-sink.mir +++ b/llvm/test/DebugInfo/MIR/X86/mlicm-sink.mir @@ -4,6 +4,7 @@ ; CHECK: %0:gr64 = nuw ADD64ri8 %9, 4, implicit-def dead $eflags ; ; When instructions are sunk to prevent register spills, line numbers should not be retained. + target triple = "x86_64-unknown-linux-gnu" %struct.A = type { i32, i32, i32, i32, i32, i32 } -- GitLab