From 558f5d2a396c533ddceb9ff278fcb2b76641c0f2 Mon Sep 17 00:00:00 2001
From: Chris Lattner
LLVM does not use RTTI (e.g. dynamic_cast<>) or exceptions, in an +effort to reduce code and executable size. These two language features violate +the general C++ principle of "you only pay for what you use", causing executable +bloat even if exceptions are never used in a code base, or if RTTI is never used +for a class. Because of this, we turn them off globally in the code. +
+ ++That said, LLVM does make extensive use of a hand-rolled form of RTTI that use +templates like isa<>, cast<>, +and dyn_cast<>. This form of RTTI is opt-in and can be added to any +class. It is also substantially more efficient than dynamic_cast<>. +
+ +