how to compile assembly

Hi,

I have generated assembly listing in MSVC 6.0.
I have then optimized and changed the code.
How do I then generated the new obj and invoke the linker to make the new program?
Can it be done with MSVC?

THank you.
hengck23Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

BeyondWuCommented:
>>>How do I then generated the new obj and invoke the linker to make the new program?
You can compile it with MASM6.x assembler first and then link it with your other modules.
>>>Can it be done with MSVC?
No, but you can convert your code into inline asm with _asm {... } directive, I think it's maybe the simplest approach for you.

0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
RosuavCommented:
Keep your optimizations to the most crucial loops and such, where it'll actually make a noticable difference - coding in assembly instead of C tends to make your code less readable, so don't do it everywhere.

Before you go for this approach, though, have you compiled in Release mode with optimizations on? Chances are the compiler knows what it's doing.
0
ram_einsteinCommented:
hengck23,

The most popular assemblers on the net are:
NASM (Netwide Assembler): http://sourceforge.net/projects/nasm/
MASM (The Microsoft Macro Assembler): http://webster.cs.ucr.edu/AsmTools/MASM/
TASM (Turbo Assembler): It isn't free. So contact Borland and pay them $$.

I strongly recommend you go for the first one if you're not particular about getting an ancient, expensive compiler (ie. TASM). Don't even think about MASM.

Hope this helps,

ram_einstein
0
mbizupCommented:
No comment has been added to this question in more than 21 days, so it is now classified as abandoned.

I will leave the following recommendation for this question in the Cleanup topic area:
    Accept: BeyondWu {http:#12500621} & Rosuav {http:#12889554} & ram_einstein {http:#13122540}

Any objections should be posted here in the next 4 days. After that time, the question will be closed.

mbizup
EE Cleanup Volunteer
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Assembly

From novice to tech pro — start learning today.