Skip to content

Added Apple Silicon support to WoA #167

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions src/arm/windows/init.c
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,23 @@ static struct woa_chip_info woa_chips[] = {
3000000000
}
}
},
/* Apple Silicon */
{
L"Apple Silicon",
woa_chip_name_apple_silicon,
{
{
cpuinfo_vendor_apple,
cpuinfo_uarch_icestorm,
2064000000
},
{
cpuinfo_vendor_apple,
cpuinfo_uarch_firestorm,
3228000000
}
}
}
};

Expand Down Expand Up @@ -203,6 +220,7 @@ static bool get_system_info_from_registry(
int compare_result = wcsncmp(text_buffer, woa_chips[i].chip_name_string, compare_length);
if (compare_result == 0) {
*chip_info = woa_chips+i;
result = true;
break;
}
}
Expand Down
3 changes: 2 additions & 1 deletion src/arm/windows/windows-arm-init.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@ enum woa_chip_name {
woa_chip_name_microsoft_sq_2 = 1,
woa_chip_name_microsoft_sq_3 = 2,
woa_chip_name_ampere_altra = 3,
woa_chip_name_unknown = 4,
woa_chip_name_apple_silicon = 4,
woa_chip_name_unknown = 5,
woa_chip_name_last = woa_chip_name_unknown
};

Expand Down