Z/OS XL C/C++ Compiler and Runtime Migration Guide for the Application Programmer

Total Page:16

File Type:pdf, Size:1020Kb

Z/OS XL C/C++ Compiler and Runtime Migration Guide for the Application Programmer z/OS Version 2 Release 4 XL C/C++ Compiler and Runtime Migration Guide for the Application Programmer IBM GC14-7306-40 Note Before using this information and the product it supports, read the information in “Notices” on page 127. This edition applies to Version 2 Release 4 of z/OS (5650-ZOS) and to all subsequent releases and modifications until otherwise indicated in new editions. Last updated: 2020-12-14 © Copyright International Business Machines Corporation 1996, 2019. US Government Users Restricted Rights – Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. Contents About this document.............................................................................................xi z/OS XL C/C++ on the World Wide Web.................................................................................................... xix Where to find more information...........................................................................................................xix Technical support...................................................................................................................................... xix How to send your comments to IBM.........................................................................................................xix If you have a technical problem........................................................................................................... xx Part 1. Introduction............................................................................................... 1 Chapter 1. New migration issues for z/OS V2R4 XL C/C++.........................................................................3 Chapter 2. Program migration checklists.................................................................................................... 5 Before you start your migration............................................................................................................. 5 When you are compiling code................................................................................................................ 6 When you are binding program objects or load modules......................................................................7 When you are running an application ....................................................................................................7 Tools that facilitate your migration........................................................................................................ 9 The Edge Portfolio Analyzer..............................................................................................................9 Applicability of product information...................................................................................................... 9 Part 2. Migration of pre-OS/390 C/C++ applications to z/OS V2R4 XL C/C++.......... 11 Chapter 3. Source code compatibility issues with pre-OS/390 C/C++ programs................................... 13 Removal of IBM Open Class Library support.......................................................................................13 Source code modifications necessitated by changes in runtime library............................................ 13 The #pragma runopts directive......................................................................................................13 Resource allocation and memory management issues...................................................................... 13 The sizeof operator applied to a function return type................................................................... 14 A user-defined global new operator and array new...................................................................... 14 Addressing incompatibilities................................................................................................................14 C/370 V2 main program and main entry point.............................................................................. 14 Pointer incompatibilities.................................................................................................................14 Data type incompatibilities.................................................................................................................. 15 Assignment restrictions for packed structures and unions...........................................................15 DSECT header files and packed structures....................................................................................15 Changes required by programs with interlanguage calls....................................................................15 Explicit program mask manipulations............................................................................................15 Assembler source code changes in System Programming C (SPC) applications built with EDCXSTRX..................................................................................................................................16 Internationalization incompatibilities..................................................................................................16 Support of alternate code points....................................................................................................16 Chapter 4. Compile-time issues with pre-OS/390 C/C++ programs........................................................17 Changes in compiler listings, messages, and return codes................................................................ 17 Macro redefinitions might result in severe errors..........................................................................17 Changes in compiler options................................................................................................................17 Compiler options that are no longer supported.............................................................................17 Compiler options that were introduced in OS/390 C/C++ or later................................................18 Changes in compiler option functionality.......................................................................................18 Changes that affect compiler invocations........................................................................................... 21 iii IPA compiler option and very large applications........................................................................... 21 Customized JCL and the CXX format..............................................................................................21 CBCI and CBCXI procedures in JCL............................................................................................... 21 Changes that affect SYSLIB DD cards..................................................................................................21 Change in SCLBH logical record length ......................................................................................... 21 Chapter 5. Bind-time migration issues with pre-OS/390 C/C++ programs............................................. 23 Library release level in use...................................................................................................................23 Binder invocation changes................................................................................................................... 25 Impact of changes to CC EXEC invocation syntax......................................................................... 25 Changes due to customizations of the runtime environment............................................................. 25 User-developed exit routines......................................................................................................... 25 Incompatibilities in external references..............................................................................................26 Requirements for relinking C/370 modules that invoke Debug Tool..................................................26 C/370 modules with interlanguage calls (ILC).................................................................................... 26 Interlanguage calls between assembler and PL/I language modules..........................................26 Function calls between C and Fortran modules............................................................................ 26 Function calls to and from COBOL modules.................................................................................. 27 Chapter 6. Runtime migration issues with pre-OS/390 C/C++ applications........................................... 31 Retention of pre-OS/390 runtime behavior.........................................................................................31 Runtime library messages....................................................................................................................31 Return codes and messages...........................................................................................................31 Error conditions that cause runtime messages............................................................................. 32 Prefixes of perror() and strerror() messages..................................................................................32 Language specification for messages............................................................................................ 32 User-developed exit routines......................................................................................................... 32 Changes that affect customized JCL procedures...............................................................................
Recommended publications
  • IBM Developer for Z/OS Enterprise Edition
    Solution Brief IBM Developer for z/OS Enterprise Edition A comprehensive, robust toolset for developing z/OS applications using DevOps software delivery practices Companies must be agile to respond to market demands. The digital transformation is a continuous process, embracing hybrid cloud and the Application Program Interface (API) economy. To capitalize on opportunities, businesses must modernize existing applications and build new cloud native applications without disrupting services. This transformation is led by software delivery teams employing DevOps practices that include continuous integration and continuous delivery to a shared pipeline. For z/OS Developers, this transformation starts with modern tools that empower them to deliver more, faster, with better quality and agility. IBM Developer for z/OS Enterprise Edition is a modern, robust solution that offers the program analysis, edit, user build, debug, and test capabilities z/OS developers need, plus easy integration with the shared pipeline. The challenge IBM z/OS application development and software delivery teams have unique challenges with applications, tools, and skills. Adoption of agile practices Application modernization “DevOps and agile • Mainframe applications • Applications require development on the platform require frequent updates access to digital services have jumped from the early adopter stage in 2016 to • Development teams must with controlled APIs becoming common among adopt DevOps practices to • The journey to cloud mainframe businesses”1 improve their
    [Show full text]
  • Software Extensibility and the System Object Model (SOM)
    Software Extensibility and the System Object Model (SOM) WWDC Release May 1996 © Apple Computer, Inc. 1992–1996 Apple Computer, Inc. Balloon Help, Chicago, Finder, Some states do not allow the exclusion © 1992–1996 Apple Computer, Inc. Geneva, Mac, and QuickDraw are or limitation of implied warranties or All rights reserved. trademarks of Apple Computer, Inc. liability for incidental or consequential damages, so the above limitation or No part of this publication may be IBM is a registered trademark of exclusion may not apply to you. This reproduced, stored in a retrieval International Business Machines warranty gives you specific legal rights, system, or transmitted, in any form Corporation. and you may also have other rights or by any means, mechanical, MacPaint and MacWrite are which vary from state to state.. electronic, photocopying, recording, registered trademarks, and or otherwise, without prior written Clarisworks is a trademark, of Claris permission of Apple Computer, Inc., Corporation. except to make a backup copy of NuBus is a trademark of Texas any documentation provided on Instruments. CD-ROM. PowerPC is a trademark of The Apple logo is a trademark of International Business Machines Apple Computer, Inc. Corporation, used under license Use of the “keyboard” Apple logo therefrom. (Option-Shift-K) for commercial UNIX is a registered trademark of purposes without the prior written Novell, Inc. in the United States and consent of Apple may constitute other countries, licensed exclusively trademark infringement and unfair through X/Open Company, Ltd. competition in violation of federal and state laws. Simultaneously published in the No licenses, express or implied, are United States and Canada.
    [Show full text]
  • High Performance Computing Toolkit: Installation and Usage Guide | Appendix B
    IBM Parallel Environment Developer Edition High Performance Computing Toolkit Version 2 Release 1 Installation and Usage Guide SC23-7287-00 IBM Parallel Environment Developer Edition High Performance Computing Toolkit Version 2 Release 1 Installation and Usage Guide SC23-7287-00 Note Before using this information and the product it supports, read the information in “Notices” on page 255. This edition applies to version 2, release 1, modification 0 of the IBM Parallel Environment Developer Edition High Performance Computing Toolkit (HPC Toolkit) (product number 5765-PD2) and to all subsequent releases and modifications until otherwise indicated in new editions. © Copyright IBM Corporation 2008, 2014. US Government Users Restricted Rights – Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. Contents Figures ..............vii | Part 3. Using the IBM PE Developer | Edition graphical performance Tables ...............ix || analysis tools ...........21 About this information ........xi | Chapter 6. Using the hpctView Who should read this information .......xi Conventions and terminology used in this || application .............23 information ..............xi || Preparing an application for analysis ......24 Prerequisite and related information ......xii || Working with the application ........25 Parallel Tools Platform component .....xii || Opening the application executable ......25 How to send your comments ........xiii || Instrumenting the application ........28 || Running the instrumented application .....29 Summary of changes ........xv || Viewing performance data .........37 | Chapter 7. Using hardware Limitations and restrictions .....xvii || performance counter profiling.....41 || Preparing an application for profiling......41 Part 1. Introduction .........1 || Instrumenting the application ........41 || Running the instrumented application .....43 Chapter 1. Introduction to the IBM HPC || Viewing hardware performance counter data . 45 Toolkit ...............3 IBM PE Developer Edition components .....3 || Chapter 8.
    [Show full text]
  • Proceedings of the Rexx Symposium for Developers and Users
    SLAC-R-95-464 CONF-9505198-- PROCEEDINGS OF THE REXX SYMPOSIUM FOR DEVELOPERS AND USERS May 1-3,1995 Stanford, California Convened by STANFORD LINEAR ACCELERATOR CENTER STANFORD UNIVERSITY, STANFORD, CALIFORNIA 94309 Program Committee Cathie Dager of SLAC, Convener Forrest Garnett of IBM Pam Taylor of The Workstation Group James Weissman Prepared for the Department of Energy under Contract number DE-AC03-76SF00515 Printed in the United States of America. Available from the National Technical Information Service, U.S. Department of Commerce, 5285 Port Royal Road, Springfield, Virginia 22161. DISTRIBUTION OF THIS DOCUMENT IS UNLIMITED ;--. i*-„r> ->&• DISCLAIMER This report was prepared as an account of work sponsored by an agency of the United States Government. Neither the United States Government nor any agency thereof, nor any of their employees, make any warranty, express or implied, or assumes any legal liability or responsibility for the accuracy, completeness, or usefulness of any information, apparatus, product, or process disclosed, or represents that its use would not infringe privately owned rights. Reference herein to any specific commercial product, process, or service by trade name, trademark, manufacturer, or otherwise does not necessarily constitute or imply its endorsement, recommendation, or favoring by the United States Government or any agency thereof. The views and opinions of authors expressed herein do not necessarily state or reflect those of the United States Government or any agency thereof. DISCLAIMER Portions
    [Show full text]
  • Program Directory for IBM Enterprise COBOL for Z/OS
    IBM Program Directory for IBM Enterprise COBOL for z/OS V06.02.00 Program Number 5655-EC6 FMIDs HADB620, JADB621, JADB622, JADB62H for Use with z/OS Document Date: September 2017 GI13-4526-01 Note Before using this information and the product it supports, be sure to read the general information under 7.0, “Notices” on page 30. © Copyright International Business Machines Corporation 1991, 2017. US Government Users Restricted Rights – Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. Contents 1.0 Introduction . 1 1.1 Enterprise COBOL Description ......................................... 1 1.2 Enterprise COBOL FMIDs ........................................... 4 2.0 Program Materials . 5 2.1 Basic Machine-Readable Material ....................................... 5 2.2 Optional Machine-Readable Material ..................................... 6 2.3 Program Publications . 6 2.3.1 Optional Program Publications ...................................... 7 2.4 Program Source Materials ........................................... 7 2.5 Publications Useful During Installation .................................... 7 3.0 Program Support . 8 3.1 Program Services . 8 3.2 Preventive Service Planning .......................................... 8 3.3 Statement of Support Procedures ....................................... 9 4.0 Program and Service Level Information ................................. 10 4.1 Program Level Information .......................................... 10 4.2 Service Level Information ..........................................
    [Show full text]
  • DB2 Product Overview
    PH061-Martineau.book Page 3 Wednesday, August 6, 2003 7:40 PM C HAPTER 1 DB2 Product Overview he relational database of choice for modern distributed applications is IBM’s DB2 Univer- T sal Database(UDB). Relational databases form the core backend of most enterprise scale applications because of their capability to deliver high performance, support advanced features such as transactions, and maintain data integrity. The Structured Query Language (SQL) provides a powerful standard for accessing and manipulating databases. Its widespread acceptance across all major vendors has also contributed to the success of relational database technology. This chapter introduces major DB2 products so that you can plan the products required for your environment. This is a key to planning the DB2 UDB solution, as shown in Figure 1.1, that is suitable for your project or your organization. OBJECTIVES After reading this chapter you should have an understanding of the following DB2 UDB products: • DB2 UDB Server Products ° DB2 UDB Enterprise Server Edition (ESE) ° DB2 UDB Workgroup Server Edition (WSE) ° DB2 UDB Workgroup Server Unlimited Edition (WSUE) • DB2 UDB Personal Edition (PE) • DB2 UDB Developer’s Products ° DB2 UDB Personal Developer’s Edition ° DB2 UDB Universal Developer’s Edition • DB2 UDB Connect Products ° DB2 UDB Connect Enterprise Edition ° DB2 UDB Connect Unlimited Edition 3 PH061-Martineau.book Page 4 Wednesday, August 6, 2003 7:40 PM 4 Chapter 1 • DB2 Product Overview ° DB2 Connect Personal Edition ° DB2 Connect Application Server Edition • DB2 UDB Clients ° DB2 Run-Time Client ° DB2 Administration Client ° DB2 Application Development Client DB2 UDB SERVER PRODUCTS DB2 UDB server products provide a relational database engine for storing, maintaining, and accessing data.
    [Show full text]
  • IBM Z Open Development Version 1.0: Host Configuration Guide Figures
    IBM Z Open Development Version 1.0 Host Configuration Guide IBM SC27-9297-01 IBM Z Open Development Version 1.0 Host Configuration Guide IBM SC27-9297-01 Note Before using this information, be sure to read the general information under “Notices” on page 27. Second edition (March 2019) This edition applies to IBM Z Open Development Version 1.0 and to all subsequent releases and modifications until otherwise indicated in new editions. IBM welcomes your comments. You can send your comments by mail to the following address: IBM Corporation Attn: Information Development Department 53NA Building 501 P.O. Box 12195 Research Triangle Park NC 27709-2195 USA You can fax your comments to: 1-800-227-5088 (US and Canada) When you send information to IBM, you grant IBM a nonexclusive right to use or distribute the information in any way it believes appropriate without incurring any obligation to you. © Copyright IBM Corporation 2015, 2019. US Government Users Restricted Rights – Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. Contents Figures ............... v Customization setup ........... 11 PARMLIB changes ............ 12 Tables ............... vii Set the z/OS UNIX definitions in BPXPRMxx .. 12 Product enablement in IFAPRDxx ...... 12 LINKLIST definitions in PROGxx ...... 14 About this document ......... ix Requisite LINKLIST and LPA definitions ... 15 Who should use this document ........ ix PROCLIB changes ............ 16 ELAXF* remote build procedures ...... 16 Host Configuration Guide ...... 1 Security definitions ............ 18 idz.env, the environment configuration file .... 18 Chapter 1. Planning.......... 3 Migration considerations .......... 3 Chapter 3. Other customization tasks 21 Planning considerations .......... 3 z/OS UNIX subprojects .........
    [Show full text]
  • Valuing Intellectual Capital, Multinationals and Taxhavens Springer Verlag 2013
    Collected References, available on-line as <i.Stanford.edu/VIC/allVICcitations.pdf> 27-Oct-13 References for: Gio Wiederhold: Valuing Intellectual Capital, Multinationals and Taxhavens Springer Verlag 2013 VIC Citations This list includes all the references cited, as well as others that I have persused. For general information, I chose a recent publication for citation, trusting that it will be easier to locate and cite earlier work. As is common in tax matters, opinions abound. Refereed material is italicized. Entries cited and listed in the Reference section of Valuing Intelectual Capital have [bold identifiers]; entries considered, but not cited are marked ‡. Entries marked † were used for [W:06] . Transcription into the spreadsheet for VIC are marked [xls/worksheet]. Shaded text is to be omitted in publication, but helpful for search or as an aide de memoire. I am dding {chapter.section} references AAAAAAA [Aaron:13B] Henry J. Aaron: Tax Reform? Between a Rock and a Hard Place; Huffington Post, Brookings, 15 Jan. 2013. The 1986 reforms shifted $1T (adjusted) from individuals to Corportations over 10 years. Mobility of capital and the proliferation of multinatinal companies prevents such a solution now. Must raise personal income tax.{VIC Ch10.7.4} [Aaron:13G] Henry J. Aaron: You Get What You Pay For: Lessons From the IRS Scandal; Brookings, 31 May 2013. Only 1% of returns is audited. $450B is uncollected. Each dollar spent auditing yields $8. {VIC Ch8,7.3} [AbahoonieA:10]‡ Edward Abahoonie and Liah Alfonso: Deferred taxes on foreign earnings: A road map; Price Waterhouse Coopers (PwC), Dec.2010, updated 2012 www.pwc/us/tax.
    [Show full text]
  • Enabling White-Box Reuse in a Pure Composition Language
    Enabling White-Box Reuse in a Pure Composition Language Diplomarbeit der Philosophisch-naturwissenschaftlichen Fakultat¨ der Universitat¨ Bern vorgelegt von Andreas Schlapbach Dezember 2002 Leiter der Arbeit: Prof. Dr. O. Nierstrasz Nathanael Scharli¨ Institut fur¨ Informatik und angewandte Mathematik i Abstract Inheritance is a key concept of object-oriented programming languages, features such as conceptual modeling and reusability are largely accredited to it. While many useful com- ponents have been, and will be, developed in this paradigm, the form of white-box reuse offered by inheritance has a fundamental flaw: reusing components by inheritance requires an understanding of the internals of the components. We can not treat components of object-oriented languages as black-box entities, inheritance breaks encapsulation and in- troduces subtle dependencies between base and extending classes. Component-oriented programming addresses this problem by shifting away from program- ming towards software composition. We build applications by scripting components. In- stead of overriding the internals of a component, we focus on composing its interfaces only. This form of black-box reuse leads to a flexible and extendible architecture with reusable components. In this master's thesis we propose a migration strategy from class inheritance { a white- box form of reuse { to component composition as a black-box form of reuse. We present a language extension that gives us the power of inheritance combined with the ease of scripting. It enables us to reuse Java components using inheritance in JPiccola { a small, pure and general composition language implemented on the Java platform { at a high level of abstraction. Using the services provided by the language extension we can seamlessly generate interfaces and subclasses from JPiccola.
    [Show full text]
  • Smalltalk Volume 2 Issue 7
    The International Newsletter for Smalltalk Programmers May 1993 Volume 2 Number 7 ecognizing Smalltalk’s increasing importance as a mainstream pro- TOWARD A gramming language and acting as a large user of the language, IBM D recently proposed the formation of a standards effort within ANSI to define a Smalltalk language standard and offered a “common SMALLTALK base” strawman to start such an effort. At this time the proposal has beenQaccepted by the ANSI SPARC committee, and the formation of an ANSI STANDARD: Smalltalk committee has begun. This article focuses on technical issues regarding the common base. We have written a companion article that will appear in OBJECT MAGAZINE,which outlines TECHNICAL ASPECTS the history of the development of the common base. WHAT IS THE COMMON BASE? OF THE COMMON BASE As part of the proposal for an ANSI Smalltalk standards effort, we have con- tributed a “strawman” as the starting point for standardization. That strawman is contained in the IBM document entitled Smalhalk Portability A Common Base By R.J. DeNatale and comprises chapters 3–5 and appendices A and B from that document. * & Y.P. Shari This proposal is not our work entirely. It is the result of an 18-month-long col- laboration among five companies: IBM, Digitalk, KSC, OTI, and ParcPlace. Contenti: A purely syntactic description of Smalltalk results in a language specification that is incomplete when compared to those for languages such as C, COBOL, Features/Articles and FORTRAN. When studying the specification for a language one expects to 1 The Smalltalk standard: Technical learn things, such as how to do arithmetic, how to code conditional logic, and so aepects of the common base forth.
    [Show full text]
  • XL C/C++ Compiler and Runtime Migration Guide for the Application Programmer
    z/OS Version 2 Release 3 XL C/C++ Compiler and Runtime Migration Guide for the Application Programmer IBM GC14-7306-30 Note Before using this information and the product it supports, read the information in “Notices” on page 129. This edition applies to Version 2 Release 3 of z/OS (5650-ZOS) and to all subsequent releases and modifications until otherwise indicated in new editions. Last updated: 2019-02-15 © Copyright International Business Machines Corporation 1996, 2017. US Government Users Restricted Rights – Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. Contents About this document.............................................................................................xi z/OS XL C/C++ on the World Wide Web.................................................................................................... xix Where to find more information...........................................................................................................xix Technical support...................................................................................................................................... xix How to send your comments to IBM.........................................................................................................xix If you have a technical problem........................................................................................................... xx Part 1. Introduction..............................................................................................
    [Show full text]
  • On the Benefits and Problems of the Object-Oriented Paradigm Including a Finnish Study
    EKONOMI OCH SAMHÄLLE Skrifter utgivna vid Svenska handelshögskolan Publications of the Swedish School of Economics and Business Administration Nr 151 PATRIK PAETAU ON THE BENEFITS AND PROBLEMS OF THE OBJECT-ORIENTED PARADIGM INCLUDING A FINNISH STUDY Helsingfors 2005 On the Benefits and Problems of the Object-Oriented Paradigm including a Finnish Study Key words: Object-oriented paradigm, benefits with object-oriented paradigm, problems with object-oriented paradigm, software components, reuse © Swedish School of Economics and Business Administration & Patrik Paetau Patrik Paetau Swedish School of Economics and Business Administration Department of Management and Organization (Information Systems Science) P.O.Box 287 65101 Vaasa, Finland Distributor: Library Swedish School of Economics and Business Administration P.O.Box 479 00101 Helsinki, Finland Telephone: +358-9-431 33 376, +358-9-431 33 265 Fax: +358-9-431 33 425 E-mail: [email protected] http://www.hanken.fi ISBN 951-555-893-X (printed) ISBN 951-555-894-8 (PDF) ISSN 0424-7256 Edita Prima Ltd, Helsingfors 2005 For my son Robin ACKNOWLEDGEMENTS Although there may still be much to discover and understand as far as benefits and problems with the object-oriented paradigm are concerned, the writing of this dissertation is now, after several years, coming to an end. The opportunity has therefore come to look back and give due credit to those who have supported and encouraged me in different ways. My first interest in the object-oriented world began in 1989 when my former manager at Tietotehdas Oy (Tietoenator nowadays) Vice President Tiina Kurki asked me if I wanted to get to know what objects actually are.
    [Show full text]