Re: Vector processing instructions

2017-08-09 Thread John P. Baker
Amrith, Converting a 128-bit unsigned fixed binary integer to packed decimal is not particularly difficult. The following methodology should meet your needs - IVFB - Input Value (128-bit Unsigned Fixed Binary) WVFB - Working Value (128-bit Unsigned Fixed Binary) AFPD - Adjustment Factor

Re: Vector processing instructions

2017-08-09 Thread Charles Mills
A 40-digit decimal number? Really? The main advantage of binary integers is that they compute readily on a computer. The main advantage of decimal integers is that they are easy for humans to read. But 40-digit decimal numbers? Charles -Original Message- From: IBM Mainframe Discussion

Re: Vector processing instructions

2017-08-07 Thread Paul Gilmartin
On Mon, 7 Aug 2017 15:03:00 -0400, Steve Smith wrote: >Maybe you could show your code. MP and DP can be tricky, but when you >CVDG the high D-word, you'd then multiply it by >9,223,372,036,854,775,808, then by 2 (or something equivalent). Add >to what you CVDG from the low D-word. > >Of course,

Re: Vector processing instructions

2017-08-07 Thread Steve Smith
Maybe you could show your code. MP and DP can be tricky, but when you CVDG the high D-word, you'd then multiply it by 9,223,372,036,854,775,808, then by 2 (or something equivalent). Add to what you CVDG from the low D-word. Of course, this will overflow if the value is too large for 31 digits,

Re: Vector processing instructions

2017-08-07 Thread Paul Gilmartin
On Mon, 7 Aug 2017 11:17:05 -0500, Todd Arnold wrote: >I got this answer from someone else at IBM, who is an expert in the vector >instructions: >"Currently to convert a 128-bit singed/unsigned integer in a vector register >to a packed decimal value you must store the value to memory and use

Re: Vector processing instructions

2017-08-07 Thread Amrith
arithmetic and the outputs from z13 and Java did not match. On Mon, 8/7/17, Todd Arnold <arno...@us.ibm.com> wrote: Subject: Re: Vector processing instructions To: IBM-MAIN@LISTSERV.UA.EDU Date: Monday, August 7, 2017, 4:17 PM I got this answe

Re: Vector processing instructions

2017-08-07 Thread Todd Arnold
I got this answer from someone else at IBM, who is an expert in the vector instructions: "Currently to convert a 128-bit singed/unsigned integer in a vector register to a packed decimal value you must store the value to memory and use the standard integer conversion instruction CVBG to convert