By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,194 Members | 889 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,194 IT Pros & Developers. It's quick & easy.

managed & unmanaged question

P: n/a
Hi, I'm writing a research simulation program and would like to write it in
c++. It should be as fast as possible and am not sure if it makes a
difference to use managed or unmanaged code. I will have to use it on more
than one computer but most of the time I will be using my own computer.
If, unmanaged code is faster, than what would I have to do to switch
between managed and unmanaged code? Can I just change a simple setting on
the new Microsoft Visual Studio? or would I just have to change the way I
declare variables? I'm not vary familiar with managed code.
thanks
dave
Jul 22 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
In article <U-********************@comcast.com>,
Dave <da*********@hotmail.com> wrote:
Hi, I'm writing a research simulation program and would like to write it in
c++. It should be as fast as possible and am not sure if it makes a
difference to use managed or unmanaged code.


I've never heard of "managed code" in the context of standard C++. A
Google search leads me to believe that it might be a Microsoft thing, in
which case you'd be better off asking about it in one of the
microsoft.public.vc.* or comp.os.ms-windows.programmer.* groups.

--
Jon Bell <jt*******@presby.edu> Presbyterian College
Dept. of Physics and Computer Science Clinton, South Carolina USA
Jul 22 '05 #2

P: n/a
Dave <da*********@hotmail.com> wrote in message
news:U-********************@comcast.com...
Hi, I'm writing a research simulation program and would like to write it in c++. It should be as fast as possible and am not sure if it makes a
difference to use managed or unmanaged code. I will have to use it on more than one computer but most of the time I will be using my own computer.
If, unmanaged code is faster, than what would I have to do to switch
between managed and unmanaged code? Can I just change a simple setting on
the new Microsoft Visual Studio? or would I just have to change the way I
declare variables? I'm not vary familiar with managed code.
thanks
dave

First of all, follow what Jon said.

After saying that, here's what I thought...and it's just my opinion.

Since your goal is doing simulation for research, you better off use any
language which is familiar to you. If you are familiar with C++, then use
C++; if C, then use C. Both should be fast enough for your purpose.

You don't need to switch between managed and unmanaged code since such a
switching always comes with a performance pernality. In Visual Studio .NET,
you can use either VB, C# if its speed satisfies your requirement.
Otherwise, use C++. As you know, use C++ in VS.NET, you can write managed
or unmanaged code as you wish.

Since you doing simulation, it must have lots of calculation instead of GUI
stuff, I assume about this. If this is the case, you may stay in C or C++.
If you do need lots graphic stuff, find some library of graphics.

You said "I will have to use it on more than one computer but most of the
time I will be using my own computer." Do you mean it will run
simultaneously on several computers? Do they need to communicate with each
other? Or will it just runs on computers of different OS? If it's the
latter case write the code and make sure it is portable across platforms.
Start from small and focus on one platform (your own computer) first.

Again, you goal is not mastering a new programming language but use it as a
tool for research. Thus, make sure the process of reaching the goal is
least-resistant. By saying that I mean using whichever language with which
you are familiar and comfortable, and it is fast enough for you.

Hope this help a bit.
Jul 22 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.