Solved

debug

Posted on 2000-04-28
16
373 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
Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

 
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
 
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

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

What is C++ STL?: STL stands for Standard Template Library and is a part of standard C++ libraries. It contains many useful data structures (containers) and algorithms, which can spare you a lot of the time. Today we will look at the STL Vector. …
Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
The goal of the video will be to teach the user the concept of local variables and scope. An example of a locally defined variable will be given as well as an explanation of what scope is in C++. The local variable and concept of scope will be relat…
The viewer will learn how to clear a vector as well as how to detect empty vectors in C++.

821 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