Visibility attributes
Visibility attributes describe whether and how an entity that is defined in one module can be referenced or used in other modules. Visibility attributes affect entities with external linkage only, and they cannot increase the visibility of other entities. By specifying visibility attributes for entities, you can export only the entities that are necessary to shared libraries.
With this feature, you can get the following benefits:
- Decrease the size of shared libraries.
- Reduce the possibility of symbol collision.
- Allow more optimization for the compile and link phases.
- Improve the efficiency of dynamic linking.
Note: In IBM Open XL C/C++ for AIX 17.1.3, any
visibility attribute does not have the effect at link time.