Thanks a bunch. I have my Linux finals on 19th Jan. This was a godsent.
@bsgamer50693 жыл бұрын
Your explanation is just amazing. I have a job interview next Thursday. I will comment if I get hired 😁. And I have posted your channel link to Facebook group
@0x2d263 жыл бұрын
what's the job title?
@bsgamer50693 жыл бұрын
@@0x2d26 junior developer. I will be doing programming stuffs.
@vorio5310 Жыл бұрын
When I was testing how the number of threads affects speed, I encountered a very strange behavior. With one thread the time is about 2s, with two the time is 10s!!!! And when adding more threads the time decreases (with 32 threads the time is about 4s). I was running the code on a virtual machine with 4 cores. I didn't use any mutexes and sleep() functions. What is the reason for that?
@CodeVault Жыл бұрын
If the workload is very small then the overhead of creating and waiting for threads plays a much bigger role. After 4 threads you shouldn't see much of a performance improvement. Do you have the exact time it take to execute for each number of threads you tested? Also, can you share the code you're trying to execute? Thanks
@fernandaeschallots24853 жыл бұрын
But I realized that Parallelism is more effective
@CodeVault3 жыл бұрын
Yes, ideally you want your program to run in parallel without any concurrency (or as little as possible)
@fernandaeschallots24853 жыл бұрын
I didn't understand anything....Google Translator probably doesn't work well
@CodeVault3 жыл бұрын
Yea... sorry, we don't have captions for other languages
@_4p_4 ай бұрын
thanks man
@antonfernando84092 жыл бұрын
Would your definition still hold true when there are multiple CPUs?
@CodeVault2 жыл бұрын
Yes, of course. Multiple CPUs on the same system acts much like one large CPU
@Awwe126752 жыл бұрын
I know parallel used multiple core and thread is only one core But I have question what is task What is multiplthreds
@CodeVault2 жыл бұрын
Threads have different meanings based on which part of the computer you're looking at. A thread in the hardware is the number of cores the OS sees. (So if you have a 4 core 8 thread CPU, the OS sees that you actually have 8 cores and you can run 8 processes in parallel). A thread in software is just another line of execution for a process A task is usually a program that is executed completely on one single thread
@Awwe126752 жыл бұрын
@@CodeVault Thank you bro but I have the same issue I can’t understand If we say parallel just use core okay “ And thread is one core with the same program running okay “ task is thread like events in the same program run? And why some people say multiplethread it’s seems to me it’s threads ? Can you draw that in future videos please And sorry for my bad English