Xref: news-dnh.mv.net comp.os.msdos.djgpp:628 Path: news-dnh.mv.net!mv!news.sprintlink.net!hookup!news.mcgill.ca!clouso.crim.ca!athena.ulaval.ca!ppp077-stdkn2.ulaval.ca!loiselse From: loiselse AT ift DOT ulaval DOT ca (Sebastien Loisel) Newsgroups: comp.os.msdos.djgpp Subject: Inline assembler in GCC for PC Date: Mon, 26 Jun 1995 02:56:03 Organization: Universite Laval Lines: 30 Nntp-Posting-Host: ppp077-stdkn2.ulaval.ca To: djgpp AT sun DOT soe DOT clarkson DOT edu Dj-Gateway: from newsgroup comp.os.msdos.djgpp Hmmm - I am a somewhat experienced programmer, and I normally manage with compiler documentation, but in this case... Could someone point me towards the documentation to the PC/DOS-specific inline assembler? What file is it (or topic in info)? I am also interested in source code that demonstrates the use of inline asm for DJGPP, as inline asm in DJGPP does not follow PC asm conventions at all (maybe they even renamed the registers for all I know). If all else fails, someone could tell me which one of the sources to the DJGPP library would contain the most inline asm in c files? Here is an example of something I would like to get fixed. (By the way, I know perfectly well that outportb is in dos.h, I'm just trying to get an easy example of inline asm to work.) --------8<-----cut here------------------------------------------------------ void SETMODE(short mode) { asm("mov ax,%0 \n int 10h" : : "f" (mode) ); } --------8<-----cut here------------------------------------------------------ Sincerely yours, Sebastien Loisel