**Symfony version(s) affected**: symfony/doctrine-bridge 4.4.19 - 5.2.2 **Description** When [Doctrine relationships with Abstract Classes and Interfaces](https://symfony.com/doc/current/doctrine/resolve_target_entity.html) are used, Symfony crashes with an 137 exit code (out of memory). This problem is observed since the 23d692107c81fbd584019ba82cf0ea1fb2b72443 commit. **How to reproduce** * Use [Doctrine relationships with Abstract Classes and Interfaces](https://symfony.com/doc/current/doctrine/resolve_target_entity.html) * Use Doctrine (eg: `php bin/console doctrine:schema:validate`) Tested with PHP 7.2.34, 7.3.26, 7.4.14 and 8.0.1