]> git.proxmox.com Git - mirror_edk2.git/commit
ArmVirtPkg: increase memory preallocations to reduce region count
authorArd Biesheuvel <ard.biesheuvel@linaro.org>
Wed, 3 Jun 2015 16:11:47 +0000 (16:11 +0000)
committerabiesheuvel <abiesheuvel@Edk2>
Wed, 3 Jun 2015 16:11:47 +0000 (16:11 +0000)
commitc1993157bd81e5ab440cf24ef77b0b3fb325e89f
treef6475f3ef1761afa4ed14cfff7c8fababd227643
parentbaae777b8e6370ab856ec9088864ab698f5e9b0f
ArmVirtPkg: increase memory preallocations to reduce region count

This updates the sizes of the preallocated regions so that the number
of distinct regions that exists is minimal at the time we exit boot
services.

For a typical run of the ArmVirtQemu platform, we get the following
utilization numbers:

  Reserved  :              4 Pages (16,384 Bytes)
  LoaderCode:            210 Pages (860,160 Bytes)
  LoaderData:              0 Pages (0 Bytes)
  BS_Code   :            355 Pages (1,454,080 Bytes)
  BS_Data   :          6,807 Pages (27,881,472 Bytes)
  RT_Code   :            112 Pages (458,752 Bytes)
  RT_Data   :            288 Pages (1,179,648 Bytes)
  ACPI_Recl :             32 Pages (131,072 Bytes)
  ACPI_NVS  :              0 Pages (0 Bytes)
  MMIO      :         16,385 Pages (67,112,960 Bytes)
  MMIO_Port :              0 Pages (0 Bytes)
  PalCode   :              0 Pages (0 Bytes)
  Available :        123,264 Pages (504,889,344 Bytes)
              --------------
Total Memory:            511 MB (536,854,528 Bytes)

Strangely enough, the allocation count of 20,000 pages for BS_Data
does not result in those regions being merged. For BS_Code, RT_Code
and RT_Data, the increased preallocation results in the following
reduction in the number of regions.

   0x000040000000-0x00004000ffff [Loader Data        |   |  |  |  |   |WB|WT|WC|UC]
-  0x000040010000-0x0000b66bbfff [Conventional Memory|   |  |  |  |   |WB|WT|WC|UC]
-  0x0000b66bc000-0x0000b66d0fff [Loader Data        |   |  |  |  |   |WB|WT|WC|UC]
-  0x0000b66d1000-0x0000b6f6bfff [Loader Code        |   |  |  |  |   |WB|WT|WC|UC]
-  0x0000b6f6c000-0x0000b6f6ffff [Reserved           |   |  |  |  |   |WB|WT|WC|UC]*
-  0x0000b6f70000-0x0000b6f8ffff [Runtime Code       |RUN|  |  |  |   |WB|WT|WC|UC]*
-  0x0000b6f90000-0x0000b6faffff [ACPI Reclaim Memory|   |  |  |  |   |WB|WT|WC|UC]*
-  0x0000b6fb0000-0x0000b6fcffff [Runtime Code       |RUN|  |  |  |   |WB|WT|WC|UC]*
-  0x0000b6fd0000-0x0000b701ffff [Runtime Data       |RUN|  |  |  |   |WB|WT|WC|UC]*
-  0x0000b7020000-0x0000b702ffff [Runtime Code       |RUN|  |  |  |   |WB|WT|WC|UC]*
-  0x0000b7030000-0x0000b70cffff [Runtime Data       |RUN|  |  |  |   |WB|WT|WC|UC]*
-  0x0000b70d0000-0x0000b70dffff [Runtime Code       |RUN|  |  |  |   |WB|WT|WC|UC]*
+  0x000040010000-0x0000b680bfff [Conventional Memory|   |  |  |  |   |WB|WT|WC|UC]
+  0x0000b680c000-0x0000b6820fff [Loader Data        |   |  |  |  |   |WB|WT|WC|UC]
+  0x0000b6821000-0x0000b70bbfff [Loader Code        |   |  |  |  |   |WB|WT|WC|UC]
+  0x0000b70bc000-0x0000b70bffff [Reserved           |   |  |  |  |   |WB|WT|WC|UC]*
+  0x0000b70c0000-0x0000b70dffff [ACPI Reclaim Memory|   |  |  |  |   |WB|WT|WC|UC]*
   0x0000b70e0000-0x0000b9f87fff [Conventional Memory|   |  |  |  |   |WB|WT|WC|UC]
   0x0000b9f88000-0x0000bb921fff [Boot Data          |   |  |  |  |   |WB|WT|WC|UC]
   0x0000bb922000-0x0000bb9bffff [Conventional Memory|   |  |  |  |   |WB|WT|WC|UC]
   0x0000bb9c0000-0x0000bbbb0fff [Boot Data          |   |  |  |  |   |WB|WT|WC|UC]
   0x0000bbbb1000-0x0000bbbeffff [Conventional Memory|   |  |  |  |   |WB|WT|WC|UC]
   0x0000bbbf0000-0x0000bbf1ffff [Boot Data          |   |  |  |  |   |WB|WT|WC|UC]
-  0x0000bbf20000-0x0000bedfffff [Conventional Memory|   |  |  |  |   |WB|WT|WC|UC]
-  0x0000bee00000-0x0000bf71ffff [Loader Data        |   |  |  |  |   |WB|WT|WC|UC]
-  0x0000bf720000-0x0000bf7ccfff [Conventional Memory|   |  |  |  |   |WB|WT|WC|UC]
-  0x0000bf7cd000-0x0000bf92ffff [Boot Code          |   |  |  |  |   |WB|WT|WC|UC]
-  0x0000bf930000-0x0000bf93ffff [Runtime Code       |RUN|  |  |  |   |WB|WT|WC|UC]*
-  0x0000bf940000-0x0000bf95ffff [Conventional Memory|   |  |  |  |   |WB|WT|WC|UC]
-  0x0000bf960000-0x0000bf97ffff [Runtime Data       |RUN|  |  |  |   |WB|WT|WC|UC]*
+  0x0000bbf20000-0x0000bebfffff [Conventional Memory|   |  |  |  |   |WB|WT|WC|UC]
+  0x0000bec00000-0x0000bf51ffff [Loader Data        |   |  |  |  |   |WB|WT|WC|UC]
+  0x0000bf520000-0x0000bf65cfff [Conventional Memory|   |  |  |  |   |WB|WT|WC|UC]
+  0x0000bf65d000-0x0000bf7bffff [Boot Code          |   |  |  |  |   |WB|WT|WC|UC]
+  0x0000bf7c0000-0x0000bf84ffff [Runtime Code       |RUN|  |  |  |   |WB|WT|WC|UC]*
+  0x0000bf850000-0x0000bf86ffff [Conventional Memory|   |  |  |  |   |WB|WT|WC|UC]
+  0x0000bf870000-0x0000bf97ffff [Runtime Data       |RUN|  |  |  |   |WB|WT|WC|UC]*
   0x0000bf980000-0x0000bf997fff [Conventional Memory|   |  |  |  |   |WB|WT|WC|UC]
   0x0000bf998000-0x0000bf99afff [Boot Data          |   |  |  |  |   |WB|WT|WC|UC]
   0x0000bf99b000-0x0000bf9aefff [Conventional Memory|   |  |  |  |   |WB|WT|WC|UC]

Contributed-under: TianoCore Contribution Agreement 1.0
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@17554 6f19259b-4bc3-4df7-8a09-765794883524
ArmVirtPkg/ArmVirt.dsc.inc