Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

* fixed OOM that happens when compiling class with huge amount of fie… #485

Merged
merged 1 commit into from
May 26, 2020

Conversation

dkimitsa
Copy link
Contributor

  • fixed OOM that happens when compiling class with huge amount of fields (like 8K).

Root case of this -- huge ClassType struct (about 170KB), that uses multiple times in raw form and this causes huge .ll string outputclass: for example for class with 8K fields: 8K * 3 * 170KB ~ 4GB data only for Class Type.
The fix introduces typedef for it and uses alias.

…lds (like 8K). Root case of this -- huge ClassType struct (about 170KB), class type struct was used directly without typedef, three times per field. as result it requires 24K * 170KB ~ 4GB data only for Class Type. The fix introduces typedef for it and uses alias.
@dkimitsa
Copy link
Contributor Author

numbers received during test run (dummy sample project):

  • size of .ll code generated reduced 162Mb -> 133Mb
  • heap pressure reduced 1145Mb->950Mb
    few more words in the post

@dkimitsa dkimitsa mentioned this pull request May 25, 2020
@Tom-Ski Tom-Ski merged commit 0c5e12c into MobiVM:master May 26, 2020
@dkimitsa dkimitsa deleted the fix-oom-huge-field-count branch May 27, 2020 14:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants