User loginNavigation |
The hidden cost of exception handlingI've just published a blog article about the hidden cost of exception handling that may interest some of the readers here. During a meeting today, a colleague of mine shared the belief that exception handling had no impact on optimizations in modern C++. While we did everything we could 20+ years ago to ensure that all kinds of optimizations were possible, there is a residual cost that you can trigger. In this post, I show cases where there is zero cost for exception handling in the primary execution path, but also build a few pathological cases where the compiler cannot preserve that property, and where just enabling exceptions markedly changes the primary code path, for reasons that may be related more to correctness than to optimizations, in other words, where it may not ever be possible to fully optimize without violating C++ semantics. By Christophe de Dinechin at 2022-05-10 06:23 | Site Discussion | previous forum topic | next forum topic | other blogs | 2304 reads
|
Browse archives
Active forum topics |
Recent comments
12 weeks 3 days ago
12 weeks 3 days ago
12 weeks 3 days ago
34 weeks 4 days ago
38 weeks 6 days ago
40 weeks 3 days ago
40 weeks 3 days ago
43 weeks 1 day ago
47 weeks 6 days ago
47 weeks 6 days ago