On Mon, Dec 19, 2016 at 9:47 AM, Paul Gilmartin <
[email protected]> wrote:

> On Mon, 19 Dec 2016 08:35:33 -0600, Peter Vander Woude wrote:
> >
> >Our programmers used to use a cobol to read in a file, for ebcdic to
> ascii translation, and then this subprogram would be called for each record
> to convert from ebcdic to ascii.  The job steps calling that routine spent
> over 90% of their cpu time in that subprogram.
> >
> >I re-wrote into hlasm, and eliminated at least 80-90% of the cpu time,
> just due to the efficiencies that the assembler code management of the data
> in a table, have vs cobol.
> >
> And that conversion is built in to the z/OS UNIX kernel if the proper
> incantations are performed.
>

​For use with a LE language, I'd use the C language __e2a_l() and
__a2e__l() functions. They have a very easy calling sequence:

__e2a_l(char *buffer, size_t buffer_len)

However, they are dedicated to IBM-1047 <-> ISO8859-1. For a more
generalized approach, I'd use the iconv(), iconv_open(), and iconv_close()
functions. These are all documented in the C Language Run-time Library
manual: http://publibz.boulder.ibm.com/epubs/pdf/edc1b210.pdf
​



>
> -- gil
>
> ----------------------------------------------------------------------
> For IBM-MAIN subscribe / signoff / archive access instructions,
> send email to [email protected] with the message: INFO IBM-MAIN
>



-- 
Heisenberg may have been here.

http://xkcd.com/1770/

Maranatha! <><
John McKown

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to