Skip to content

Conversation

@vtjnash
Copy link
Member

@vtjnash vtjnash commented Apr 11, 2025

Together, the commits save roughly 184 MB -> 159 MB by not storing unnecessary inferred IR

$ llvm-size -A usr/lib/julia/sys.dylib
usr/lib/julia/sys.dylib  :
section                  size        addr
__text               15522036        1904
__stubs                  1128    15523940
__stub_helper            1152    15525068
__const                438592    15526224
__cstring              297006    15964816
__unwind_info          247368    16261824
__eh_frame              27144    16509192
__got                     104    16547840
__const                   632    16547944
__la_symbol_ptr           752    16564224
__data              142444216    16564992
__common               100800   159009216
Total               159080930

@vtjnash vtjnash requested a review from JeffBezanson April 11, 2025 17:00
@vtjnash vtjnash added don't squash Don't squash merge backport 1.12 Change should be backported to release-1.12 labels Apr 12, 2025
vtjnash added 3 commits April 15, 2025 13:13
After the bindings change, there is quite a lot of garbage in here now
at runtime (it does not de-duplicate entries added for bindings), so
attempt to do a bit of that during serialization.
Compressing IR adds Methods roots, which tend to become quite expensive
to store after some time. We also used to store the inferred code, but
since we never actually look at that again now (since now the compiler
avoids using --output-ji or --sysimage-native-code=no or --pkgimages=no)
it is now quite a bit of wasted space also.

For some reason, this also generates 20% more native code in the system
image, which isn't quite clear if that is good or not.
@KristofferC KristofferC mentioned this pull request Apr 16, 2025
51 tasks
@vtjnash vtjnash merged commit 860188f into master Apr 16, 2025
3 of 4 checks passed
@vtjnash vtjnash deleted the jn/sysimg-junk branch April 16, 2025 17:27
@Zentrik
Copy link
Member

Zentrik commented Apr 17, 2025

This seems to have caused a lot of test failures.

aviatesk pushed a commit that referenced this pull request Apr 17, 2025
vtjnash added a commit that referenced this pull request Apr 20, 2025
After the bindings change, there is quite a lot of garbage in here now
at runtime (it does not de-duplicate entries added for bindings), so
attempt to do a bit of that during serialization.

Re-landing part of #58078
@KristofferC KristofferC mentioned this pull request Apr 29, 2025
53 tasks
serenity4 pushed a commit to serenity4/julia that referenced this pull request May 1, 2025
Together, the commits save roughly 184 MB -> 159 MB by not storing
unnecessary inferred IR
```
$ llvm-size -A usr/lib/julia/sys.dylib
usr/lib/julia/sys.dylib  :
section                  size        addr
__text               15522036        1904
__stubs                  1128    15523940
__stub_helper            1152    15525068
__const                438592    15526224
__cstring              297006    15964816
__unwind_info          247368    16261824
__eh_frame              27144    16509192
__got                     104    16547840
__const                   632    16547944
__la_symbol_ptr           752    16564224
__data              142444216    16564992
__common               100800   159009216
Total               159080930
```
serenity4 pushed a commit to serenity4/julia that referenced this pull request May 1, 2025
LebedevRI pushed a commit to LebedevRI/julia that referenced this pull request May 2, 2025
LebedevRI pushed a commit to LebedevRI/julia that referenced this pull request May 2, 2025
After the bindings change, there is quite a lot of garbage in here now
at runtime (it does not de-duplicate entries added for bindings), so
attempt to do a bit of that during serialization.

Re-landing part of JuliaLang#58078
@KristofferC KristofferC removed the backport 1.12 Change should be backported to release-1.12 label May 5, 2025
vtjnash added a commit that referenced this pull request Jun 5, 2025
After the bindings change, there is quite a lot of garbage in here now
at runtime (it does not de-duplicate entries added for bindings), so
attempt to do a bit of that during serialization.

Re-landing part of #58078

(cherry picked from commit 3ea60d2)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

don't squash Don't squash merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants