Skip to content

Use of Memory Efficient Data Structures Micro-Optimization #1785

@CamiloFallaM

Description

@CamiloFallaM

Hi Kickstarter Team

My name is Camilo Falla and I´m a student at Universidad de Los Andes in Bogotá, Colombia studying Computer Science. I had the opportunity to take a look into the Kotlin repository in GitHub and found some micro-optimization ideas I would like to share with you. The ideas have to do with the use of memory efficient data structures. In the file TrackingClientType.kt I found that HashMaps were used but the order of the added values was always the same. In that sense, you could use an ArrayList to save thee values in the know order without having to save the keys into memory, having a better performance and memory consumption.

This would be the changes I would make on the file:

image

image

I think this micro-optimization would have a positive impact on the general application´s memory consumption. We hope you can take it into account in the future!

Best regards,
Camilo Falla, Carlos Silva, Juan José Beltrán

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions