Solved

debug

Posted on 2000-04-28
16
365 Views
Last Modified: 2008-02-26
Hi ,good day!

I write a simple assebmly program and want to debug it step by step .When I use VC,it's easy ,there already debugger there.But this assebemly program I write by MASM .

Would you please tell me what tool I can use to debug it step by step with register info?
Btw ,i'm under window98 system.

Thanks!
0
Comment
Question by:zystudio
  • 7
  • 7
  • 2
16 Comments
 
LVL 22

Expert Comment

by:nietod
ID: 2758832
I would suggest you use SoftIce from Nu-mega.  I think they have the best hard-ware level windows compatible debugger on the market.  I used to use Periscope, which was also good, but Soft-ice is a little better.  You can reach them at

www.numega.com
0
 
LVL 22

Expert Comment

by:nietod
ID: 2758836
The best thing about soft-ice is that it allows you to place a monochrome video card in your computer and attach it to a monochrome monitor.  The debugger will display information on this monitor, not on the regular screen.  this allows you to use the debugger and see what is on the screen at the same time.  very nice.  (You don't have to run this way, if you don't have the hardware, but it is really nice.)
0
 

Author Comment

by:zystudio
ID: 2758892
Thank but I cannot pay such money.I need a simple free one.
I use MASM32 FOR WINDOWS assembler ,is there any debugger with it?
0
 
LVL 22

Expert Comment

by:nietod
ID: 2758911
masm probably still comes with a debugger caled "symdeb" or "symdbg"  I can't remember which.  It is very very basic and it probably can't handle 32 bit debugging.  It certainly isn't windows aware in any way.  I don't know if they ship ot anyways.

Other than that, you are going have to pay money.  Debuggers are hard to write--especially in windows--so you probably aren't going to find any for free.

FYI in the future you should try to include all the "conditions" in the original question.  It is a bit unfair to reject an answer because of conditions not present in the question.
0
 
LVL 3

Accepted Solution

by:
PinTail earned 50 total points
ID: 2759219

You can make a VC++ project from your existing source code, then debug from wihtin VC++.  (rember : all C/C++ compilers 'know' assembly language.)
0
 
LVL 22

Expert Comment

by:nietod
ID: 2759296
VC can't debug 16 bit code or non-windows executables.  Only 32 bit windows programs.  It is extremely unlikely that this is for a 32 bit windows program, because it is almost imposible to write them in MASM (16 bit is okay, 32...)
0
 
LVL 3

Expert Comment

by:PinTail
ID: 2759306
>>Btw ,i'm under window98 system.
0
 
LVL 22

Expert Comment

by:nietod
ID: 2759317
We are still talking (probably) about code that is either not a windows program (its DOS) or is not 32 bit.  Have you ever tried to write a 32 bit windows program in MASM?
0
Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

 
LVL 3

Expert Comment

by:PinTail
ID: 2759328
No, I stoped using MASM when I realised how nice it was to write assembly under the VC IDE in VC+ 1.5.

Who writes 16 bit programs any more ?
0
 
LVL 22

Expert Comment

by:nietod
ID: 2759384
>> Who writes 16 bit programs any more ?
Everyone who uses MASM to begin with.   People with legacy issues to contend with (like me.)
0
 

Author Comment

by:zystudio
ID: 2759461
Thank,PinTail.

But How can I write complete assembly code under vc++6.0?

I use .data and .code and use struct ,offset and so on .i.e : Can I just copy all working code in MASM to VC and compile and link? OR there are some limitations?

Thanks!

0
 
LVL 3

Expert Comment

by:PinTail
ID: 2759497
0
 
LVL 22

Expert Comment

by:nietod
ID: 2759507
you can't write the complete code that way, but you can use inline assembly inside a function in C++.   like

int Increment(int i)
{
   __asm
   {
      mov EAX,i
      inc EAX
      mov i,EAX
   }
   return i;  
}

this is sort of the best of both worlds.  Although the in-line asembler is very rudamentary.  it does not have all the features of MASM.  (although many of those features are less important in this case, because you can be used C's features instead.

But you can only do this if you are writting a win32 program.  Is that what you want?
0
 
LVL 3

Expert Comment

by:PinTail
ID: 2759558
Good point.

There are a few things that you may have to change from your existing code, but they ought not be too severe.

If you need to you can also invoke MASM from VC++ see microsoft Knowledge base article : Q106399
0
 
LVL 3

Expert Comment

by:PinTail
ID: 2759646
Good point.

There are a few things that you may have to change from your existing code, but they ought not be too severe.

If you need to you can also invoke MASM from VC++ see microsoft Knowledge base article : Q106399
0
 
LVL 3

Expert Comment

by:PinTail
ID: 2759649
woops
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Errors will happen. It is a fact of life for the programmer. How and when errors are detected have a great impact on quality and cost of a product. It is better to detect errors at compile time, when possible and practical. Errors that make their wa…
Container Orchestration platforms empower organizations to scale their apps at an exceptional rate. This is the reason numerous innovation-driven companies are moving apps to an appropriated datacenter wide platform that empowers them to scale at a …
The viewer will learn how to pass data into a function in C++. This is one step further in using functions. Instead of only printing text onto the console, the function will be able to perform calculations with argumentents given by the user.
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now