What is counted as a task?

lakimens

Honorable
Hello, everyone
I have here in my laptop the i7-2670QM.
I know it has 4 cores 2 threads each.
So what is counted as a task?
I know 1 thread is suppost to do 1 task.
And I know I can run more than 8 things at the same time..
Can someone explain it to me?
 
Solution
A CORE is now basically what an entire CPU used to be (one core). So a 4-core CPU is basically four CPU's joined together with a task manager or whatever the right term is to allocate tasks between them.

A "hyperthread" is a way to sneak another task into a core when it's already running a task (it's a bit complicated).

A single core can be running HUNDREDS of small tasks. Basically it can start doing one, then the next, then the next until it finally repeats back to the first task to continue on with the instructions.

Tasks are processed using a PRIORITY. For example, a crucial Windows task might receive the highest priority, and a VIDEO program nearly the highest because it needs to run in REAL TIME.

*There is some confusion that...
One thread can do many tasks. A task can be a service, a program. Just open "Task Manager" and you'll see all tasks running.
For a complete explanation:
In computer programming, a task is a basic unit of programming that an operating system controls. Depending on how the operating system defines a task in its design, this unit of programming may be an entire program or each successive invocation of a program. Since one program may make requests of other utility programs, the utility programs may also be considered tasks (or subtasks). All of today's widely-used operating systems support multitasking , which allows multiple tasks to run concurrently, taking turns using the resources of the computer.

In preemptive multitasking , each task may be assigned a priority depending on its relative importance, the amount of resources it is consuming, and other factors. The operating system then preempts (cuts short) a task having a lower priority value so that a higher priority task is given a turn. Windows 2000 , OS/390 , Linux , and Amiga are examples of operating systems that use preemptive multitasking. Cooperative multitasking is the ability for an operating system to manage multiple tasks such as application programs at the same time, but without the ability to necessarily preempt them.

It's easy to confuse the terms multithreading and multitasking . Multithreading is the management of multiple concurrent uses of the same program. Most operating systems and modern computer languages also support multithreading.
Source: http://whatis.techtarget.com/definition/task
 
The situation is not as simple as one thread = one task = one program. Programs may only run one thread or they may run multiple threads. Different programs will run on different threads, though, so if you are running X programs, you will be running at least X threads.

However, a single logical core on a CPU can handle multiple threads - it just can only execute one thread simultaneously. However, modern CPUs are so good at juggling multiple threads and context switching that to you, the end user, it may seem like the computer is running more threads simultaneously than should be possible. A big part of this is that every-day programs do not require 100% CPU time and are more often than not limited by the speed of user interaction, which is orders of magnitude slower than the speeds at which the CPU can execute commands.
 
A CORE is now basically what an entire CPU used to be (one core). So a 4-core CPU is basically four CPU's joined together with a task manager or whatever the right term is to allocate tasks between them.

A "hyperthread" is a way to sneak another task into a core when it's already running a task (it's a bit complicated).

A single core can be running HUNDREDS of small tasks. Basically it can start doing one, then the next, then the next until it finally repeats back to the first task to continue on with the instructions.

Tasks are processed using a PRIORITY. For example, a crucial Windows task might receive the highest priority, and a VIDEO program nearly the highest because it needs to run in REAL TIME.

*There is some confusion that a 4-core CPU can only run four tasks. No. It can run as many as it can keep up with. I don't even know if there's a limit, of course the more things running the less time each program receives to get processed which again is why we have priorities.

Programs like HANDBRAKE can use all EIGHT threads of a CPU nicely, however game engines are far more complicated. Not only is multi-tasking not programmed very well yet but also the CPU needs to communicate with the GPU and there can be a disconnect there preventing full use of the CPU.

Not sure if this was useful.
 
Solution
Also some programs, for instance Mass Effect 3 if I remember correctly, only uses 2 Cores/4 Threads. But you can always change the Affinity to run on more or less cores-but is not recommended most of the time.
 


What most people don't understand is tasks can jump between cores. For example, the game might only be able to use one thread, but when you see the four graphs for the four cores you see about 25% usage roughly spread between them which is equivalent to 100% on one core.

Fallout 3 actually crashes a lot until you add in an INI tweak to force only 2-core usage on startup then it works far better.

A game can't be forced to use more threads, but it can be forced to use less and spread the tasks between them.
 


I disliked Fallout 3 for how much it crashed for me with the newer expansions-and the Core Affinity was not always permanent. An update sometimes would change it back...I disliked that game for that reason and others. As a game itself-It was ok (But I'm more of action FPS like BF and Racing lkike Forza and GT5)