Dr-Noob / cpufetch

Simple yet fancy CPU architecture fetching tool
GNU General Public License v2.0
1.82k stars 99 forks source link

Windows on ARM support #226

Open Wunkolo opened 5 months ago

Wunkolo commented 5 months ago

Creating this issue to capture interest and information in relation to adding Windows on Arm support.

Wunkolo commented 5 months ago

Windows on Arm processor-features can be detected from registry with Get-Item -Path HKLM:\HKEY_LOCAL_MACHINE\HARDWARE\DESCRIPTION\System\CentralProcessor\*.

The registry entries map to the registers :

CP 4000: MIDR_EL1
CP 4020: ID_AA64PFR0_EL1
CP 4021: ID_AA64PFR1_EL1
CP 4028: ID_AA64DFR0_EL1
CP 4029: ID_AA64DFR1_EL1
CP 402C: ID_AA64AFR0_EL1
CP 402D: ID_AA64AFR1_EL1
CP 4030: ID_AA64ISAR0_EL1
CP 4031: ID_AA64ISAR1_EL1
CP 4038: ID_AA64MMFR0_EL1
CP 4039: ID_AA64MMFR1_EL1
CP 403A: ID_AA64MMFR2_EL1

An example output from my ThinkPad x13s:

Click to expand ``` Hive: HKEY_LOCAL_MACHINE\HARDWARE\DESCRIPTION\System\CentralProcessor Name Property ---- -------- 0 Component Information : {0, 0, 0, 0...} Identifier : ARMv8 (64-bit) Family 8 Model D4B Revision 0 Configuration Data : VendorIdentifier : Qualcomm Technologies Inc ~MHz : 1440 CP 4020 : 1224979098931106066 CP 4021 : 16 CP 4028 : 271602696 CP 4029 : 0 CP 402C : 0 CP 402D : 0 CP 4030 : 4521192084017440 CP 4031 : 18874417 CP 4038 : 1048609 CP 4039 : 2097154 CP 403A : 16 CP 4000 : 1091556528 CP 5801 : 2487533572 CP 4080 : 17593005005149 CP 4081 : 0 CP 4100 : 54043212695154688 CP 4510 : 4919057789357392127 ProcessorNameString : Snapdragon (TM) 8cx Gen 3 @ 3.0 GHz 1 Component Information : {0, 0, 0, 0...} Identifier : ARMv8 (64-bit) Family 8 Model D4B Revision 0 Configuration Data : VendorIdentifier : Qualcomm Technologies Inc ~MHz : 1440 CP 4020 : 1224979098931106066 CP 4021 : 16 CP 4028 : 271602696 CP 4029 : 0 CP 402C : 0 CP 402D : 0 CP 4030 : 4521192084017440 CP 4031 : 18874417 CP 4038 : 1048609 CP 4039 : 2097154 CP 403A : 16 CP 4000 : 1091556528 CP 5801 : 2487533572 CP 4080 : 17593005005149 CP 4081 : 0 CP 4100 : 54043212695154688 CP 4510 : 4919057789357392127 ProcessorNameString : Snapdragon (TM) 8cx Gen 3 @ 3.0 GHz 2 Component Information : {0, 0, 0, 0...} Identifier : ARMv8 (64-bit) Family 8 Model D4B Revision 0 Configuration Data : VendorIdentifier : Qualcomm Technologies Inc ~MHz : 1440 CP 4020 : 1224979098931106066 CP 4021 : 16 CP 4028 : 271602696 CP 4029 : 0 CP 402C : 0 CP 402D : 0 CP 4030 : 4521192084017440 CP 4031 : 18874417 CP 4038 : 1048609 CP 4039 : 2097154 CP 403A : 16 CP 4000 : 1091556528 CP 5801 : 2487533572 CP 4080 : 17593005005149 CP 4081 : 0 CP 4100 : 54043212695154688 CP 4510 : 4919057789357392127 ProcessorNameString : Snapdragon (TM) 8cx Gen 3 @ 3.0 GHz 3 Component Information : {0, 0, 0, 0...} Identifier : ARMv8 (64-bit) Family 8 Model D4B Revision 0 Configuration Data : VendorIdentifier : Qualcomm Technologies Inc ~MHz : 1440 CP 4020 : 1224979098931106066 CP 4021 : 16 CP 4028 : 271602696 CP 4029 : 0 CP 402C : 0 CP 402D : 0 CP 4030 : 4521192084017440 CP 4031 : 18874417 CP 4038 : 1048609 CP 4039 : 2097154 CP 403A : 16 CP 4000 : 1091556528 CP 5801 : 2487533572 CP 4080 : 17593005005149 CP 4081 : 0 CP 4100 : 54043212695154688 CP 4510 : 4919057789357392127 ProcessorNameString : Snapdragon (TM) 8cx Gen 3 @ 3.0 GHz 4 Component Information : {0, 0, 0, 0...} Identifier : ARMv8 (64-bit) Family 8 Model D4C Revision 0 Configuration Data : VendorIdentifier : Qualcomm Technologies Inc ~MHz : 1747 CP 4020 : 1224979098931106066 CP 4021 : 16 CP 4028 : 271602696 CP 4029 : 0 CP 402C : 0 CP 402D : 0 CP 4030 : 4521192084017440 CP 4031 : 18874417 CP 4038 : 1048609 CP 4039 : 2097154 CP 403A : 16 CP 4000 : 1091556544 CP 5801 : 2487533572 CP 4080 : 17593005005149 CP 4081 : 0 CP 4100 : 54043212695154688 CP 4510 : 4919057789357392127 ProcessorNameString : Snapdragon (TM) 8cx Gen 3 @ 3.0 GHz 5 Component Information : {0, 0, 0, 0...} Identifier : ARMv8 (64-bit) Family 8 Model D4C Revision 0 Configuration Data : VendorIdentifier : Qualcomm Technologies Inc ~MHz : 1747 CP 4020 : 1224979098931106066 CP 4021 : 16 CP 4028 : 271602696 CP 4029 : 0 CP 402C : 0 CP 402D : 0 CP 4030 : 4521192084017440 CP 4031 : 18874417 CP 4038 : 1048609 CP 4039 : 2097154 CP 403A : 16 CP 4000 : 1091556544 CP 5801 : 2487533572 CP 4080 : 17593005005149 CP 4081 : 0 CP 4100 : 54043212695154688 CP 4510 : 4919057789357392127 ProcessorNameString : Snapdragon (TM) 8cx Gen 3 @ 3.0 GHz 6 Component Information : {0, 0, 0, 0...} Identifier : ARMv8 (64-bit) Family 8 Model D4C Revision 0 Configuration Data : VendorIdentifier : Qualcomm Technologies Inc ~MHz : 1747 CP 4020 : 1224979098931106066 CP 4021 : 16 CP 4028 : 271602696 CP 4029 : 0 CP 402C : 0 CP 402D : 0 CP 4030 : 4521192084017440 CP 4031 : 18874417 CP 4038 : 1048609 CP 4039 : 2097154 CP 403A : 16 CP 4000 : 1091556544 CP 5801 : 2487533572 CP 4080 : 17593005005149 CP 4081 : 0 CP 4100 : 54043212695154688 CP 4510 : 4919057789357392127 ProcessorNameString : Snapdragon (TM) 8cx Gen 3 @ 3.0 GHz 7 Component Information : {0, 0, 0, 0...} Identifier : ARMv8 (64-bit) Family 8 Model D4C Revision 0 Configuration Data : VendorIdentifier : Qualcomm Technologies Inc ~MHz : 1747 CP 4020 : 1224979098931106066 CP 4021 : 16 CP 4028 : 271602696 CP 4029 : 0 CP 402C : 0 CP 402D : 0 CP 4030 : 4521192084017440 CP 4031 : 18874417 CP 4038 : 1048609 CP 4039 : 2097154 CP 403A : 16 CP 4000 : 1091556544 CP 5801 : 2487533572 CP 4080 : 17593005005149 CP 4081 : 0 CP 4100 : 54043212695154688 CP 4510 : 4919057789357392127 ProcessorNameString : Snapdragon (TM) 8cx Gen 3 @ 3.0 GHz ```
Dr-Noob commented 4 months ago

So I was going to argue that ARM on Windows makes little sense, but then I realized you have this Snapdragon that runs Windows (I forgot this existed). I'm still not a fan of Windows, but yes it makes sense to have support for it. I'll schedule some time for this and I'll let you know so that you can test it on your machine :+1: