C++ Programming/Programming Languages/C++/Code/Keywords/asm

From Wikibooks, open books for an open world
Jump to navigation Jump to search

The asm keyword is used to declare an inline assembly code. When using the windows compiler, the __asm keyword is used instead. Here the asm keyword does not do anything.

asm {  
   mov al, 4  
   mov dx, 0xD007  
   out dx, al