The Graal compiler adds the logic for dispatching an exception based on its type into the compiled code. The makeExceptionDispatch method creates a subgraph that contains this logic for a list of exception handlers. In order to reduce code size, we only compile exception handlers that have been executed at least once. - thomas