_leb128_unsigned_decode64(3E)

_leb128_unsigned_decode64, _leb128_signed_decode64, _leb128_unsigned_decode32, _leb128_signed_decode32 - Decodes leb128 integers

As shipped in IRIX 6.5.19. Last changed in IRIX 6.5.19.

NAME
     _leb128_unsigned_decode64, _leb128_signed_decode64,
     _leb128_unsigned_decode32, _leb128_signed_decode32 - Decodes leb128
     integers

SYNOPSIS
     #include <cmplrs/leb128.h>

     int _leb128_unsigned_decode64(char* data, __uint64_t* value);

     int _leb128_signed_decode64(char* data, __int64_t* value);

     int _leb128_unsigned_decode32(char* data, __int64_t* value);

     int _leb128_signed_decode32(char* data, __int64_t* value);

DESCRIPTION
     These routines decode leb128 numbers into the integers they encode.
     The leb128 format is a variable-length encoding extensively used in
     the DWARF debugging information format and is described in the DWARF
     documentation.

     The caller must know if the leb128 number data in hand is 32 or 64 bit
     and if it is signed or unsigned.  Nothing in the leb128 format makes
     it possible to determine this from the input data itself.

     If data points to a number that fits in 32 bits, either the 32-bit or
     64-bit decoding routine may be called: the correct value is returned
     through the value pointer.  If data points at a number too large to
     fit in 32 bits both the returned-value and the number of bytes
     returned by either of the 32-bit functions will be incorrect.

     The decoded number is placed into data and the number of bytes of data
     which held the number is returned.

     Link with the option -lelfutil to link in these routines.

     The arguments are as follows:

     data A pointer to the input number to be converted from leb128 format
          into an integer.

     value
          A pointer to properly aligned space (provided by the caller) to
          which the called routine writes the decoded integer value.

FILES
     /usr/include/cmplrs/leb128.h
     /usr/lib/libelfutil.a
     /usr/lib32/libelfutil.a
     /usr/lib64/libelfutil.a

DIAGNOSTICS
     Returns the number of bytes found and used in decoding the number.
     The returned value will be in the range 1 to 5 for the 32-bit number
     input versions.  The returned value will be in the range 1 to 10 for
     the 64-bit number input versions.

     If a number is erroneously encoded for the call (if the decoded value
     will not fit in the provided value pointed to) there is no error
     indication; instead a value is returned and the length returned is 5
     (for the 32-bit versions) or 10 (for the 64-bit versions).

SEE ALSO
     _leb128_signed_encode64(3E),
     _leb128_signed_encode32(3E),
     _leb128_unsigned_encode64(3E),
     _leb128_unsigned_encode32(3E),
     libelfutil(5),
     xlate(4),