unnrv2b.S revision 677833bc953b6cb418c701facbdcf4aa18d6c44e
/*
* Copyright (C) 1996-2002 Markus Franz Xaver Johannes Oberhumer
* Copyright (C) 2002 Eric Biederman
*
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of
* the License, or (at your option) any later version.
*
* Originally this code was part of ucl the data compression library
* for upx the ``Ultimate Packer of eXecutables''.
*
* - Converted to gas assembly, and refitted to work with etherboot.
* Eric Biederman 20 Aug 2002
*
* - Converted to functional ia64 assembly (Can this get smaller?)
* Eric Biederman 5 Dec 2002
*/
.text
/* See where I am running, and compute gp */
{
/* Do no call alloc here as I do not know how many argument
* registers are being passed through the decompressor, and if I report
* to few the unreported registers may get stomped.
*
* Instead just explicitly get the value of ar.pfs.
*/
}
{.mlx
}
;;
{
}
{
}
/* ------------- DECOMPRESSION -------------
Input:
r8 - ar.pfs
r14 - source
r15 - dest
r16 - 1
r17 - (buffer) 0
r20 - 0xd00 (constant)
r21 - start address
Usage:
r9 - scratch register for memory copies
r18 - scratch register for getbit
r19 - scratch register for loads and stores
Output:
r2 - 0
r3 - 0
*/
;;
;;
/* Do a unaligned 64bit load */
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
;;
1:
;;
;;
/* Branch to the start address */
;;
;;