Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Weird Problem with TASM

Status
Not open for further replies.

ackka

Programmer
Sep 25, 1999
269
0
0
US
This is a problem that i have noticed for some time now with TD.exe, the Debugger that comes with tasm. I have a really simple test program so i know it has nothing to do with the Assembly program. Here is the program
;============================================================
;
; test program homework 5
;
;
;============================================================
.MODEL SMALL,BASIC,FARSTACK
;============================================================
;
; S T A C K S E G M E N T D E F I N I T I O N
;
.STACK 16
;============================================================
;
; D A T A S E G M E N T D E F I N I T I O N
;
.FARDATA DATA
;
db1 DB 10110111b
db2 DB -2
db3 DB '1'
db4 DB 5 DUP('x')
dw1 DW 1001
dw2 DW -20
db5 DB -129
db9 DB 'aaaaaaaa aaaaaaaa aaaaaaaaaa'
;============================================================
;
; C O D E S E G M E N T D E F I N I T I O N
;
.CODE
ASSUME DS:DATA
PR_2_1: MOV AX,SEG DATA
MOV DS,AX
NOP
;
MOV AX,2
;
.EXIT ;RETURN TO DOS
END PR_2_1


;what program variables should be....
;pr_2_1 @1022:0000
;db1 '+' 183 (B7h)
;db2 '_' 254 (FEh)
;db3 '1' 49 (31h)
;db4 "xxxxx"
;dw1 1001 (3E9h)
;dw2 65516 (FFECh)
;db5 '' 127 (7Fh)
;db9 "aaaaaaaa aaaaaaaa aaaaaaaaaa"

What happens is i load this executable, i view the variables before running and get the top configuration, which is correct. I then hit F7 to step one line through the code, and viewing the variables you get this....
pr_2_1 @102F:0000
db1 ' ' 0 (00h)
db2 ' ' 0 (00h)
db3 '1' 49 (31h)
db4 "xxxxx"
dw1 1001 (3E9h)
dw2 65516 (FFECh)
db5 '' 127 (7Fh)
db9 "aaaaaaaa aaaaaaaa aaaaaaaaaa"

As you can see the first two variables have somehow been initialized to 0 ????????????
This always happens no matter what type of program i run, if i use one variable it turns to 0 etc... I tried installing the patches from Borlands website with no luck. This may be particular to Turbo Debugger as i have not tested it on any other Debuggers.....
This is on a Dell Computer with a Intel Pentium II Processor with 64mb or Ram running windows 98 version 4.10.1998

Thanks for any help [sig]<p>ackka<br><a href=mailto:tmoses@iname.com>tmoses@iname.com</a><br><a href= my site</a><br>"Do No Harm, Leave No Tracks"<br>
ICMP Summer 2000, 2600 Article<br>
<br>
[/sig]
 
That very last line is very important: &quot;...running Windows 98...&quot;. Windows works in protected mode and I believe TASM is for real mode. Try starting your computer without protected mode initialization (no himem.sys etc. in you config.sys file) and without starting Windows.
I don't know if it will help, but Windows can do strange things with my Turbo Pascal programs.

Regards, [sig]<p>Bert Vingerhoets<br><a href=mailto:vingerhoetsbert@hotmail.com>vingerhoetsbert@hotmail.com</a><br><a href= Webpage</a><br>Don't worry what people think about you. They're too busy wondering what you think about them.[/sig]
 
That has been my interpretation as well, Tubro Debugger works fine when it is launched into the actual dos OS from a 98 machine. Not when using a DOS emulation box inside of win98, i will post this in the 98 section..

Thanks

[sig]<p>ackka<br><a href=mailto:tmoses@iname.com>tmoses@iname.com</a><br><a href= my site</a><br>"Do No Harm, Leave No Tracks"<br>
ICMP Summer 2000, 2600 Article<br>
<br>
[/sig]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top