on 04/04/2013 20:16 John Baldwin said the following: > On Thursday, April 04, 2013 12:16:32 pm Andriy Gapon wrote: >> diff --git a/sys/boot/i386/zfsboot/zfsboot.c > b/sys/boot/i386/zfsboot/zfsboot.c >> index 82402b6..12ceeb0 100644 >> --- a/sys/boot/i386/zfsboot/zfsboot.c >> +++ b/sys/boot/i386/zfsboot/zfsboot.c >> _at__at_ -374,6 +374,16 _at__at_ bios_getmem(void) >> } >> >> /* >> + * If extended memory is at least twice as large as the largest >> + * region of higher memory, then carve the high heap out of >> + * extended memory. >> + */ >> + if (bios_extmem > 2 * high_heap_size) { >> + high_heap_base = 0x100000 + bios_extmem / 2; >> + high_heap_size = bios_extmem / 2; >> + } >> + >> + /* >> * If we have extended memory and did not find a suitable heap >> * region in the SMAP, use the last 3MB of 'extended' memory as a >> * high heap candidate. >> > > We should really use the same algorithm in boot2 and gptboot as well. Yes, this is just something to start with. BTW, all other components use bios_getmem from sys/boot/i386/libi386/biosmem.c ? > I think though that in this case you can just use the last 3MB of heap > rather than half of the extended memory as heap. I thought the more the better? :-) I've kept the block of code that tries to make high_heap_size at least 3MB. -- Andriy GaponReceived on Thu Apr 04 2013 - 16:01:47 UTC
This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:36 UTC