On Sun, 26 Mar 2023 at 18:15, Michael van Elst <mlelstv%serpens.de@localhost> wrote: > > abs%netbsd.org@localhost (David Brownlee) writes: > > >That would be the ideal "default" case - though would that most likely > >involve loading the kernel first into the largest segment, > > There is no "default" case. Often you have a mixed zoo of memory regions > and the largest region isn't necessarily the best choice for the kernel. > > Using the region with the highest priority (usually the fastet, not the > largest) can be a good default. Unless you think that your application > code can use that memory better than the kernel. > > Also, with todays kernel sizes, there is often no choice. Hence this discussion on adjusting default behaviour :) A default of "pick the highest priority region which into which the kernel would fit" should do the optimal option of putting the kernel into the fastest memory where possible, falling back to slower memory where not possible, while (crucially) not failing to boot if any higher priority regions are too small. If implementing "kernel would fit" would be too complex, then an alternative of "pick the highest priority region which is at least 8 MB" (and allowing both the 8 to be adjusted, and for the behaviour to be overridden to pick the largest) should allow optimal option in *almost all* cases, with a very low risk of failing to boot if someone builds an unusual kernel. Thanks DAvid