From 4b429fcf25b96a4c191420ca715057c0d9686ef3 Mon Sep 17 00:00:00 2001 From: Andrew Lenharth Date: Fri, 22 Jul 2005 21:53:35 +0000 Subject: [PATCH] make sure we always handle small negatives well git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@22503 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/CodeGen/Alpha/i32_sub_1.ll | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 test/CodeGen/Alpha/i32_sub_1.ll diff --git a/test/CodeGen/Alpha/i32_sub_1.ll b/test/CodeGen/Alpha/i32_sub_1.ll new file mode 100644 index 00000000000..ea6ab9299cd --- /dev/null +++ b/test/CodeGen/Alpha/i32_sub_1.ll @@ -0,0 +1,10 @@ +; Make sure this testcase codegens to the ctpop instruction +; RUN: llvm-as < %s | llc -march=alpha | grep -i 'subl $16,1,$0' + +implementation ; Functions: + +int %foo(int %x) { +entry: + %tmp.1 = add int %x, -1 ; [#uses=1] + ret int %tmp.1 +}