Name Strings
SPV_KHR_linkonce_odr
Contact
To report problems with this extension, please open a new issue at:
Contributors
-
Ben Ashbaugh, Intel
-
Mariya Podchishchaeva, Intel
-
Nicolai Hähnle, AMD
Notice
Copyright (c) 2020 The Khronos Group Inc. Copyright terms at http://www.khronos.org/registry/speccopyright.html
Status
-
Complete
-
Approved by the SPIR Working Group: 2020-06-24
-
Ratified the Khronos Group: 2020-08-14
Version
Last Modified Date |
2020-05-19 |
Revision |
1 |
Dependencies
This extension is written against the SPIR-V Specification, Version 1.5 Revision 2, Unified
This extension requires SPIR-V 1.0.
Overview
This extension adds a new Linkage Type LinkOnceODR. A global variable or function with such linkage type can be merged with equivalent global variables or functions from other modules during the linking process. The primary use case of this linkage type is to satisfy the C++ language One Definition Rule.
Extension Name
To use this extension within a SPIR-V module, the following OpExtension must be present in the module:
OpExtension "SPV_KHR_linkonce_odr"
Modifications to the SPIR-V Specification, Version 1.5
Linkage Type
In section 3.17 "Linkage Type" add the following row to the Linkage Type table:
Linkage Type | Enabling Capabilities | |
---|---|---|
2 |
LinkOnceODR |
Linkage |
Issues
-
Do we need to introduce more linkage types, such as weak, weak_odr etc?
RESOLVED: We will not add additional linkage types as part of this extension.
Revision History
Rev | Date | Author | Changes |
---|---|---|---|
1 |
2020-05-19 |
Ben Ashbaugh |
Initial KHR extension. |