LINUX.ORG.RU

История изменений

Исправление V1KT0P, (текущая версия) :

Тогда, в OpenGL мы только его и перекомпилим и слинкуем программу заново.

Я вот смотрю что написано в спецификации SPIRV 1.0: https://www.khronos.org/registry/spir-v/specs/1.0/SPIRV.html
И там написано что можно вызывать функции из уже скомпилированных модулей, как ты это описал.

Вот здесь написано что можно вызывать функции из других модулей:

2.9. Function Calling

To call a function defined in the current module or a function declared to be imported from another module, use OpFunctionCall with an operand that is the <id> of the OpFunction to call, and the <id>s of the arguments to pass. All arguments are passed by value into the called function. This includes pointers, through which a callee object could be modified.

А вот тут написано что можно импортировать функции которые экспортированы другим модулем и что это связывание происходит на этапе линковки:

2.13. Linkage

The ability to have partially linked modules and libraries is provided as part of the Linkage capability.

By default, functions and global variables are private to a module and cannot be accessed by other modules. However, a module may be written to export or import functions and global (module scope) variables. Imported functions and global variable definitions are resolved at linkage time. A module is considered to be partially linked if it depends on imported values.

Исходная версия V1KT0P, :

Тогда, в OpenGL мы только его и перекомпилим и слинкуем программу заново.

Я вот смотрю что написано в спецификации SPIRV 1.0: https://www.khronos.org/registry/spir-v/specs/1.0/SPIRV.html
И там написано что можно вызывать функции из уже скомпилированных модулей, как ты это описал.

Вот здесь написано что можно вызывать функции из других модулей:

2.9. Function Calling

To call a function defined in the current module or a function declared to be imported from another module, use OpFunctionCall with an operand that is the <id> of the OpFunction to call, and the <id>s of the arguments to pass. All arguments are passed by value into the called function. This includes pointers, through which a callee object could be modified.

А вот тут написано что можно импортировать функции который экспортированы другим модулем и что это связывание происходит на этапе линковки:

2.13. Linkage

The ability to have partially linked modules and libraries is provided as part of the Linkage capability.

By default, functions and global variables are private to a module and cannot be accessed by other modules. However, a module may be written to export or import functions and global (module scope) variables. Imported functions and global variable definitions are resolved at linkage time. A module is considered to be partially linked if it depends on imported values.