Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home
HP-UX Reference > H

hppac(3X)

PA-RISC Systems Only
HP-UX 11i Version 3: February 2007
» 

Technical documentation

» Feedback
Content starts here

 » Table of Contents

 » Index

NAME

hppac: HPPACADDD(), HPPACCMPD(), HPPACCVAD(), HPPACCVBD(), HPPACCVDA(), HPPACCVDB(), HPPACDIVD(), HPPACLONGDIVD(), HPPACMPYD(), HPPACNSLD(), HPPACSLD(), HPPACSRD(), HPPACSUBD() — HP 3000-mode packed-decimal library

SYNOPSIS

#include <hppac.h> void HPPACADDD( unsigned char *operand2, int op2digs, unsigned char *operand1, int op1digs, enum HPPAC_CC *compcode, int *pacstatus ); void HPPACCMPD( unsigned char *operand1, int op1digs, unsigned char *operand2, int op2digs, enum HPPAC_CC *compcode, int *pacstatus ); void HPPACCVAD( unsigned char *target, int targetdigs, unsigned char *source, int sourcedigs, enum HPPAC_CC *compcode, int *pacstatus ); void HPPACCVBD( unsigned char *target, int targetdigs, unsigned short *source, int sourcewords, enum HPPAC_CC *compcode, int *pacstatus ); void HPPACCVDA( unsigned char *target, int targetdigs, unsigned char *source, int sign_control, enum HPPAC_CC *compcode, int *pacstatus ); void HPPACCVDB( unsigned short *target, unsigned char *source, int sourcedigs, enum HPPAC_CC *compcode, int *pacstatus ); void HPPACDIVD( unsigned char *operand2, int op2digs, unsigned char *operand1, int op1digs, enum HPPAC_CC *compcode, int *pacstatus ); void HPPACLONGDIVD( unsigned char *operand2, int op2digs, unsigned char *operand1, int op1digs, enum HPPAC_CC *compcode, int *pacstatus ); void HPPACMPYD( unsigned char *operand2, int op2digs, unsigned char *operand1, int op1digs, enum HPPAC_CC *compcode, int *pacstatus ); void HPPACNSLD( unsigned char *operand2, int op2digs, unsigned char *operand1, int op1digs, int *shift_amt, enum HPPAC_CC *compcode, int *pacstatus, int *carry ); void HPPACSLD( unsigned char *operand2, int op2digs, unsigned char *operand1, int op1digs, int shift_amt, enum HPPAC_CC *compcode, int *pacstatus, int *carry ); void HPPACSRD( unsigned char *operand2, int op2digs, unsigned char *operand1, int op1digs, int shift_amt, enum HPPAC_CC *compcode, int *pacstatus ); void HPPACSUBD( unsigned char *operand2, int op2digs, unsigned char *operand1, int op1digs, enum HPPAC_CC *compcode, int *pacstatus );

DESCRIPTION

This set of calls invokes the library functions for emulating 3000-mode (MPE V/E) packed-decimal operations. These functions are in library libcl which is searched when the option -lcl is used with cc or ld(1).

HPPACADDD()

Performs packed-decimal addition.

HPPACCMPD()

Compares two packed-decimal numbers.

HPPACCVAD()

Converts an ASCII representation to packed-decimal.

HPPACCVBD()

Converts a binary representation to packed-decimal.

HPPACCVDA()

Converts a packed-decimal number to ASCII.

HPPACCVDB()

Converts a packed-decimal number to binary.

HPPACDIVD()

Performs packed-decimal division.

HPPACLONGDIVD()

Performs packed-decimal division (alternate routine).

HPPACMPYD()

Performs packed-decimal multiplication.

HPPACNSLD()

Performs a packed-decimal normalizing left shift.

HPPACSLD()

Performs a packed-decimal left shift.

HPPACSRD()

Performs a packed-decimal right shift.

HPPACSUBD()

Performs packed-decimal subtraction.

For all operations, the value returned in the variable to which the compcode argument points is one of the following values of type enum HPPAC_CC:

HPPAC_CCG

Result > 0 or operand1 > operand2

HPPAC_CCL

Result < 0 or operand1 < operand2

HPPAC_CCE

Result == 0 or operand1 == operand2

For all operations, the value returned in the variable to which the pacstatus argument points is one of the following values of type enum HPPAC_STATUS. Their meanings are intended to be obvious:

HPPAC_NO_ERROR

HPPAC_DECIMAL_OVERFLOW

HPPAC_INVALID_ASCII_DIGIT

HPPAC_INVALID_PACKED_DECIMAL_DIGIT

HPPAC_INVALID_SOURCE_WORD_COUNT

HPPAC_INVALID_DECIMAL_OPERAND_LENGTH

HPPAC_DECIMAL_DIVIDE_BY_ZERO

AUTHOR

The HPPAC library was developed by HP.

SEE ALSO

Compiler Library/XL Reference Manual

Printable version
Privacy statement Using this site means you accept its terms Feedback to webmaster
© 1983-2007 Hewlett-Packard Development Company, L.P.