Appendix D. Performance Considerations

Table of Contents
D.1. Controlling Run-time Checks
D.2. Optimization Levels
D.3. Inlining of Subprograms

The XGC Ada compiler provides a number of options that allow a trade off between

The defaults if no options are selected are aimed at improving the performance of the generated code:

These options are suitable for most program development purposes. This chapter describes how you can modify these choices.

D.1. Controlling Run-time Checks

By default, XGC Ada produces all run-time checks except arithmetic overflow checking for integer operations (including division by zero) and checks for access before elaboration on subprogram calls.

Two gnat switches, -gnatp and -gnato allow this default to be modified. See Section 1.2.3.

Our experience is that the default is suitable for most development purposes.

We treat integer overflow and elaboration checks specially because these are quite expensive and in our experience are not as important as other run-time checks in the development process.

Note that the setting of the switches controls the default setting of the checks. They may be modified using either pragma Suppress (to remove checks) or pragma Unsuppress (to add back suppressed checks) in the program source.