Metal C only supports virtual IO (i.e., sprintf, etc). It does not
support any real IO.
That said, I HAVE gotten it to support some things that are not in the
manual. For example, I took the time routines from MVS gcc and set them
up to be called from Metal C and they work fine.
I have also gotten some other things from MVS gcc to run with Metal C.
For example, we needed to be able to do some things in ASCII on z/OS.
The normal functions from Metal C or LE do things in EBCDIC. So again I
took the MVS gcc routines that already had OS390 switches to do
different things in EBCDIC or ASCII and just took out the OS390 stuff so
the functions work with ASCII.
I have not tried to use any of the gcc IO routines with Metal C because
the environments that I run in do not support doing IO.
Also, if you use the static link capabilities that are documented in the
z/OS 1.12 Metal C manual, you can run Metal C programs on older z/OS
systems. You are not limited to the compile system and newer.
Lloyd
On 6/6/2014 7:57 PM, Scott Ford wrote:
Peter,
I assumed no based on what I read but I didn't see it in the manual per se. I
appreciate the help. Just means we write in XL C ...
Scott ford
www.identityforge.com
from my IPAD
On Jun 6, 2014, at 6:24 PM, "Farley, Peter x23353"
<[email protected]> wrote:
Scott,
This is the Metal C "Programming Guide and Reference" (watch the wrap):
http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/CCRUG130/CCONTENTS?SHELF=cbcbs1c0&DN=SA23-2225-03&DT=20100705233441
To answer your questions, No and No.
AFAICT, Metal C is intended as an "HLL" (FSVO "H"LL) replacement for assembler,
to be used for such things as exits or any other reason(s) you may have that require
assembler-level capabilities.
As the name suggests, it is a "bare metal" flavor of C, with a very limited number of C library functions
available. All library functions are installed standard in z/OS system memory and accessed via "jump"
control blocks. IOW, no LE here, and no actual library of functions so no "dynamic load" or "static
link" of library routines, and if you write it on your system it should run on someone else's system at the same
or higher (and sometimes lower) level.
So no C library routines for threads or for TCPIP, but you could write your own
in Metal C if you should choose to do so. I wouldn't, but maybe that's just me.
OTOH you can write Metal C code that ATTACHes real z/OS tasks and WAIT's on
real ECB lists (using the real assembler macros), or uses BSAM for playing with
datasets, etc.
There's more, but those are the "bare" facts as I know them.
HTH
Peter
-----Original Message-----
From: IBM Mainframe Discussion List [mailto:[email protected]] On Behalf
Of Scott Ford
Sent: Friday, June 06, 2014 5:23 PM
To: [email protected]
Subject: Metal C
All:
Does anyone know where I can find a comparison of Metal C vs IBM XL C ….?
I am particularly interested in what Metal C does not support. Does it support
threads and TCPIP ?
Regards,
Scott
--
This message and any attachments are intended only for the use of the addressee
and may contain information that is privileged and confidential. If the reader
of the message is not the intended recipient or an authorized representative of
the intended recipient, you are hereby notified that any dissemination of this
communication is strictly prohibited. If you have received this communication
in error, please notify us immediately by e-mail and delete the message and any
attachments from your system.
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN