| 
                  The C Calling Convention
                   An Introduction  | 
            
| 
                   
                      
                     Prof. David Bernstein
                       | 
            
| Computer Science Department | 
| bernstdh@jmu.edu | 
               
            
         
            
         
         
            
         
         
            
         
         
            
         Prologue
Body
...
         
            
         ...
Epilogue
         
            
         
         
            
         ebp holds the base pointeresp holds the current stack pointereip holds the next instruction to be executedeax,ecx,
              edx
                     ebx,edi,
              esi
                     mov:
      mov 
                        source 
                        destination
                     mov 
                        destination, source
                     
         
            
         push:
      esp by 4 (e.g., down if the stack grows 
              down)[esp]
                     pop:
      [esp] into the
              operandesp by 4 (e.g., up if the stack 
              grows down)jmp:
      call:
      ret: