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

Started by
11 comments, last by mateo 20 years ago
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.
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
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]
--AnkhSVN - A Visual Studio .NET Addin for the Subversion version control system.[Project site] [IRC channel] [Blog]
BTW masm is different than x86 asm, which is probably what you were using.
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]
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.
--What are you nutz?I have nothing to say to your unevolved little brain. The more I say gives you more weapons to ask stupid questions.
You know, you can program DirectX in dev-cpp with the mingw compiler. It''s what I use.
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!
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
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

This topic is closed to new replies.

Advertisement