Where allowed to run: All environments (*ALL) Threadsafe: No |
Parameters Examples Error messages |
The Change Module (CHGMOD) command changes the attributes of a module object without requiring the module to be recompiled.
Restrictions:
Top |
Keyword | Description | Choices | Notes |
---|---|---|---|
MODULE | Module | Qualified object name | Required, Key, Positional 1 |
Qualifier 1: Module | Generic name, name, *ALL | ||
Qualifier 2: Library | Name, *USRLIBL, *LIBL | ||
OPTIMIZE | Optimize module | *SAME, *FULL, *BASIC, *NONE, 40, 30, 20, 10 | Optional |
RMVOBS | Remove observable info | Single values: *SAME, *NONE, *ALL Other values (up to 3 repetitions): *CRTDTA, *DBGDTA, *ILDTA |
Optional |
ENBPFRCOL | Enable performance collection | Single values: *SAME, *NONE, *PEP Other values: Element list |
Optional |
Element 1: Collection level | *FULL, *ENTRYEXIT | ||
Element 2: Procedures | *ALLPRC, *NONLEAF | ||
PRFDTA | Profiling data | *SAME, *NOCOL, *COL | Optional |
FRCCRT | Force module recreation | *NO, *YES | Optional |
TEXT | Text 'description' | Character value, *SAME, *BLANK | Optional |
LICOPT | Licensed Internal Code options | Single values: *SAME, *NONE Other values: Element list |
Optional |
Element 1: Options | Character value | ||
Element 2: Action | *REPLACE, *ADD |
Top |
Specifies the module for which attributes are to be changed.
This is a required parameter.
Qualifier 1: Module
Qualifier 2: Library
Top |
Specifies the optimization level for the generated code in the module. Changing the optimization level of the module causes the system to re-create the module with the new optimization level.
Note: The value of the variable displayed during debugging may not be the current value of the variable.
Top |
Specifies whether the observable information associated with modules is to be removed.
Note: *ALL cannot be specified if the module is enabled to collect profiling data.
Top |
Specifies whether collection of performance data is enabled.
Single values
Element 1: Collection level
Element 2: Procedures
Top |
Specifies the program profiling data attribute for the module. Program profiling is an advanced optimization technique to reorder procedures and code within the procedures based on statistical data (profiling data).
Note: *COL can be specified only when the optimization level of the module is *FULL (30) or greater.
Top |
Specifies whether module re-creation is forced.
Top |
Specifies text that briefly describes the module and its function.
Top |
Specifies individual Licensed Internal Code compile-time options to be selected, and is intended for the advanced programmer who understands the potential benefits and drawbacks of each selected compiler option. Changing the Licensed Internal Code options of an Integrated Language Environment (ILE) module to any value other than *SAME causes the system to re-create the ILE module. Note: Additional information about the LICOPT options can be found in the ILE Concepts book, SC41-5606.
Element 1: Options
Element 2: Action
Top |
Example 1: Optimizing for Maximum Performance
CHGMOD MODULE(XYZ/PERFMOD) OPTIMIZE(40)
This command optimizes module PERFMOD in library XYZ to ensure optimum performance.
Example 2: Removing All Observability
CHGMOD MODULE(XYZ/NOOBSERV) RMVOBS(*ALL)
This command removes all observability from module NOOBSERV in library XYZ. It can not be re-created, and can not be debugged when it is included in a program or service program object.
Example 3: Enabling Collection of Profiling Data
CHGMOD MODULE(XYZ/PROFMOD) OPTIMIZE(30) PRFDTA(*COL)
This command enables module PROFMOD in library XYZ to collect profiling data when it is included in a program or service program object. The optimization level must be 30 or greater to enable a module to collect profiling data.
Top |
*ESCAPE Messages
Top |