Redundant temporary interface variables
Original Reporter info from Mantis: Gorelkin
-
Reporter name: Sergei Gorelkin
Original Reporter info from Mantis: Gorelkin
- Reporter name: Sergei Gorelkin
Description:
As originally reported by Max Rusov at freepascal.ru forum, after fixing #14019 (closed) it appears that calling just any method of an interface stored in a field of an object makes compiler generate a temporary interface variable. This is a negative impact on both executable size and performance.
See the assembler listing of provided test file: in procedure tobj.test1 there is one temporary interface while it is not needed, and in procedure tobj.test2 there are three, while only two are needed.
Mantis conversion info:
- Mantis ID: 14092
- Version: 2.5.1
- Fixed in version: 2.6.0
- Fixed in revision: 15880 (#3a07adf2)
- Monitored by: » luizamerico (Luiz Americo), » @marcoonthegit (Marco van de Voort), » @MageSlayer (Denis Golovan)