]> granicus.if.org Git - clang/commit
msabi: Fix exponential mangling time for even more contrived inputs
authorNico Weber <nicolasweber@gmx.de>
Tue, 4 Jun 2019 23:27:40 +0000 (23:27 +0000)
committerNico Weber <nicolasweber@gmx.de>
Tue, 4 Jun 2019 23:27:40 +0000 (23:27 +0000)
commit31328963a09f9781c9ace84b9f49ff5fdd79b6be
tree181f3e65cfd6941879ee457a5b66541ea22b23a4
parent45371fed1e3447f0161ebf6f62dda55b84f8df7b
msabi: Fix exponential mangling time for even more contrived inputs

This is a follow-up to r362293 which fixed exponential time needed
for mangling certain templates. This fixes the same issue if that
template pattern happens in template arguments > 10: The first
ten template arguments can use back references, and r362293 added
caching for back references. For latter arguments, we have to add
a cache for the mangling itself instead.

Fixes PR42091 even more.

Differential Revision: https://reviews.llvm.org/D62780

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@362560 91177308-0d34-0410-b5e6-96231b3b80d8
lib/AST/MicrosoftMangle.cpp
test/CodeGenCXX/mangle-ms-back-references-pr13207.cpp