summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite/test/python_api/process/main.cpp
diff options
context:
space:
mode:
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>2015-12-10 17:56:06 +0000
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>2015-12-10 17:56:06 +0000
commit836f0ddb600f1e43dde312280c392c7ecc92c088 (patch)
tree0862c602b989f4769cd0e006ec7e0ecec90e5d6b /lldb/packages/Python/lldbsuite/test/python_api/process/main.cpp
parentbff0a21b57c698403452694b925079de9e2d0868 (diff)
downloadbcm5719-llvm-836f0ddb600f1e43dde312280c392c7ecc92c088.tar.gz
bcm5719-llvm-836f0ddb600f1e43dde312280c392c7ecc92c088.zip
Verifier: Avoid quadratic checking of aggregates for bad bitcasts
Avoid O(N^2) behaviour when checking for bad bitcasts in `ConstantExpr`s buried inside of aggregate initializers to `GlobalVariable`s. I've: - centralized the "visited" set for recursing through `ConstantExpr`s so that expressions are only visited once per Verifier run, - removed the duplicate logic for the stack visit, and - avoided recursing into other `GlobalValue`s. This recovers roughly a 100x time difference in clang compiles of a particular input file (filled with large cross-referencing tables) that depends on whether `-disable-llvm-verifier` is on. This slowdown was caused by r187506, which introduced these checks. Now, avoiding `-disable-llvm-verifier` only causes a 2x slowdown for this case. (Interestingly, dumping the textual IR for this file starts at least 50GB of global variable initializers (I don't know the total, since I killed the dump)...) llvm-svn: 255269
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/python_api/process/main.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud