From 85d8b2bbe386bcfe669575d05b61482d7be07e5d Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Tue, 9 Jun 2015 19:06:30 +0000 Subject: Vendor import of llvm trunk r239412: https://llvm.org/svn/llvm-project/llvm/trunk@239412 --- test/CodeGen/MIR/machine-function-missing-name.mir | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 test/CodeGen/MIR/machine-function-missing-name.mir (limited to 'test/CodeGen/MIR/machine-function-missing-name.mir') diff --git a/test/CodeGen/MIR/machine-function-missing-name.mir b/test/CodeGen/MIR/machine-function-missing-name.mir new file mode 100644 index 000000000000..54668f1a5efe --- /dev/null +++ b/test/CodeGen/MIR/machine-function-missing-name.mir @@ -0,0 +1,22 @@ +# RUN: not llc -start-after branch-folder -stop-after branch-folder -o /dev/null %s 2>&1 | FileCheck %s +# This test ensures that an error is reported when a machine function doesn't +# have a name attribute. + +--- | + + define i32 @foo() { + ret i32 0 + } + + define i32 @bar() { + ret i32 0 + } + +... +--- +# CHECK: [[@LINE+1]]:1: error: missing required key 'name' +nme: foo +... +--- +name: bar +... -- cgit v1.3