Yes. Your application runs in IIS which is a multi-threaded program that will take advantage of however many processors or processor cores are available to it on the system.
IIS is an application that makes use of all the processors available to it as that is how it has been written. This largely frees you from the need to consider the hardware when coding your applications that run in IIS, and it means if the hardware is upgraded
your application benefits from it immediately without you having to revisit your code. It doesn't stop you from creating code that is multi-threaded or asynchronous in order to reap even more benefits from multiple processors where it is appropriate to do
so.
MCSD, MCPD, MCTS
Marked as answer by contactrajkumar on May 03, 2012 10:28 AM
When we deploy our web app on the server, IIS makes several threads to work in parallel because its multi threading enabled. We can also make threads in our code behind and make them execute as well
contactrajku...
Participant
854 Points
213 Posts
Multiprocessor Programming
Apr 30, 2012 11:54 AM|LINK
Hi Friends,
Generally we are creating web application (.Net 2.0) and hosting it in server, Our server has more than one processor.
will our application meke use of all the processor or it will use only one processor?
How to write multi processor programming using .net 4.0?
Please guide me...
Thanks in Advance.
Regards,
Rajkumar M.
jigarbjpatel
Member
454 Points
88 Posts
Re: Multiprocessor Programming
Apr 30, 2012 12:03 PM|LINK
Use Task Parallel Library
Refer links
http://msdn.microsoft.com/en-us/library/dd537609.aspx
http://blogs.msdn.com/b/csharpfaq/archive/2010/06/01/parallel-programming-in-net-framework-4-getting-started.aspx
contactrajku...
Participant
854 Points
213 Posts
Re: Multiprocessor Programming
Apr 30, 2012 12:12 PM|LINK
Thank you for your reply.
our server has 4 processors, Will .Net 2.0 application use all the processors or only one?
frez
Contributor
5418 Points
913 Posts
Re: Multiprocessor Programming
Apr 30, 2012 12:18 PM|LINK
contactrajku...
Participant
854 Points
213 Posts
Re: Multiprocessor Programming
Apr 30, 2012 12:25 PM|LINK
Hi frez,
Thank you for your reply.
My application is mainly fetching data from database and displaying it into required format, for this case i have not used threading.
then my application will use only one processor?
nijhawan.sau...
All-Star
16398 Points
3172 Posts
Re: Multiprocessor Programming
Apr 30, 2012 12:25 PM|LINK
You don't have to write any additional code here, the Server will take care of utilizing all cores and processors by it's own.
contactrajku...
Participant
854 Points
213 Posts
Re: Multiprocessor Programming
May 02, 2012 09:42 AM|LINK
Hi nijhawan.saurabh
If server will take care of all those things then what is the use of Multi-Core Processors or parallel programming.
I got confused...
frez
Contributor
5418 Points
913 Posts
Re: Multiprocessor Programming
May 02, 2012 10:33 AM|LINK
contactrajku...
Participant
854 Points
213 Posts
Re: Multiprocessor Programming
May 03, 2012 09:40 AM|LINK
Hi frez,
Is there any article on this?
Send me some appropriate links about this if you have..
Thank you.
cYpH3r x3r0
Member
327 Points
107 Posts
Re: Multiprocessor Programming
May 03, 2012 09:57 AM|LINK
When we deploy our web app on the server, IIS makes several threads to work in parallel because its multi threading enabled. We can also make threads in our code behind and make them execute as well
http://www.codeproject.com/Articles/38501/Multi-Threading-in-ASP-NET
in that case each thread will be executed on the separate processor