Re:FreeBSD replaces bubblesort with mergesort on SYSINTs, re...
by magicalhippo on Monday August 21, 2023 @01:16AM
(#37205733)
Why the hash stack limit? I assume this precludes a fixed-size array.
[ Parent
| on HN ]
Re:FreeBSD replaces bubblesort with mergesort on SYSINTs, re...
by ahoka on Monday August 21, 2023 @06:21AM
(#37207499)
I'm not sure when this sort happens, but early boot may not have a proper virtual memory implementation yet, so the kernel has to use a fixed stack size allocated by the boot loader.
Re:FreeBSD replaces bubblesort with mergesort on SYSINTs, re...
by kevans91 on Monday August 21, 2023 @12:20PM
(#37211682)
Right, in this case specifically we're running off a limited bootstack allocated in the kernel's .bss (somewhere between 2 to 6 pages, generally); we won't finish initializing VM until shortly after this sort is done (in some of the SYSINITs that we're sorting).