evas: reduce useless allocation during destruction of image.
authorCedric BAIL <cedric.bail@free.fr>
Fri, 6 Dec 2019 00:35:23 +0000 (16:35 -0800)
committerJongmin Lee <jm105.lee@samsung.com>
Wed, 11 Dec 2019 21:23:08 +0000 (06:23 +0900)
commit72acaf9aa70e6dfe2cad9651b9a96849b6685722
treebbcf15eaecc1a077e027806b72225f73f3ff4071
parent0294fb0b9bb3d1e45a336b57ea01a47c4b12ca27
evas: reduce useless allocation during destruction of image.

Evas image use a GC to reduce duplicated state accross multiple object.
Still during shutdown we do clean it up and free it. There is no point
to push that down the GC if we are to just free it after. Relying on
the fact that dynamic content will avoid triggering the GC altogether
as their content change to frequently and is expected to be uniq among
other objects, we can avoid unecessary allocation during the destruction
by just switching that early on during the destructor.

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D10815
src/lib/evas/canvas/evas_object_image.c