Gentoo Archives: gentoo-user

From: tuxic@××××××.de
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] RYZEN 5: Hyperthreading or no hyperthreading...
Date: Sat, 28 Mar 2020 05:58:04
Message-Id: 20200328055753.ja4p7wqemzl43s53@solfire
In Reply to: Re: [gentoo-user] RYZEN 5: Hyperthreading or no hyperthreading... by Mark Knecht
1 On 03/27 11:51, Mark Knecht wrote:
2 > On Fri, Mar 27, 2020 at 11:11 AM <tuxic@××××××.de> wrote:
3 > >
4 > > On 03/27 06:04, Andrea Conti wrote:
5 > > > Hello,
6 > > >
7 > > > > Thread(s) per core: 1 <<<<<
8 > > > > Does my CPU hyperthread?
9 > > >
10 > > > Definitely not.
11 > > >
12 > > > Your kernel config is fine, chances are hyperthreading (aka "SMT mode")
13 > is
14 > > > disabled in your BIOS settings.
15 > > >
16 > > > andrea
17 > > >
18 > >
19 > > Hi Andrea,
20 > >
21 > > I checked that: The BIOS setting was set to use hyperthreading.
22 > >
23 > > But "Number of cores" was set to six. I changed that to 12 and
24 > > Voila! I got two threads per core.
25 > >
26 > > I think "Number of cores" is a little misleading, since there
27 > > are six physical cores (not threads) with a RYZEN 5.
28 > >
29 > > I feeling not that comfortable with this solution.
30 > >
31 > > Is there any way to check for the validity of this setting
32 > > beside a tool, which prints a "2" after the word "threads" ;) ?
33 > >
34 > > Cheers!
35 > > Meino
36 > >
37 > >
38 >
39 > cat /proc/cpu should give info for each thread. I've been running an i7 980
40 > Extreme processor @3.33GHz here at home for about 12 years or so. It's 6
41 > cores but shows 12 processors on both Gentoo and now Kubuntu.
42 >
43 > I generally run top and then hit '1' and 'z'. You can watch what percentage
44 > each core/thread is using.
45 >
46 > Time a BIG compile job twice, once with each kernel. If it's working you'll
47 > measure a significant difference in time. Note that it won't be 2x as
48 > you'll also be limited by disk read/write throughput, but you'll know it's
49 > basically working.
50 >
51 > On Gentoo make sure you're compile settings in (I think make.conf - I no
52 > longer run Gentoo much) are set to take advantage of all your cores and not
53 > limited to something smaller. Also watch overheating when using more
54 > cores/threads. On older PCs like mine when you possibly have dust in CPU
55 > coolers might not be as efficient as when they are new.
56 >
57 > HTH,
58 > Mark
59
60 Hi Mark,
61
62 thank you for your explanations! :)
63
64 /proc/cpu doesn't exist on my system....may be you are referring to
65 /proc/cpuinfo?
66
67 The problem was caused by a kernel misconfiguration by me.
68
69 In the kernel setup there is a setting "Number of cores" which
70 I had set to six ... since my CPU has 6 physical core.
71
72 Setting this to twelve (and blurring the syntactically border between
73 threads and cores thereby...) gives me twelves cores in top, htop
74 and such and (as an example) compiling the kernel is faster -
75 so it is not a display gimmick only.
76
77 I think "Number of cores" is a misnomer...or am I wrong?
78
79 Cheers!
80 Meino

Replies

Subject Author
Re: [gentoo-user] RYZEN 5: Hyperthreading or no hyperthreading... Mark Knecht <markknecht@×××××.com>