[NVPTX] Fix issue introduced in D10321
authorJingyue Wu <jingyue@google.com>
Tue, 30 Jun 2015 18:59:19 +0000 (18:59 +0000)
committerJingyue Wu <jingyue@google.com>
Tue, 30 Jun 2015 18:59:19 +0000 (18:59 +0000)
commit75cacfb4903fb4530b20773bcd482973e0e7e95d
treee384fddb2f474eb93ed04c4e34b73af25626678b
parentc408bc8e39e1e594dc545cf9d171ca133aa8393a
[NVPTX] Fix issue introduced in D10321

Summary:
Really check if %SP is not used in other places, instead of checking only exact
one non-dbg use.

Patched by Xuetian Weng.

Test Plan:
@foo4 in test/CodeGen/NVPTX/local-stack-frame.ll, create a case that
SP will appear twice.

Reviewers: jholewinski, jingyue

Reviewed By: jingyue

Subscribers: llvm-commits, sfantao, jholewinski

Differential Revision: http://reviews.llvm.org/D10844

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@241099 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/NVPTX/NVPTXFrameLowering.cpp
test/CodeGen/NVPTX/local-stack-frame.ll