OSDN Git Service

[PowerPC] Fix memory corruption in AsmParser
authorUlrich Weigand <ulrich.weigand@de.ibm.com>
Mon, 6 May 2013 11:16:57 +0000 (11:16 +0000)
committerUlrich Weigand <ulrich.weigand@de.ibm.com>
Mon, 6 May 2013 11:16:57 +0000 (11:16 +0000)
commit7d55b6bb1a4a5220ef973cf7b68ae508859a9b71
tree718d6e6da4f4ddff94cde73d4c53cdee329af29e
parent5d042c63741bc5ccec8ad18bfebf9f621fcde640
[PowerPC] Fix memory corruption in AsmParser

As pointed out by Evgeniy Stepanov, assigning a std::string temporary
to a StringRef is not a good idea.  Rework MatchRegisterName to avoid
using the .lower routine.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@181192 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/PowerPC/AsmParser/PPCAsmParser.cpp