Function nvvm::sys::nvvmAddModuleToProgram[][src]

pub unsafe extern "C" fn nvvmAddModuleToProgram(
    prog: nvvmProgram,
    buffer: *const c_char,
    size: size_t,
    name: *const c_char
) -> nvvmResult
Expand description

\ingroup compilation \brief Add a module level NVVM IR to a program.

The buffer should contain an NVVM IR module. The module should have NVVM IR version 1.6 either in the LLVM 7.0.1 bitcode representation or in the LLVM 7.0.1 text representation. Support for reading the text representation of NVVM IR is deprecated and may be removed in a later version.

\param [in] prog NVVM program. \param [in] buffer NVVM IR module in the bitcode or text representation. \param [in] size Size of the NVVM IR module. \param [in] name Name of the NVVM IR module. If NULL, “” is used as the name. \return

  • \link ::nvvmResult NVVM_SUCCESS \endlink
  • \link ::nvvmResult NVVM_ERROR_OUT_OF_MEMORY \endlink
  • \link ::nvvmResult NVVM_ERROR_INVALID_INPUT \endlink
  • \link ::nvvmResult NVVM_ERROR_INVALID_PROGRAM \endlink