Solved

Why does app use only 25% of dual cpu

Posted on 2006-11-20
6
227 Views
Last Modified: 2010-04-18
Hi

I am new to multiple cpu's and win3k.

I have an application which performs a batch task. On a 64bit 2400 athlon running 32bit Win3k it uses 100% and performs the task quickly.

On a dual xeon 2.4ghz it only uses 25% cpu usage and takes 4 times as long as the single machine to do the job.

Can somebody please explain why an application that uses 100% cpu on a single cpu machine, only uses 25% of a dual xeon machine?

Thanks
0
Comment
Question by:zattz
  • 3
  • 3
6 Comments
 
LVL 95

Accepted Solution

by:
Lee W, MVP earned 500 total points
Comment Utility
A dual Xeon presents 4 processors to the OS - each physical CPU is hyperthreaded (HT) and each HT CPU is seen as two.  So 2 physical CPUs times 2 for HT gives you 4 processors (according to Windows).

An Athlon64 doesn't offer HyperThreading (HT is an Intel only feature - AMD does offer HyperTransport, but that's not the same thing).  So unless you have two cores in the athlon or a second CPU, the athlon is only seen as 1 CPU.

So you're thinking, "fine, by why still only 25%?"

Because the application only has ONE Thread.  In order to take advantage of multiple processors, you need the application to utilize MORE than one thread.  Think of it like having a kitchen and each person in the house is capable of washing dishes, but there's only one sink.  You can't have more than one person washing the dishes at the same time (drying doesn't count).  So even if you brought friends over, you couldn't wash the dishes any faster unless you had more sinks (threads).
0
 

Author Comment

by:zattz
Comment Utility
Leew,

That's what I was thinking, hmm

I forgot to mention the application queries a MS Sql server.

If the application does a single query, would the query run as one thread on MS SQL and use one cpu, or would it be spread over multiple?

Thanks
0
 
LVL 95

Expert Comment

by:Lee W, MVP
Comment Utility
I'm not sure - SQL is multithreaded, but I'm not sure how it's multithreaded.  A single, SIMPLE query almost certainly executes in one thread.  A query that uses subqueries and/or joins may use more than one thread.  But that's just a guess.
0
Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 

Author Comment

by:zattz
Comment Utility
Makes sense to me...

Although if I go to task mngr, the cpu graphs show equal activity across all cpu's... and yes it is a very single query, no joins... Maybe windows is lying?

0
 
LVL 95

Expert Comment

by:Lee W, MVP
Comment Utility
It's possible task manager isn't being entirely accurate... when looking at the processes tabs I've seen that claim lots of idle time then look at the graph and it's pegged...
0
 

Author Comment

by:zattz
Comment Utility
Okay. Thanks a lot for your help:)
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Preface Having the need * to contact many different companies with different infrastructures * do remote maintenance in their network required us to implement a more flexible routing solution. As RAS, PPTP, L2TP and VPN Client connections are no…
Numerous times I have been asked this questions that what is it that makes my machine log on so slow, there have been cases where computers took 23 minute exactly after taking password and getting to the desktop. Interesting thing was the fact th…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now