www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1999/01/08/09:33:41

Message-ID: <19990108143156.1466.qmail@hotmail.com>
X-Originating-IP: [194.79.98.41]
From: "Mohamed El-dawy" <msdawy AT hotmail DOT com>
To: djgpp AT delorie DOT com
Subject: some questions...
Date: Fri, 08 Jan 1999 06:31:54 PST
Mime-Version: 1.0
Reply-To: djgpp AT delorie DOT com

Hi all,
   I would sincerely like to thank  u all for the great effort u r 
doing! this mailing list is one of the most active (and most friendly) 
mailing list i have ever seen. thanx every body!

   well... I'd love to ask some questions!
   1) how can i determine the free amount of PHYSICAL memory? and how 
can i determine the free amount of TOTAL memory (physical+virtual)?

   2) I have written a very simple clear screen program in assembler, it 
was working fine on Borland C++ but it causes an SIGSEGV fault when i 
run the DJGPP version under windows 98! here is the DJGPP version:

void cls(unsigned int where)
{
	asm("movl $16000,%%ecx\n"
	    "movl %0,%%edi\n"
	    "movl $0x0,%%eax\n"
	    "rep\n"
	    "stosl\n"
            : :"g" (where):"esi","edi","eax","ecx","memory");	    
}

and here it is in Intel syntax:
   mov ecx,16000
   mov edi,where
   mov eax,0
   rep stosd

when called with cls(0xa0000) (after setting mode to 320*200 of course) 
it causes a SIGSEGV fault when running! any suggestions?
  here is the SIGSEGV message:


   Exiting due to signal SIGSEGV
General Protection Fault at eip=000015ba
eax=00000000 ebx=000082e5 ecx=00003e80 edx=0001001e esi=00000054 
edi=000a0000
ebp=000910d4 esp=000910cc program=D:\DJGPP\BIN\TEST2.EXE
cs: sel=01f7  base=82e51000  limit=0009ffff


any suggestions are appreciated!

   Keep up the good work guys! See u soon...


With love,
   Mohamed El Dawy

______________________________________________________
Get Your Private, Free Email at http://www.hotmail.com

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019