aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Lex/ModuleMap.cpp
diff options
context:
space:
mode:
authorHoward Hinnant <hhinnant@apple.com>2012-01-13 01:22:31 +0000
committerHoward Hinnant <hhinnant@apple.com>2012-01-13 01:22:31 +0000
commit50f7eeec9d15a6965eeceb1c4b7d0356642a53a8 (patch)
tree22ec469f3bb00d5487bb4049e950147d9ec081da /clang/lib/Lex/ModuleMap.cpp
parentda4fda73647f7ab8cdf2e5d76d6ad8825db62dfe (diff)
downloadllvm-50f7eeec9d15a6965eeceb1c4b7d0356642a53a8.zip
llvm-50f7eeec9d15a6965eeceb1c4b7d0356642a53a8.tar.gz
llvm-50f7eeec9d15a6965eeceb1c4b7d0356642a53a8.tar.bz2
Enclosed is a stress test for dynamic_cast. It stresses both libc++abi, and clang itself. It creates a ridiculously large class hierarchy using variadic templates. You can specify both the width and depth of the class hierarchy. And you can specify whether the cast is to the actual run time type, or to an intermediate layer in the class. About 1/3 of the time I compile this, it crashes the compiler. There seems to be an uninitialized area of memory, and I'm probably blowing past an assumption on class hierarchy size within clang (and understandably so). I can get it work most of the time with a class hierarchy width of 20 and a depth of 7. I'm making timings with both -O3 and -Os, using both cast to root and cast to intermediate, on both libc++abi, and gcc's dynamic_cast. I've put the results in a comment/table at the bottom of the test.
llvm-svn: 148083
Diffstat (limited to 'clang/lib/Lex/ModuleMap.cpp')
0 files changed, 0 insertions, 0 deletions