home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Programming / Misc / CLISP-2.LHA / CLISP960530-ki.lha / ffcall / trampoline / tramp-mips.s < prev    next >
Encoding:
Text File  |  1996-04-15  |  717 b   |  30 lines

  1. /* Trampoline for mips CPU */
  2.  
  3. /*
  4.  * Copyright 1995 Bruno Haible, <haible@ma2s2.mathematik.uni-karlsruhe.de>
  5.  *
  6.  * This is free software distributed under the GNU General Public Licence
  7.  * described in the file COPYING. Contact the author if you don't have this
  8.  * or can't live with it. There is ABSOLUTELY NO WARRANTY, explicit or implied,
  9.  * on this software.
  10.  */
  11.  
  12. /* Available registers: $2, $3. */
  13.  
  14.     .set    nobopt
  15.     .set    noreorder
  16.     .text
  17.     .globl    tramp
  18.     .ent    tramp
  19. tramp:
  20.     li    $2,0x73550000
  21.     ori    $2,$2,0x4711
  22.     sw    $2,0x12345678
  23.     li    $25,0xbabe0000
  24.     ori    $25,$25,0xbec0
  25.     /* The called function expects to see its own address in $25. */
  26.     j    $25
  27.     /* Some Mips hardware running Irix-4.0.5 needs this nop. */
  28.     nop
  29.     .end    tramp
  30.