singe_cuda_sys/nvjitlink_sys_13040.rs
1/* automatically generated by rust-bindgen 0.72.1 */
2
3impl nvJitLinkResult {
4 /// The operation completed successfully.
5 pub const NVJITLINK_SUCCESS: nvJitLinkResult = nvJitLinkResult(0);
6 /// Unrecognized Option
7 pub const NVJITLINK_ERROR_UNRECOGNIZED_OPTION: nvJitLinkResult = nvJitLinkResult(1);
8 /// Option `-arch=sm_NN` not specified
9 pub const NVJITLINK_ERROR_MISSING_ARCH: nvJitLinkResult = nvJitLinkResult(2);
10 /// Invalid Input
11 pub const NVJITLINK_ERROR_INVALID_INPUT: nvJitLinkResult = nvJitLinkResult(3);
12 /// Issue during PTX Compilation
13 pub const NVJITLINK_ERROR_PTX_COMPILE: nvJitLinkResult = nvJitLinkResult(4);
14 /// Issue during NVVM Compilation
15 pub const NVJITLINK_ERROR_NVVM_COMPILE: nvJitLinkResult = nvJitLinkResult(5);
16 /// Internal Error
17 pub const NVJITLINK_ERROR_INTERNAL: nvJitLinkResult = nvJitLinkResult(6);
18 /// Issue with Thread Pool
19 pub const NVJITLINK_ERROR_THREADPOOL: nvJitLinkResult = nvJitLinkResult(7);
20 /// Unrecognized Input
21 pub const NVJITLINK_ERROR_UNRECOGNIZED_INPUT: nvJitLinkResult = nvJitLinkResult(8);
22 /// Finalizer Error
23 pub const NVJITLINK_ERROR_FINALIZE: nvJitLinkResult = nvJitLinkResult(9);
24 /// Null Input
25 pub const NVJITLINK_ERROR_NULL_INPUT: nvJitLinkResult = nvJitLinkResult(10);
26 /// Incompatible Options
27 pub const NVJITLINK_ERROR_INCOMPATIBLE_OPTIONS: nvJitLinkResult = nvJitLinkResult(
28 11,
29 );
30 /// Incorrect Input Type
31 pub const NVJITLINK_ERROR_INCORRECT_INPUT_TYPE: nvJitLinkResult = nvJitLinkResult(
32 12,
33 );
34 /// Arch Mismatch
35 pub const NVJITLINK_ERROR_ARCH_MISMATCH: nvJitLinkResult = nvJitLinkResult(13);
36 /// Outdated Library
37 pub const NVJITLINK_ERROR_OUTDATED_LIBRARY: nvJitLinkResult = nvJitLinkResult(14);
38 /// Missing Fatbin
39 pub const NVJITLINK_ERROR_MISSING_FATBIN: nvJitLinkResult = nvJitLinkResult(15);
40 /// Unrecognized -arch value
41 pub const NVJITLINK_ERROR_UNRECOGNIZED_ARCH: nvJitLinkResult = nvJitLinkResult(16);
42 /// Unsupported -arch value
43 pub const NVJITLINK_ERROR_UNSUPPORTED_ARCH: nvJitLinkResult = nvJitLinkResult(17);
44 /// Requires -lto
45 pub const NVJITLINK_ERROR_LTO_NOT_ENABLED: nvJitLinkResult = nvJitLinkResult(18);
46}
47/// The enumerated type nvJitLinkResult defines API call result codes. nvJitLink APIs return nvJitLinkResult codes to indicate the result.
48#[repr(transparent)]
49#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
50pub struct nvJitLinkResult(pub ::core::ffi::c_uint);
51impl nvJitLinkInputType {
52 /// Error Type
53 pub const NVJITLINK_INPUT_NONE: nvJitLinkInputType = nvJitLinkInputType(0);
54 /// For CUDA Binaries
55 pub const NVJITLINK_INPUT_CUBIN: nvJitLinkInputType = nvJitLinkInputType(1);
56 /// For PTX
57 pub const NVJITLINK_INPUT_PTX: nvJitLinkInputType = nvJitLinkInputType(2);
58 /// For LTO-IR
59 pub const NVJITLINK_INPUT_LTOIR: nvJitLinkInputType = nvJitLinkInputType(3);
60 /// For Fatbin
61 pub const NVJITLINK_INPUT_FATBIN: nvJitLinkInputType = nvJitLinkInputType(4);
62 /// For Host Object
63 pub const NVJITLINK_INPUT_OBJECT: nvJitLinkInputType = nvJitLinkInputType(5);
64 /// For Host Library
65 pub const NVJITLINK_INPUT_LIBRARY: nvJitLinkInputType = nvJitLinkInputType(6);
66 /// For Index File
67 pub const NVJITLINK_INPUT_INDEX: nvJitLinkInputType = nvJitLinkInputType(7);
68 /// Dynamically chooses from the valid types
69 pub const NVJITLINK_INPUT_ANY: nvJitLinkInputType = nvJitLinkInputType(10);
70}
71/// The enumerated type nvJitLinkInputType defines the kind of inputs that can be passed to nvJitLinkAdd* APIs.
72#[repr(transparent)]
73#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
74pub struct nvJitLinkInputType(pub ::core::ffi::c_uint);
75/// Incomplete native type used by [`nvJitLinkHandle`] handles. The native API owns its layout.
76#[repr(C)]
77#[derive(Debug, Copy, Clone)]
78pub struct nvJitLink {
79 _unused: [u8; 0],
80}
81/// nvJitLinkHandle is the unit of linking, and an opaque handle for a program.
82///
83/// To link inputs, an instance of nvJitLinkHandle must be created first with nvJitLinkCreate().
84pub type nvJitLinkHandle = *mut nvJitLink;
85singe_loader::functions! { crate::NVJITLINK;
86 /// nvJitLinkCreate creates an instance of nvJitLinkHandle with the given input options, and sets the output parameter `handle`.
87 ///
88 ///
89 ///
90 /// # Return value
91 ///
92 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
93 /// - [`nvJitLinkResult::NVJITLINK_ERROR_UNRECOGNIZED_OPTION`]
94 /// - [`nvJitLinkResult::NVJITLINK_ERROR_MISSING_ARCH`]
95 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
96 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
97 ///
98 /// It supports options listed in `options`.
99 ///
100 ///
101 ///
102 /// See also: nvJitLinkDestroy
103 ///
104 /// # Parameters
105 ///
106 /// - `handle`: Address of nvJitLink handle.
107 /// - `numOptions`: Number of options passed.
108 /// - `options`: Array of size `numOptions` of option strings.
109 pub fn __nvJitLinkCreate_13_4(
110 handle: *mut nvJitLinkHandle,
111 numOptions: u32,
112 options: *const *const ::core::ffi::c_char,
113 ) -> nvJitLinkResult;
114}
115singe_loader::functions! { crate::NVJITLINK;
116 /// nvJitLinkCreate creates an instance of nvJitLinkHandle with the given input options, and sets the output parameter `handle`.
117 ///
118 ///
119 ///
120 /// # Return value
121 ///
122 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
123 /// - [`nvJitLinkResult::NVJITLINK_ERROR_UNRECOGNIZED_OPTION`]
124 /// - [`nvJitLinkResult::NVJITLINK_ERROR_MISSING_ARCH`]
125 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
126 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
127 ///
128 /// It supports options listed in `options`.
129 ///
130 ///
131 ///
132 /// See also: nvJitLinkDestroy
133 ///
134 /// # Parameters
135 ///
136 /// - `handle`: Address of nvJitLink handle.
137 /// - `numOptions`: Number of options passed.
138 /// - `options`: Array of size `numOptions` of option strings.
139 pub fn nvJitLinkCreate(
140 handle: *mut nvJitLinkHandle,
141 numOptions: u32,
142 options: *mut *const ::core::ffi::c_char,
143 ) -> nvJitLinkResult;
144}
145singe_loader::functions! { crate::NVJITLINK;
146 /// nvJitLinkDestroy frees the memory associated with the given handle and sets it to NULL.
147 ///
148 ///
149 ///
150 /// # Return value
151 ///
152 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
153 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
154 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
155 ///
156 ///
157 ///
158 /// See also: nvJitLinkCreate
159 ///
160 /// # Parameters
161 ///
162 /// - `handle`: Address of nvJitLink handle.
163 pub fn __nvJitLinkDestroy_13_4(handle: *mut nvJitLinkHandle) -> nvJitLinkResult;
164}
165singe_loader::functions! { crate::NVJITLINK;
166 /// nvJitLinkDestroy frees the memory associated with the given handle and sets it to NULL.
167 ///
168 ///
169 ///
170 /// # Return value
171 ///
172 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
173 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
174 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
175 ///
176 ///
177 ///
178 /// See also: nvJitLinkCreate
179 ///
180 /// # Parameters
181 ///
182 /// - `handle`: Address of nvJitLink handle.
183 pub fn nvJitLinkDestroy(handle: *mut nvJitLinkHandle) -> nvJitLinkResult;
184}
185singe_loader::functions! { crate::NVJITLINK;
186 /// nvJitLinkAddData adds data image to the link.
187 ///
188 ///
189 ///
190 /// # Return value
191 ///
192 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
193 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
194 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
195 ///
196 /// # Parameters
197 ///
198 /// - `handle`: nvJitLink handle.
199 /// - `inputType`: kind of input.
200 /// - `data`: pointer to data image in memory.
201 /// - `size`: size of the data.
202 /// - `name`: name of input object.
203 pub fn __nvJitLinkAddData_13_4(
204 handle: nvJitLinkHandle,
205 inputType: nvJitLinkInputType,
206 data: *const ::core::ffi::c_void,
207 size: usize,
208 name: *const ::core::ffi::c_char,
209 ) -> nvJitLinkResult;
210}
211singe_loader::functions! { crate::NVJITLINK;
212 /// nvJitLinkAddData adds data image to the link.
213 ///
214 ///
215 ///
216 /// # Return value
217 ///
218 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
219 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
220 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
221 ///
222 /// # Parameters
223 ///
224 /// - `handle`: nvJitLink handle.
225 /// - `inputType`: kind of input.
226 /// - `data`: pointer to data image in memory.
227 /// - `size`: size of the data.
228 /// - `name`: name of input object.
229 pub fn nvJitLinkAddData(
230 handle: nvJitLinkHandle,
231 inputType: nvJitLinkInputType,
232 data: *const ::core::ffi::c_void,
233 size: usize,
234 name: *const ::core::ffi::c_char,
235 ) -> nvJitLinkResult;
236}
237singe_loader::functions! { crate::NVJITLINK;
238 /// nvJitLinkAddFile reads data from file and links it in.
239 ///
240 ///
241 ///
242 /// # Return value
243 ///
244 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
245 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
246 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
247 ///
248 /// # Parameters
249 ///
250 /// - `handle`: nvJitLink handle.
251 /// - `inputType`: kind of input.
252 /// - `fileName`: name of file.
253 pub fn __nvJitLinkAddFile_13_4(
254 handle: nvJitLinkHandle,
255 inputType: nvJitLinkInputType,
256 fileName: *const ::core::ffi::c_char,
257 ) -> nvJitLinkResult;
258}
259singe_loader::functions! { crate::NVJITLINK;
260 /// nvJitLinkAddFile reads data from file and links it in.
261 ///
262 ///
263 ///
264 /// # Return value
265 ///
266 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
267 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
268 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
269 ///
270 /// # Parameters
271 ///
272 /// - `handle`: nvJitLink handle.
273 /// - `inputType`: kind of input.
274 /// - `fileName`: name of file.
275 pub fn nvJitLinkAddFile(
276 handle: nvJitLinkHandle,
277 inputType: nvJitLinkInputType,
278 fileName: *const ::core::ffi::c_char,
279 ) -> nvJitLinkResult;
280}
281singe_loader::functions! { crate::NVJITLINK;
282 /// nvJitLinkComplete does the actual link.
283 ///
284 ///
285 ///
286 /// # Return value
287 ///
288 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
289 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
290 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
291 ///
292 /// # Parameters
293 ///
294 /// - `handle`: nvJitLink handle.
295 pub fn __nvJitLinkComplete_13_4(handle: nvJitLinkHandle) -> nvJitLinkResult;
296}
297singe_loader::functions! { crate::NVJITLINK;
298 /// nvJitLinkComplete does the actual link.
299 ///
300 ///
301 ///
302 /// # Return value
303 ///
304 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
305 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
306 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
307 ///
308 /// # Parameters
309 ///
310 /// - `handle`: nvJitLink handle.
311 pub fn nvJitLinkComplete(handle: nvJitLinkHandle) -> nvJitLinkResult;
312}
313singe_loader::functions! { crate::NVJITLINK;
314 /// nvJitLinkGetLinkedCubinSize gets the size of the linked cubin.
315 ///
316 ///
317 ///
318 /// # Return value
319 ///
320 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
321 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
322 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
323 ///
324 ///
325 ///
326 /// See also: nvJitLinkGetLinkedCubin
327 ///
328 /// # Parameters
329 ///
330 /// - `handle`: nvJitLink handle.
331 /// - `size`: Size of the linked cubin.
332 pub fn __nvJitLinkGetLinkedCubinSize_13_4(
333 handle: nvJitLinkHandle,
334 size: *mut usize,
335 ) -> nvJitLinkResult;
336}
337singe_loader::functions! { crate::NVJITLINK;
338 /// nvJitLinkGetLinkedCubinSize gets the size of the linked cubin.
339 ///
340 ///
341 ///
342 /// # Return value
343 ///
344 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
345 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
346 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
347 ///
348 ///
349 ///
350 /// See also: nvJitLinkGetLinkedCubin
351 ///
352 /// # Parameters
353 ///
354 /// - `handle`: nvJitLink handle.
355 /// - `size`: Size of the linked cubin.
356 pub fn nvJitLinkGetLinkedCubinSize(
357 handle: nvJitLinkHandle,
358 size: *mut usize,
359 ) -> nvJitLinkResult;
360}
361singe_loader::functions! { crate::NVJITLINK;
362 /// nvJitLinkGetLinkedCubin gets the linked cubin.
363 ///
364 ///
365 ///
366 /// # Return value
367 ///
368 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
369 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
370 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
371 ///
372 /// User is responsible for allocating enough space to hold the `cubin`.
373 ///
374 /// See also: nvJitLinkGetLinkedCubinSize
375 ///
376 /// # Parameters
377 ///
378 /// - `handle`: nvJitLink handle.
379 /// - `cubin`: The linked cubin.
380 pub fn __nvJitLinkGetLinkedCubin_13_4(
381 handle: nvJitLinkHandle,
382 cubin: *mut ::core::ffi::c_void,
383 ) -> nvJitLinkResult;
384}
385singe_loader::functions! { crate::NVJITLINK;
386 /// nvJitLinkGetLinkedCubin gets the linked cubin.
387 ///
388 ///
389 ///
390 /// # Return value
391 ///
392 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
393 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
394 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
395 ///
396 /// User is responsible for allocating enough space to hold the `cubin`.
397 ///
398 /// See also: nvJitLinkGetLinkedCubinSize
399 ///
400 /// # Parameters
401 ///
402 /// - `handle`: nvJitLink handle.
403 /// - `cubin`: The linked cubin.
404 pub fn nvJitLinkGetLinkedCubin(
405 handle: nvJitLinkHandle,
406 cubin: *mut ::core::ffi::c_void,
407 ) -> nvJitLinkResult;
408}
409singe_loader::functions! { crate::NVJITLINK;
410 /// nvJitLinkGetLinkedPtxSize gets the size of the linked ptx.
411 ///
412 ///
413 ///
414 /// # Return value
415 ///
416 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
417 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
418 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
419 ///
420 /// Linked PTX is only available when using the `-lto` option.
421 ///
422 /// See also: nvJitLinkGetLinkedPtx
423 ///
424 /// # Parameters
425 ///
426 /// - `handle`: nvJitLink handle.
427 /// - `size`: Size of the linked PTX.
428 pub fn __nvJitLinkGetLinkedPtxSize_13_4(
429 handle: nvJitLinkHandle,
430 size: *mut usize,
431 ) -> nvJitLinkResult;
432}
433singe_loader::functions! { crate::NVJITLINK;
434 /// nvJitLinkGetLinkedPtxSize gets the size of the linked ptx.
435 ///
436 ///
437 ///
438 /// # Return value
439 ///
440 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
441 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
442 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
443 ///
444 /// Linked PTX is only available when using the `-lto` option.
445 ///
446 /// See also: nvJitLinkGetLinkedPtx
447 ///
448 /// # Parameters
449 ///
450 /// - `handle`: nvJitLink handle.
451 /// - `size`: Size of the linked PTX.
452 pub fn nvJitLinkGetLinkedPtxSize(
453 handle: nvJitLinkHandle,
454 size: *mut usize,
455 ) -> nvJitLinkResult;
456}
457singe_loader::functions! { crate::NVJITLINK;
458 /// nvJitLinkGetLinkedPtx gets the linked ptx.
459 ///
460 ///
461 ///
462 /// # Return value
463 ///
464 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
465 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
466 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
467 ///
468 /// Linked PTX is only available when using the `-lto` option. User is responsible for allocating enough space to hold the `ptx`.
469 ///
470 /// See also: nvJitLinkGetLinkedPtxSize
471 ///
472 /// # Parameters
473 ///
474 /// - `handle`: nvJitLink handle.
475 /// - `ptx`: The linked PTX.
476 pub fn __nvJitLinkGetLinkedPtx_13_4(
477 handle: nvJitLinkHandle,
478 ptx: *mut ::core::ffi::c_char,
479 ) -> nvJitLinkResult;
480}
481singe_loader::functions! { crate::NVJITLINK;
482 /// nvJitLinkGetLinkedPtx gets the linked ptx.
483 ///
484 ///
485 ///
486 /// # Return value
487 ///
488 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
489 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
490 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
491 ///
492 /// Linked PTX is only available when using the `-lto` option. User is responsible for allocating enough space to hold the `ptx`.
493 ///
494 /// See also: nvJitLinkGetLinkedPtxSize
495 ///
496 /// # Parameters
497 ///
498 /// - `handle`: nvJitLink handle.
499 /// - `ptx`: The linked PTX.
500 pub fn nvJitLinkGetLinkedPtx(
501 handle: nvJitLinkHandle,
502 ptx: *mut ::core::ffi::c_char,
503 ) -> nvJitLinkResult;
504}
505singe_loader::functions! { crate::NVJITLINK;
506 /// nvJitLinkGetLinkedLTOIRSize gets the size of the linked LTOIR.
507 ///
508 ///
509 ///
510 /// # Return value
511 ///
512 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
513 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
514 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
515 ///
516 /// Linked LTOIR is only available when using the `-lto` option. The returned data is in LTOIR Container format (not raw bitcode).
517 ///
518 /// See also: nvJitLinkGetLinkedLTOIR
519 ///
520 /// # Parameters
521 ///
522 /// - `handle`: nvJitLink handle.
523 /// - `size`: Size of the linked LTOIR.
524 pub fn __nvJitLinkGetLinkedLTOIRSize_13_4(
525 handle: nvJitLinkHandle,
526 size: *mut usize,
527 ) -> nvJitLinkResult;
528}
529singe_loader::functions! { crate::NVJITLINK;
530 /// nvJitLinkGetLinkedLTOIRSize gets the size of the linked LTOIR.
531 ///
532 ///
533 ///
534 /// # Return value
535 ///
536 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
537 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
538 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
539 ///
540 /// Linked LTOIR is only available when using the `-lto` option. The returned data is in LTOIR Container format (not raw bitcode).
541 ///
542 /// See also: nvJitLinkGetLinkedLTOIR
543 ///
544 /// # Parameters
545 ///
546 /// - `handle`: nvJitLink handle.
547 /// - `size`: Size of the linked LTOIR.
548 pub fn nvJitLinkGetLinkedLTOIRSize(
549 handle: nvJitLinkHandle,
550 size: *mut usize,
551 ) -> nvJitLinkResult;
552}
553singe_loader::functions! { crate::NVJITLINK;
554 /// nvJitLinkGetLinkedLTOIR gets the linked LTOIR.
555 ///
556 ///
557 ///
558 /// # Return value
559 ///
560 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
561 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
562 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
563 ///
564 /// Linked LTOIR is only available when using the `-lto` option. User is responsible for allocating enough space to hold the `ltoir`. The returned data is in LTOIR Container format (not raw bitcode).
565 ///
566 /// See also: nvJitLinkGetLinkedLTOIRSize
567 ///
568 /// # Parameters
569 ///
570 /// - `handle`: nvJitLink handle.
571 /// - `ltoir`: The linked LTOIR in Container format.
572 pub fn __nvJitLinkGetLinkedLTOIR_13_4(
573 handle: nvJitLinkHandle,
574 ltoir: *mut ::core::ffi::c_void,
575 ) -> nvJitLinkResult;
576}
577singe_loader::functions! { crate::NVJITLINK;
578 /// nvJitLinkGetLinkedLTOIR gets the linked LTOIR.
579 ///
580 ///
581 ///
582 /// # Return value
583 ///
584 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
585 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
586 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
587 ///
588 /// Linked LTOIR is only available when using the `-lto` option. User is responsible for allocating enough space to hold the `ltoir`. The returned data is in LTOIR Container format (not raw bitcode).
589 ///
590 /// See also: nvJitLinkGetLinkedLTOIRSize
591 ///
592 /// # Parameters
593 ///
594 /// - `handle`: nvJitLink handle.
595 /// - `ltoir`: The linked LTOIR in Container format.
596 pub fn nvJitLinkGetLinkedLTOIR(
597 handle: nvJitLinkHandle,
598 ltoir: *mut ::core::ffi::c_void,
599 ) -> nvJitLinkResult;
600}
601singe_loader::functions! { crate::NVJITLINK;
602 /// nvJitLinkGetErrorLogSize gets the size of the error log.
603 ///
604 ///
605 ///
606 /// # Return value
607 ///
608 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
609 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
610 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
611 ///
612 ///
613 ///
614 /// See also: nvJitLinkGetErrorLog
615 ///
616 /// # Parameters
617 ///
618 /// - `handle`: nvJitLink handle.
619 /// - `size`: Size of the error log.
620 pub fn __nvJitLinkGetErrorLogSize_13_4(
621 handle: nvJitLinkHandle,
622 size: *mut usize,
623 ) -> nvJitLinkResult;
624}
625singe_loader::functions! { crate::NVJITLINK;
626 /// nvJitLinkGetErrorLogSize gets the size of the error log.
627 ///
628 ///
629 ///
630 /// # Return value
631 ///
632 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
633 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
634 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
635 ///
636 ///
637 ///
638 /// See also: nvJitLinkGetErrorLog
639 ///
640 /// # Parameters
641 ///
642 /// - `handle`: nvJitLink handle.
643 /// - `size`: Size of the error log.
644 pub fn nvJitLinkGetErrorLogSize(
645 handle: nvJitLinkHandle,
646 size: *mut usize,
647 ) -> nvJitLinkResult;
648}
649singe_loader::functions! { crate::NVJITLINK;
650 /// nvJitLinkGetErrorLog puts any error messages in the log.
651 ///
652 ///
653 ///
654 /// # Return value
655 ///
656 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
657 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
658 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
659 ///
660 /// User is responsible for allocating enough space to hold the `log`.
661 ///
662 /// See also: nvJitLinkGetErrorLogSize
663 ///
664 /// # Parameters
665 ///
666 /// - `handle`: nvJitLink handle.
667 /// - `log`: The error log.
668 pub fn __nvJitLinkGetErrorLog_13_4(
669 handle: nvJitLinkHandle,
670 log: *mut ::core::ffi::c_char,
671 ) -> nvJitLinkResult;
672}
673singe_loader::functions! { crate::NVJITLINK;
674 /// nvJitLinkGetErrorLog puts any error messages in the log.
675 ///
676 ///
677 ///
678 /// # Return value
679 ///
680 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
681 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
682 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
683 ///
684 /// User is responsible for allocating enough space to hold the `log`.
685 ///
686 /// See also: nvJitLinkGetErrorLogSize
687 ///
688 /// # Parameters
689 ///
690 /// - `handle`: nvJitLink handle.
691 /// - `log`: The error log.
692 pub fn nvJitLinkGetErrorLog(
693 handle: nvJitLinkHandle,
694 log: *mut ::core::ffi::c_char,
695 ) -> nvJitLinkResult;
696}
697singe_loader::functions! { crate::NVJITLINK;
698 /// nvJitLinkGetInfoLogSize gets the size of the info log.
699 ///
700 ///
701 ///
702 /// # Return value
703 ///
704 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
705 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
706 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
707 ///
708 ///
709 ///
710 /// See also: nvJitLinkGetInfoLog
711 ///
712 /// # Parameters
713 ///
714 /// - `handle`: nvJitLink handle.
715 /// - `size`: Size of the info log.
716 pub fn __nvJitLinkGetInfoLogSize_13_4(
717 handle: nvJitLinkHandle,
718 size: *mut usize,
719 ) -> nvJitLinkResult;
720}
721singe_loader::functions! { crate::NVJITLINK;
722 /// nvJitLinkGetInfoLogSize gets the size of the info log.
723 ///
724 ///
725 ///
726 /// # Return value
727 ///
728 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
729 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
730 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
731 ///
732 ///
733 ///
734 /// See also: nvJitLinkGetInfoLog
735 ///
736 /// # Parameters
737 ///
738 /// - `handle`: nvJitLink handle.
739 /// - `size`: Size of the info log.
740 pub fn nvJitLinkGetInfoLogSize(
741 handle: nvJitLinkHandle,
742 size: *mut usize,
743 ) -> nvJitLinkResult;
744}
745singe_loader::functions! { crate::NVJITLINK;
746 /// nvJitLinkGetInfoLog puts any info messages in the log.
747 ///
748 ///
749 ///
750 /// # Return value
751 ///
752 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
753 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
754 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
755 ///
756 /// User is responsible for allocating enough space to hold the `log`.
757 ///
758 /// See also: nvJitLinkGetInfoLogSize
759 ///
760 /// # Parameters
761 ///
762 /// - `handle`: nvJitLink handle.
763 /// - `log`: The info log.
764 pub fn __nvJitLinkGetInfoLog_13_4(
765 handle: nvJitLinkHandle,
766 log: *mut ::core::ffi::c_char,
767 ) -> nvJitLinkResult;
768}
769singe_loader::functions! { crate::NVJITLINK;
770 /// nvJitLinkGetInfoLog puts any info messages in the log.
771 ///
772 ///
773 ///
774 /// # Return value
775 ///
776 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
777 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
778 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
779 ///
780 /// User is responsible for allocating enough space to hold the `log`.
781 ///
782 /// See also: nvJitLinkGetInfoLogSize
783 ///
784 /// # Parameters
785 ///
786 /// - `handle`: nvJitLink handle.
787 /// - `log`: The info log.
788 pub fn nvJitLinkGetInfoLog(
789 handle: nvJitLinkHandle,
790 log: *mut ::core::ffi::c_char,
791 ) -> nvJitLinkResult;
792}
793singe_loader::functions! { crate::NVJITLINK;
794 /// nvJitLinkVersion returns the current version of nvJitLink.
795 ///
796 ///
797 ///
798 /// # Return value
799 ///
800 /// - [`nvJitLinkResult::NVJITLINK_SUCCESS`]
801 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INVALID_INPUT`]
802 /// - [`nvJitLinkResult::NVJITLINK_ERROR_INTERNAL`]
803 ///
804 /// # Parameters
805 ///
806 /// - `major`: The major version.
807 /// - `minor`: The minor version.
808 pub fn nvJitLinkVersion(
809 major: *mut ::core::ffi::c_uint,
810 minor: *mut ::core::ffi::c_uint,
811 ) -> nvJitLinkResult;
812}