Skip to content

[RFC] Improve/clarify versioninfo output#61390

Open
christiangnrd wants to merge 7 commits intoJuliaLang:masterfrom
christiangnrd:versioninfo
Open

[RFC] Improve/clarify versioninfo output#61390
christiangnrd wants to merge 7 commits intoJuliaLang:masterfrom
christiangnrd:versioninfo

Conversation

@christiangnrd
Copy link
Copy Markdown
Contributor

@christiangnrd christiangnrd commented Mar 21, 2026

**Best reviewed with "Ignore whitespace"

When looking into #61292, I tried to use versioninfo to get the JIT’s cpu target. I found out that even though it shares parentheses with “ORCJIT”, the displayed cpu is always just the host CPU.

Then I fell into the confusing and undocumented output of versioninfo rabbit hole trying to improve it and this is the result of that. Once I have a better idea about which changes are/aren't welcome, I’ll edit the docstring to be more explicit about what each item is.

May be worth reviewing per-commit as I've tried to separate each change

This PR:

  • Changes “GB” and “MB” to “GiB” and “MiB” when reporting memory information.
  • Hides WORD_SIZE behind the verbose flag.
  • Moves the detected host cpu llvm target to be with the CPU instead of in the LLVM section. I changed this because the previous way implied it was the JIT target cpu. They usually match, but they may not if julia was launched with the -C flag
  • The build commit has been moved down into “Build Information”
  • Refactors the “Build Information” section. It will now always be shown, and the GC julia was built with was moved from the “Platform Information” section.
  • Adds the target cpu and triple that the base system image was built with when verbose=true. This adds a new Sys.BASE_SYSIMG_TARGET constant variable because calling sysimage_target from InteractiveUtils returns “sysimage”. Hidden behind verbose flag
  • LLVM section now reports the JIT target CPU where the host CPU use to be. This expands/uses API that was added by @gbaraldi for GPUCompiler in Expose the Julia JIT with a C API #49858.
  • The triple on the OS line is now the JIT target triple (same implementations worries as above), and the build machine triple (MACHINE) is now reported in the verbose-only sysimage line in “Build Information”. This is probably more relevant on macOS, where the triple includes the kernel version, but I find it confusing to show the build kernel version when reporting the current OS.

Current output (master):

julia> versioninfo()
Julia Version 1.14.0-DEV.1927
Commit 7d591fcb00c (2026-03-21 05:36 UTC)
Build Info:
  Official https://julialang.org release
Platform Info:
  OS: macOS (arm64-apple-darwin24.0.0)
  CPU: 12 × Apple M2 Max
  WORD_SIZE: 64
  LLVM: libLLVM-20.1.8 (ORCJIT, apple-m2)
  GC: Built with stock GC
Threads: 1 default, 1 interactive, 1 GC (on 8 virtual cores)

julia> versioninfo(verbose=true)
Julia Version 1.14.0-DEV.1927
Commit 7d591fcb00c (2026-03-21 05:36 UTC)
Build Info:
  Official https://julialang.org release
Platform Info:
  OS: macOS (arm64-apple-darwin24.0.0)
  uname: Darwin 25.4.0 Darwin Kernel Version 25.4.0: Thu Mar  5 21:59:20 PST 2026; root:xnu-12377.101.14~18/RELEASE_ARM64_T6020 arm64 arm
  CPU: Apple M2 Max:
                 speed         user         nice          sys         idle          irq
       #1-12  2400 MHz      72878 s          0 s      49120 s     496724 s          0 s
  Memory: 32.0 GB (1832.421875 MB free)
  Uptime: 171177.0 sec
  Load Avg:  3.67041015625  4.4208984375  4.2578125
  WORD_SIZE: 64
  LLVM: libLLVM-20.1.8 (ORCJIT, apple-m2)
  GC: Built with stock GC
Threads: 1 default, 1 interactive, 1 GC (on 8 virtual cores)
Environment:

This PR:

julia> versioninfo()
Julia Version 1.14.0-DEV.1940
Build Info:
  Official https://julialang.org release
  Commit: 756eb8be874 (2026-03-24 13:31 UTC)
  GC: Built with stock GC
Platform Info:
  OS: macOS (arm64-apple-darwin25.4.0)
  CPU: 12 × Apple M2 Max (apple-m2)
  LLVM: libLLVM-20.1.8 (ORCJIT, apple-m2)
Threads: 1 default, 1 interactive, 1 GC (on 8 virtual cores)

julia> versioninfo(verbose=true)
Julia Version 1.14.0-DEV.1940
Build Info:
  Official https://julialang.org release
  Commit: 756eb8be874 (2026-03-24 13:31 UTC)
  GC: Built with stock GC
  Sysimage: generic;apple-m1,clone_all (arm64-apple-darwin24.0.0)
Platform Info:
  OS: macOS (arm64-apple-darwin25.4.0)
  uname: Darwin 25.4.0 Darwin Kernel Version 25.4.0: Thu Mar  5 21:59:20 PST 2026; root:xnu-12377.101.14~18/RELEASE_ARM64_T6020 arm64 arm
  CPU: Apple M2 Max (apple-m2):
                 speed         user         nice          sys         idle          irq
       #1-12  2400 MHz     245810 s          0 s     120835 s    1650663 s          0 s
  Memory: 32.0 GiB (6047.796875 MiB free)
  Uptime: 412120.0 sec
  Load Avg:  5.1875  4.126953125  4.16015625
  WORD_SIZE: 64
  LLVM: libLLVM-20.1.8 (ORCJIT, apple-m2)
Threads: 1 default, 1 interactive, 1 GC (on 8 virtual cores)
Environment:

@christiangnrd christiangnrd force-pushed the versioninfo branch 2 times, most recently from dce83c8 to fb3c7a3 Compare March 23, 2026 17:27
@christiangnrd christiangnrd changed the title Improve/clarify versioninfo output [RFC] Improve/clarify versioninfo output Mar 24, 2026
@christiangnrd christiangnrd force-pushed the versioninfo branch 6 times, most recently from 1e477c9 to 13c35f2 Compare March 27, 2026 17:46
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.

1 participant