Questions tagged [hyperthreading]

In a hyperthreaded CPU, for each processor core that is physically present, the operating system addresses two virtual or logical cores, and shares the workload between them when possible.

In an hyper threaded environment, For each processor core that is physically present, the operating system addresses two virtual or logical cores, and shares the workload between them when possible.

This allows to decrease the number of dependent instructions on the pipeline. It takes advantage of superscalar architecture (multiple instructions operating on separate data in parallel).

223 questions
1
vote
1 answer

Can hardware threads access main memory at the same time?

I am trying to understand microarchitecture. When an operating system schedules code to run on a CPU hardware thread (as in Intel HyperThreading), can each execution context issue memory reads in parallel or is the pipeline shared? I am trying to do…
1
vote
0 answers

Why application runs faster when co-located with another app on a logical core?

I have two applications (both with a single thread). One is a word reindexing application (named wrmem) which could be found here, and the other one is a simple loop that iterates over an array. I noticed that when I pin both apps to a logical core,…
Mohammad Siavashi
  • 1,192
  • 2
  • 17
  • 48
1
vote
0 answers

strange CPU binding/pining result within OpenMPI

I have tried to evaluate an OpenMPI program with Matrix Multiplication algorithm, the written code scales very well on a single thread per core machine in our Laboratory (close to ideal speedup within 48 and 64 cores), However, on some other…
Elephant88
  • 117
  • 1
  • 12
1
vote
1 answer

Is synchronization faster on the same physical CPU core?

I have a question. If a thread modifies a variable, will the thread on the same physical core (a different hyperthread core) see the modification earlier than other cores? Or it has to wait until all the other cores see it? I've been trying to pin…
1
vote
2 answers

Why does my pc prefer even numbered cores?

My pc has a 10th gen Core i7 vPRO with virtualization enabled. 8 cores + 8 virtual cores. (i7-10875H, Comet Lake) Each physical core is split into pairs, so Core 1 hosts virtual cores 0 & 1, core 2 hosts virtual cores 2 & 3. I've noticed that in…
AutoBaker
  • 919
  • 2
  • 15
  • 31
1
vote
1 answer

How to test performance of Intel HyperThreading in Linux X86_64

I am trying to figure out the performance impact of Intel HT in Linux X86_64. Is there a well know tool or ready-to-use code to do this testing ? If not, my test plan is as follows, Scenario 1: Thread 1: High priority, run in CoreN Thread0, sleep 1…
wangt13
  • 959
  • 7
  • 17
1
vote
0 answers

How does Hyper-Threading affect the cache?

When I was using Hyper-Threading, a very strange phenomenon appeared. I was using c language to measure the time of l2 hit. I wrote the test time in a program A. When I run it alone, it showed that it takes about 26 cycles each time. When I wrote…
Gerrie
  • 736
  • 3
  • 18
1
vote
1 answer

Should I aim for multiple physical cores or multiple threads for parallel computing in R?

I am new to parallel computing and this may be a trivial question. I am thinking about which processor to choose for parallel computing (on a single machine)? In particular, I would like to know whether I should aim for a high number (physical)…
1
vote
0 answers

Can't find WSL kernel directory not in /usr/src and not in /lib/modules

I am not a developer, and don't have enough experience with Linux. I am a data scientist and wants to know how to improve my performance using my CPUs better. I have a linux VM with 2 physical CPUs, with 15 logical cores with two logical processors…
1
vote
0 answers

Does Hyper Threading will decrease the performance of Docker?

I have the below configuration server, In this we are running only Docker, All the applications are running as Docker container , Expect Docker , no other application are installed in the OS System Information : - Server Model : Dell…
Arvindh
  • 127
  • 2
  • 10
1
vote
0 answers

How hyperthreading is useful in kvm based guest VM?

We are creating virtual os threads inside guest os but the actual physical core is on the host machine. Will hyperthread = true in guest VM config make any difference? I can visualize how hyperthreading works on the host as it has a physical core,…
1
vote
1 answer

Python multiprocessing.Pool: Why doesn't adding additional processes seem to improve performance on a hyperthreaded system?

I'm experimenting with Python 3's multiprocessing module, and have the following code that reads a file containing a number on each line and prints the factorization of each number: import multiprocessing import sys NUM_PROCESSES = 4 CHUNK_SIZE =…
1
vote
0 answers

OpenMP: no speedup with Hyperthreading

I'm trying to parallelize the following C function using OpenMP: struct pixel { double r, g, b; }; double min_dist_sum_parallel(struct pixel *pixels, int n_pixels, struct pixel *centroids, int n_centroids) { …
Peter
  • 2,919
  • 1
  • 16
  • 35
1
vote
1 answer

Does number logical CPUs impact Java8 Streams performance?

While processing parallel streams JVM spins up number of threads equal to number of cores. How does the number of logical CPUs impact the performance? Does the degree of parallelism increase with the number of logical CPUs just like number of cores?…
noobCoder
  • 292
  • 2
  • 17
1
vote
1 answer

Check if hyperthreading is enabled from within R

Is there a way to check if hyperthreading is enabled from within R? The best I can think of now is to run the following system call, but this requires root privileges, and has to be parsed. system("dmidecode -t processor | grep HTT")
Megatron
  • 15,909
  • 12
  • 89
  • 97