From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from ZXSHCAS1.zhaoxin.com (ZXSHCAS1.zhaoxin.com [203.148.12.81]) by mx.groups.io with SMTP id smtpd.web09.5867.1614055790304541502 for ; Mon, 22 Feb 2021 20:49:51 -0800 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: zhaoxin.com, ip: 203.148.12.81, mailfrom: tigerliu@zhaoxin.com) Received: from zxbjmbx1.zhaoxin.com (10.29.252.163) by ZXSHCAS1.zhaoxin.com (10.28.252.161) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1979.3; Tue, 23 Feb 2021 12:49:46 +0800 Received: from zxbjmbx2.zhaoxin.com (10.29.252.164) by zxbjmbx1.zhaoxin.com (10.29.252.163) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1979.3; Tue, 23 Feb 2021 12:49:45 +0800 Received: from zxbjmbx2.zhaoxin.com ([fe80::4d77:9dba:64a8:8ec3]) by zxbjmbx2.zhaoxin.com ([fe80::4d77:9dba:64a8:8ec3%4]) with mapi id 15.01.1979.003; Tue, 23 Feb 2021 12:49:45 +0800 From: "Tiger Liu(BJ-RD)" To: "devel@edk2.groups.io" , "fanjianfeng@byosoft.com.cn" , lersek Subject: Re: [edk2-devel] MP Services Protocol : Support Hyper threading or not Thread-Topic: [edk2-devel] MP Services Protocol : Support Hyper threading or not Thread-Index: AdcJn0mV3IaVjx52SlynVZtHRupQ/Q== Date: Tue, 23 Feb 2021 04:49:45 +0000 Message-ID: <68bdfa765dbb4d5fb40b837c90920035@zhaoxin.com> Accept-Language: zh-CN, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.29.8.50] MIME-Version: 1.0 Return-Path: TigerLiu@zhaoxin.com Content-Language: zh-CN Content-Type: multipart/alternative; boundary="_000_68bdfa765dbb4d5fb40b837c90920035zhaoxincom_"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d2FyZGluZyBvZiB0 aGlzIGVtYWlsIG9yIHRoZSBjb250ZW50IG9mIHRoaXMgZW1haWwgaXMgc3RyaWN0bHkgcHJvaGli aXRlZC4NCg== --_000_68bdfa765dbb4d5fb40b837c90920035zhaoxincom_ Content-Type: text/html; charset="gb2312" Content-Transfer-Encoding: quoted-printable

Dear All:

Got it.

 

Thank you very much.

 

Thanks

=B7=A2=BC=FE=C8=CB: devel@edk2.gro= ups.io <devel@edk2.groups.io> =B4=FA=B1= =ED fanjianfeng@byosoft.com.cn
=B7=A2=CB= =CD=CA=B1=BC=E4: 2021=C4=EA2=D4=C223=C8=D5 9:18
=CA=D5=BC=FE=C8=CB: devel@edk2.groups.io; lersek <lersek@redhat.com>; Tiger Liu(= BJ-RD) <TigerLiu@zhaoxin.com>
=D6=F7=CC=E2: Re: [edk2-devel] MP Services Protocol : Support Hyper threading or not

 

" Will = EFI_MP_SERVICES_PROTOCOL.StartupAllAPs() make all 8 logical cores do some t= asks simultaneously?"

 <= /o:p>

All APs logi= cal processors excute AP task, not including BSP. Acutally the answer is 7.=

 <= /o:p>

Jeff

 <= /o:p>

From: Laszlo Ersek

Date: 2021-02-22 18:3= 9

To: devel; tigerliu

Subject: Re: [edk2-devel] MP Services Protocol : Support Hyper threading or not

On 02/22/21 = 08:08, Tiger Liu(BJ-RD) wrote:

> Dear Al= l:

> I have = a question about MP Services Protocol.

> Does it= support Hyper-threading technology?

>

> For exa= mple:

> A Quad-= cores CPU(with HT feature support), actually it is equal to 8 logical cores= .

> Take as= sumption 8 logical cores are all healthy and being enabled.

>

> So:

>

> 1. = ;     Will EFI_MP_SERVICES_PROTOCOL.GetNumberOfProcesso= rs()return total 8 logical processor cores?

>

> 2. = ;     Will EFI_MP_SERVICES_PROTOCOL.StartupAllAPs() mak= e all 8 logical cores do some tasks simultaneously?

 <= /o:p>

My understan= ding is "yes", to both questions. Most of the MP stuff deals=

with "l= ogical processors".

 <= /o:p>

 <= /o:p>

BTW, if you = check the EFI_MP_SERVICES_GET_PROCESSOR_INFO prototype, it

outputs EFI_= PROCESSOR_INFORMATION. The latter has the following fields:

 <= /o:p>

  EFI_C= PU_PHYSICAL_LOCATION      Location;

  EXTEN= DED_PROCESSOR_INFORMATION ExtendedInformation;

 <= /o:p>

The former g= ives you a package/core/thread identification for a

particular p= rocessor number. The latter (optionally) provides a 6-level

description = (package / module / tile / die / core / thread). In each<= /p>

information = structure, "logical thread" is the finest granularity<= /span>

information.=

 <= /o:p>

hth

Laszlo<= /o:p>

 <= /o:p>

 <= /o:p>

 <= /o:p>

 <= /o:p>

 <= /o:p>

 <= /o:p>



=B1=A3=C3=DC=C9=F9=C3=F7=A3=BA
=B1=BE=D3=CA=BC=FE=BA=AC=D3=D0=B1=A3=C3=DC=BB=F2=D7=A8=D3= = =D0=D0=C5=CF=A2=A3=AC=BD=F6=B9=A9=D6=B8=B6=A8=CA=D5=BC=FE=C8=CB=CA=B9=D3= =C3=A1=A3=D1=CF=BD=FB=B6=D4=B1=BE=D3=CA=BC=FE=BB=F2=C6=E4=C4=DA=C8=DD=D7= =F6=C8=CE=BA=CE=CE=B4=BE=AD=CA=DA=C8=A8=B5=C4=B2=E9=D4=C4=A1=A2=CA=B9=D3= =C3=A1=A2=B8=B4=D6=C6=BB=F2=D7=AA=B7=A2=A1=A3
CONFIDENTIAL NOTE:
This email contains confidential or legally privileged information and = is for the sole use of its intended recipient. Any unauthorized review, use= , copying or forwarding of this email or the content of this email is stric= tly prohibited.
--_000_68bdfa765dbb4d5fb40b837c90920035zhaoxincom_--