2

It is well known that OpenBSD disables hyper-threading by default. However, htop shows 16 CPUs: 8 online and 8 offline, which takes extra space on the screen and is not very informative.

enter image description here

Moreover, sysctl also sees 16 logical CPUs. This doesn't make sense to me: with hyperthreading disabled, it's an 8-core 8-thread processor, so I should see 8 physical/logical CPUs.

$ sysctl hw
hw.machine=amd64
hw.model=AMD Ryzen 7 5800H with Radeon Graphics
hw.ncpu=16
hw.byteorder=1234
hw.pagesize=4096
hw.disknames=sd0:6d1abdce154d2fc8
hw.diskcount=1
hw.sensors.cpu0.frequency0=3900000000.00 Hz
hw.sensors.cpu2.frequency0=3900000000.00 Hz
hw.sensors.cpu4.frequency0=3900000000.00 Hz
hw.sensors.cpu6.frequency0=3900000000.00 Hz
hw.sensors.cpu8.frequency0=3900000000.00 Hz
hw.sensors.cpu10.frequency0=3900000000.00 Hz
hw.sensors.cpu12.frequency0=3900000000.00 Hz
hw.sensors.cpu14.frequency0=3900000000.00 Hz
hw.sensors.ksmn0.temp0=83.12 degC (Tctl)
hw.sensors.it0.temp0=83.00 degC
hw.sensors.it0.temp1=49.00 degC
hw.sensors.it0.temp2=200.00 degC
hw.sensors.it0.fan0=0 RPM
hw.sensors.it0.fan1=3835 RPM
hw.sensors.it0.fan2=2986 RPM
hw.sensors.it0.volt0=1.74 VDC (VCORE_A)
hw.sensors.it0.volt1=1.62 VDC (VCORE_B)
hw.sensors.it0.volt2=2.67 VDC (+3.3V)
hw.sensors.it0.volt3=3.71 VDC (+5V)
hw.sensors.it0.volt4=10.69 VDC (+12V)
hw.sensors.it0.volt5=-3.24 VDC (-12V)
hw.sensors.it0.volt6=0.57 VDC (-5V)
hw.sensors.it0.volt7=3.68 VDC (+5VSB)
hw.sensors.it0.volt8=2.16 VDC (VBAT)
hw.cpuspeed=3200
hw.setperf=100
hw.vendor=AZW
hw.product=SER
hw.version=Default string
hw.serialno=A58003LH80340
hw.uuid=00020003-0004-0005-0006-000700080009
hw.physmem=13840232448
hw.usermem=13840216064
hw.ncpufound=16
hw.allowpowerdown=1
hw.perfpolicy=manual
hw.smt=0
hw.ncpuonline=8
hw.power=1
hw.ucomnames=

How do I disable logical processors, so that each "CPU" is a physical processor?

3
  • 2
    Disable hyperthreading from BIOS/EFI. OpenBSD just put them offline Commented Apr 24, 2024 at 16:52
  • 1
    @RomeoNinov Thanks for the advice! If you can make it into an answer I will upvote and accept it. Commented Apr 26, 2024 at 13:29
  • Symmetric Multithreading, or "Why are only half of my CPUs used?" Commented Oct 17, 2024 at 0:13

1 Answer 1

2

Availability of hyperthreading is managed from BIOS/EFI. What OpenBSD do is to put offline the processor(s)/thread(s). So You should do it in BIOS/EFI by disabling hyperthreading option.

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.