www.digitalmars.com         C & C++   DMDScript  

c++.dos - inline assembler using the c compiler

reply lee <lee_member pathlink.com> writes:
I'm trying to call an interrupt service from within an assembly block.
Everytime I make a call to an interrupt service the program crashes.
Looking through previous forum records I found an article describing a similar
problem. In it, the problem was solved by compiling the program for 16 bit dos.
The author did this by adjusting the parameter settings for the compiler.
Unfortunately they didn't go into details. I'm still learning the compiler, but
I assume that they were refering to the memory model flag '-m'. I'm trying to
set the memeory mode to Dos 16 bits, which is indicated by 'd'. The problem is
'dmc ... -md' fails. The syntax structure is given as follows: 
m[tsmclvfnrpxz][do][w][u] 
My guess is that the d option has to be preeceeded by one of these other flags,
but I don't know which.
Jun 28 2006
parent Nic Tiger <g_tiger progtech.ru> writes:
lee wrote:
 I'm trying to call an interrupt service from within an assembly block.
 Everytime I make a call to an interrupt service the program crashes.
 Looking through previous forum records I found an article describing a similar
 problem. In it, the problem was solved by compiling the program for 16 bit dos.
 The author did this by adjusting the parameter settings for the compiler.
 Unfortunately they didn't go into details. I'm still learning the compiler, but
 I assume that they were refering to the memory model flag '-m'. I'm trying to
 set the memeory mode to Dos 16 bits, which is indicated by 'd'. The problem is
 'dmc ... -md' fails. The syntax structure is given as follows: 
 m[tsmclvfnrpxz][do][w][u] 
 My guess is that the d option has to be preeceeded by one of these other flags,
 but I don't know which.
 
 
try -ml (large model) or -mt (tiny model)
Jun 28 2006