• Advertisement

Archived

This topic is now archived and is closed to further replies.

Intel Assembly programming in Visual c++ .net 2003 Standard possible?

This topic is 5066 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I plan on purchasing the Visual c++ standard edition in the near future, and I was wondering if you could use assembly instructions (mmx, sse, sse2, sse3) inside of the VC++ .Net 2003 Standard edition? I come from a dos/assembly background and plan on learning c++ (To program anything Significant in Windows, You need a higher level language other than assembly!). And don''t want to give up the performance that assembly gives you in certain operations.

Share this post


Link to post
Share on other sites
Advertisement
It''s called "inline assembly". You use the asm key word followed by braces. Be warned that each compiler has a different implementation of this though.

The true general first seeks victory, then seeks battle
- Sun Tzu

Share this post


Link to post
Share on other sites
Not sure that VC++ Standard ships with MASM. Try opening the VS.NET command prompt and typing ml. If you get a ''ml'' is not recognized as an internal or external command, operable program or batch file., it''s not included.

--
AnkhSVN - A Visual Studio .NET Addin for the Subversion version control system.
[Project site] [Blog] [RSS] [Browse the source] [IRC channel]

Share this post


Link to post
Share on other sites
I do not have the VC++ .Net Compiler yet, which is why I am asking questions before I buy. The main reason I am getting the compiler is because I want to learn to program DirextX. And maybe write some windows apps if I have to. Having a decent knowledge of dos32 assembly language. I was just wondering how far the assembly support goes in the Standard version of the VC++ .Net compiler? I"d like to be able to use the full range of Pentium/AMD instruction sets (mmx , sse , sse2 , sse3)

quote
Drakkcon
It's called "inline assembly". You use the asm key word followed by braces. Be warned that each compiler has a different implementation of this though.
/quote

I'm using the free borland compiler, and have tried to use assembly but found out that it does not come with an assembler.
I do have MASM 6.? and it works good, but would like to be able to use assembly inside the source itself.

Mateo


[edited by - mateo on April 12, 2004 5:02:35 PM]

[edited by - mateo on April 12, 2004 5:04:05 PM]

[edited by - mateo on April 12, 2004 5:04:27 PM]

Share this post


Link to post
Share on other sites
Most C based compilers allow you to develop in ASM using
syntax like so.

_asm
{
mov eax,dx;

}

Thats the usual way ASM is used in C/C++. If borlands free version doesn''t support it well there are other free ones out there.

Share this post


Link to post
Share on other sites
You know, you can program DirectX in dev-cpp with the mingw compiler. It''s what I use.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Yes, VS.NET 2003 uses intel syntax asm, my installation also appears to have masm installed, although I am using a DDK too ... so I''m not sure if infact masm has come from that.

FWIW: don''t worry about squeezing every last cpu cycle out with asm - in this day and age its rarely an issue ... and if it is get a profiler & find the bottlenecks, once you''ve got a working algorithm!

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
i''m using vs.net 2003 enterprise architect all u need to do to inline assembly is :

__asm
{
//ur assembly code here
}

this is not the standard ( should be asm ) but anyway i think borland also has an assembler but i don''t remember how did i used it (i''m talking about borland 5.something )

also don''t buy the standard edition as it''s not an optimizing compiler like the enter blah blah

by the way does anybody know where i can find the old masm 6.x
i can''t find it at microsoft

Share this post


Link to post
Share on other sites
Unfortunately purchasing professional or enterprise isn''t an option if you''re on a budget. This is compounded even more so by the fact you seem to be required to buy the entire Visual Studio suite to get the Pro/Enterprise editions of products.
Is anybody aware of a way around this limitation, or is that just the way it is?

-Mezz

Share this post


Link to post
Share on other sites
Purchase of MSDN for 1200 is the better bet than the whole Ent,Pro thing. As you can install upto 10 of each OS that comes with it, 2K or 2K3. SQL and tons of other stuff.

Share this post


Link to post
Share on other sites
Drakkon:
I've downloaded free compilers before, Dev c++ included, and the only one that worked for me without much troubles was the borland compiler. But even with the borland compiler there are limitations as to what you can do. Window and Menu design is just one major minus. The other one is of course, no assembler included or available.

Anonymous:
Right now all I can afford is the Standard (the cheapest) Edition. I'm not too worried about major optimizations right now. Just want something to compile the source from the books that I have now and the source from future books that I plan to purchase. I'm in a beginner learning stage (with the c++ language, know 32-bit assembly fairly well though!) and just was curious if you could include assembly in the source itself without linking in an object file or dll.

Mezz:
In the Provantage catalogue, the Standard c++ edition is only $90 (my price range!). Then all I see is the visual studio editions, the pro costs $467 and the enterprise costs $942. And I just noticed that these prices are for the Upgrade versions only. And because I'm not in college, I will be paying FULL price! Hey, anybody know any better deals than this?

Mateo

[edited by - mateo on April 13, 2004 5:20:39 PM]

Share this post


Link to post
Share on other sites

  • Advertisement