2 Replies Last post: Jun 4, 2009 2:56 PM by kelly.arrey  
Click to view ilam's profile   1 posts since
Apr 22, 2009

Apr 24, 2009 10:19 AM

How to pass an adata file generated by the as utility to the DSECT utility?

If a C METAL application is compiled with the xlc utility, and then call the as utility to
assemble the assembler file. How do I pass the associated data file produced by
the as utility to the DSECT utility?

The SYSADATA file that is required by the DSECT utility can
be either a PDS member, a PDSE member, or a sequential file (hereinafter called
the MVS file), but cannot be a z/OS UNIX System Services file. Therefore, when
you invoke the as utility with –gadata option, you need to specify an MVS file
name.

To pass the associated data file produced by the as utility to the DSECT
utility, take the following steps:

1. Compile the C metal program with –S and –qmetal options, the compiler then
generates a.s file.

xlc -S –qmetal a.c
2. Assemble a.s by using the as utility with –gadata option. You need to
specify an MVS file name for the as utility to generate associated data file
'HLQ.ADATA'.

as -gadata="//'HLQ.ADATA'" a.s
3. Invoke the DSECT utility using the following sample JCL:


//DSECT EXEC PGM=CCNEDSCT
//SYSADATA DD DSN=HLQ.ADATA,DISP=SHARE
//EDCDSECT DD SYSOUT=*
Click to view DaveyC's profile   22 posts since
Jan 20, 2009
Thanks for the info.

What would be nice is if the DSECT conversion utility could execute in USS to save having to switch back to ISPF to run the JCL.


The DSECT conversion utility is quite good, but it has it's flaws. It chokes on multi-line comments and I've yet to use it on a non-trivial DSECT without having to hand craft the results. IMO, If Metal C is really going to make a big impact then IBM really need to start providing C structure equivilents of SYS1.MACLIB, SYS1.MODGEN mapping macros. The DSECT conversion utility really doesn't cut it. Maybe a job for an intern.

Click to view kelly.arrey's profile   6 posts since
Nov 19, 2008

Hi Davey,

We're planning to address these issues with the DSECT utility in a future release.

Thanks again,

Kel

Bottom Banner