Reinforce ARMTargetParser::getCanonicalArchName validation
authorRenato Golin <renato.golin@linaro.org>
Fri, 22 May 2015 20:43:30 +0000 (20:43 +0000)
committerRenato Golin <renato.golin@linaro.org>
Fri, 22 May 2015 20:43:30 +0000 (20:43 +0000)
commitebdd12cbf1372d513a41ad6be1f38e53f13dd541
tree07717e290ef30e47485c0a07632d50f02ded26c5
parent67336305f5e11b328344814998890c248c8c4517
Reinforce ARMTargetParser::getCanonicalArchName validation

Before, getCanonicalArchName was relying on parseArch() to validate the arch
name, which was a problem when other methods, that also needed to call it,
were duplicating the steps.

But to dissociate getCanonicalArchName from parseArch, we needed to make
getCanonicalArchName more robust in detecting valid arch names. It's still
not perfect, but will do for the time being, until we merge Triple with
TargetParser into a TargetDescription mega class.

llvm-svn: 238047
llvm/lib/Support/TargetParser.cpp