public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [Patch v3 0/3] Optimize load uCode performance
@ 2018-07-16  3:08 Eric Dong
  2018-07-16  3:08 ` [Patch v3 1/3] UefiCpuPkg/MpInitLib: Relocate uCode to memory to save time Eric Dong
                   ` (3 more replies)
  0 siblings, 4 replies; 14+ messages in thread
From: Eric Dong @ 2018-07-16  3:08 UTC (permalink / raw)
  To: edk2-devel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1069 bytes --]

Use below three rules to optimize load uCode performance:
1. Let BSP relocate uCode from flash to memory for better performance.
2. BSP caches the CPU ID and address of uCode so AP doesn’t need to look 
   for the uCode again if the CPU ID is same as BSP’s.
3. Only apply uCode in one thread of a core when hyper threading is enabled.

v2 changes:
  Fix potential issue if allocate memory failed.

V3 Changes:
  Remove the ASSERT code which is not correct.

Test:
Use an sample platform which has 1 socket, 4 core, 8 threads, the 
CpuMpPei driver cost time reduce from 108.4ms to 27.2ms


Eric Dong (3):
  UefiCpuPkg/MpInitLib: Use BSP uCode for APs if possible.
  UefiCpuPkg/MpInitLib: Load uCode once for each core.
  UefiCpuPkg/MpInitLib: Relocate uCode to memory to save time.

 UefiCpuPkg/Library/MpInitLib/Microcode.c | 43 +++++++++++++++++++++++++++++---
 UefiCpuPkg/Library/MpInitLib/MpLib.c     | 38 +++++++++++++++++++++++++---
 UefiCpuPkg/Library/MpInitLib/MpLib.h     | 11 ++++++--
 3 files changed, 84 insertions(+), 8 deletions(-)

-- 
2.15.0.windows.1



^ permalink raw reply	[flat|nested] 14+ messages in thread
* [Patch v3 0/3] Optimize load uCode performance
@ 2018-07-13  0:47 Eric Dong
  2018-07-13  0:47 ` [Patch v3 2/3] UefiCpuPkg/MpInitLib: Use BSP uCode for APs if possible Eric Dong
  0 siblings, 1 reply; 14+ messages in thread
From: Eric Dong @ 2018-07-13  0:47 UTC (permalink / raw)


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1069 bytes --]

Use below three rules to optimize load uCode performance:
1. Let BSP relocate uCode from flash to memory for better performance.
2. BSP caches the CPU ID and address of uCode so AP doesn’t need to look 
   for the uCode again if the CPU ID is same as BSP’s.
3. Only apply uCode in one thread of a core when hyper threading is enabled.

v2 changes:
  Fix potential issue if allocate memory failed.

V3 Changes:
  Remove the ASSERT code which is not correct.

Test:
Use an sample platform which has 1 socket, 4 core, 8 threads, the 
CpuMpPei driver cost time reduce from 108.4ms to 27.2ms


Eric Dong (3):
  UefiCpuPkg/MpInitLib: Use BSP uCode for APs if possible.
  UefiCpuPkg/MpInitLib: Load uCode once for each core.
  UefiCpuPkg/MpInitLib: Relocate uCode to memory to save time.

 UefiCpuPkg/Library/MpInitLib/Microcode.c | 43 +++++++++++++++++++++++++++++---
 UefiCpuPkg/Library/MpInitLib/MpLib.c     | 38 +++++++++++++++++++++++++---
 UefiCpuPkg/Library/MpInitLib/MpLib.h     | 11 ++++++--
 3 files changed, 84 insertions(+), 8 deletions(-)

-- 
2.15.0.windows.1



^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2018-07-19  4:44 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-07-16  3:08 [Patch v3 0/3] Optimize load uCode performance Eric Dong
2018-07-16  3:08 ` [Patch v3 1/3] UefiCpuPkg/MpInitLib: Relocate uCode to memory to save time Eric Dong
2018-07-17 10:02   ` Ni, Ruiyu
2018-07-16  3:08 ` [Patch v3 2/3] UefiCpuPkg/MpInitLib: Use BSP uCode for APs if possible Eric Dong
2018-07-17 10:00   ` Ni, Ruiyu
2018-07-16  3:08 ` [Patch v3 3/3] UefiCpuPkg/MpInitLib: Load uCode once for each core Eric Dong
2018-07-17 10:02   ` Ni, Ruiyu
2018-07-17 14:07     ` Laszlo Ersek
2018-07-18  0:11       ` Dong, Eric
2018-07-19  4:42         ` Ni, Ruiyu
2018-07-17 16:38 ` [Patch v3 0/3] Optimize load uCode performance Laszlo Ersek
2018-07-17 19:08   ` Laszlo Ersek
2018-07-18  0:18   ` Dong, Eric
  -- strict thread matches above, loose matches on Subject: below --
2018-07-13  0:47 Eric Dong
2018-07-13  0:47 ` [Patch v3 2/3] UefiCpuPkg/MpInitLib: Use BSP uCode for APs if possible Eric Dong

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox