I read somewhere that Intel is planning a processor with 80 cores, wow! The current processors have 2 cores and soon we will have 4 cores available.

As I understand it, a process in Windows runs on one core in the processor, a process can have multiple threads. Each thread is given time to process in the processor core in a round robin or something like that.

I have a situation where I need a program to do 3 different things, now I perform them one at a time, but would it be better to start up each of the actions in its own thread? Would it result in better usage of the different cores to do the work quicker?

If not, what should I then do? Start up multiple processes? - That does not seem natural.

As I understand it, a process in Windows runs on one core in the processor, a process can have multiple threads. Each thread is given time to process in the processor core in a round robin or something like that.

I don't know where you heard that but it's wrong. Multiple threads in a single process can and will take advantage of multiple CPUs/cores.

Klaus Enevoldsen wrote:As I understand it, a process in Windows runs on one core in the processor, a process can have multiple threads. Each thread is given time to process in the processor core in a round robin or something like that.

I don't know where you heard that but it's wrong. Multiple threads in a single process can and will take advantage of multiple CPUs/cores.

Agreed. Each thread will be assigned to the available core. Having multiple cores means that more threads will be processed, and that the processor has more capacity to process more threads, who ever their owner is. When you write multi-threaded, and Asynchronous
applications you automatically take advantage of multi-core processing, because now the threads are not competing for a single core, but for 2 cores, and the more cores the better, it will mean the capacity to process 80+ threads at a time is a plus in terms
of performance.

I suggest you read the chapter on Processes, Threads and AppDomains in Joe Duffy's book. Joe has a second book on concurrency in the pipe - but in the mean time Joe's first book has a pretty good treatment on the subject.

Klaus Enevoldsen wrote:As I understand it, a process in Windows runs on one core in the processor, a process can have multiple threads. Each thread is given time to process in the processor core in a round robin or something like that.

I don't know where you heard that but it's wrong. Multiple threads in a single process can and will take advantage of multiple CPUs/cores.

Agreed. Each thread will be assigned to the available core. Having multiple cores means that more threads will be processed, and that the processor has more capacity to process more threads, who ever their owner is. When you write multi-threaded, and Asynchronous
applications you automatically take advantage of multi-core processing, because now the threads are not competing for a single core, but for 2 cores, and the more cores the better, it will mean the capacity to process 80+ threads at a time is a plus in terms
of performance.

And if all threads need a common object? I mean it doesn't have a lot benefit then, if one thread is blocking that object for a certain amount of time...

I'm wondering a lot how this is going to be automated. There is so much logic that can't be automatically applied. *curious about the future*

A typical use where I personally use mutlithreading is in parsing flat files.... I have a directorywatcher watching a directory (in a windows service) that runs on its own thread.... each time it sees a new file it spawns a new thread to parse that file and
upload it to a SQL db..... the parsing and uploading can take some time so threading allows me to parse multiple files at once (this cut the average parse time of 10+ files from a total of 30 seconds to an aprox 18sec total... IIRC)

Remember its not just about Cores... its about logical processors.... HT-enabled procs/cores count as two processors....

There are crypto systems that will not work now because the processor power is there. What new crypto systems are being developed for the Multi-Core world?

Longer the key and you are safe with the existing ones. Cryptography has only a problem once quantum CPUs are available, but there are already people developing and have already developed ways to do quantum cryptography.

SecretSoftware wrote:﻿I wanted to ask about Mulit-Core and Cryptographic systems.

There are crypto systems that will not work now because the processor power is there. What new crypto systems are being developed for the Multi-Core world?

Longer the key and you are safe with the existing ones. Cryptography has only a problem once quantum CPUs are available, but there are already people developing and have already developed ways to do quantum cryptography.

But there are cryptographic hashes that will not be used anymore because of the Quad cores. Now its easier to guess the password from a hash. Or do Man-In-the middle attacks, because you have more processor power. remember the 80 core promise by 2010?

Thread Closed

This thread is kinda stale and has been closed but if you'd like to continue the conversation,
please create a new thread in our Forums, or
Contact Us and let us know.