Skip to content

Commit

Permalink
Disable znver1 by default
Browse files Browse the repository at this point in the history
This crap won't be upstreamized and we do not have so many resources
to build and test yet another pack of binaries without big performance gain.

rpm-software-management#1035 (comment)

To enable automatic detection of Ryzen CPUs create a file
/etc/rpm/znver1_enable
  • Loading branch information
mikhailnov committed Feb 8, 2021
1 parent 1593b04 commit 0b60996
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/rpmrc.c
Original file line number Diff line number Diff line change
Expand Up @@ -959,6 +959,11 @@ static int is_geode(void)

#if defined(__linux__) && (defined(__i386__) || defined(__x86_64__))
static int is_ryzen() {
// Disable this crap by default on ROSA.
// rpmExpandNumeric does not work here for some reasons,
// probably this is done earlier than macros are loaded.
if (access("/etc/rpm/znver1_enable", F_OK) != 0)
return 0;
uint32_t eax, ebx, ecx, edx;
char vendor[13];
int family;
Expand Down

0 comments on commit 0b60996

Please sign in to comment.