#![cfg_attr(xlsynth_runtime_runpath, feature(link_arg_attribute))]
#[cfg(xlsynth_runtime_runpath)]
include!(concat!(env!("OUT_DIR"), "/xlsynth_runtime_link_arg.rs"));
extern crate libc;
#[repr(C)]
pub struct CIrValue {
_private: [u8; 0], }
#[repr(C)]
pub struct CIrBits {
_private: [u8; 0], }
#[repr(C)]
pub struct CBitsRope {
_private: [u8; 0], }
#[repr(C)]
pub struct CIrPackage {
_private: [u8; 0], }
#[repr(C)]
pub struct CIrFunction {
_private: [u8; 0], }
#[repr(C)]
pub struct CIrFunctionBase {
_private: [u8; 0], }
#[repr(C)]
pub struct CIrFunctionJit {
_private: [u8; 0], }
#[repr(C)]
pub struct CXlsAotExecContext {
_private: [u8; 0], }
#[repr(C)]
pub struct CTraceMessage {
pub message: *mut std::os::raw::c_char,
pub verbosity: i64,
}
#[repr(C)]
pub struct CIrType {
_private: [u8; 0], }
#[repr(C)]
pub struct CIrFunctionType {
_private: [u8; 0], }
#[repr(C)]
pub struct CIrAnalysis {
_private: [u8; 0], }
#[repr(C)]
pub struct CIrIntervalSet {
_private: [u8; 0], }
pub type XlsIrAnalysisLevel = i32;
pub const XLS_IR_ANALYSIS_LEVEL_FAST: XlsIrAnalysisLevel = 0;
pub const XLS_IR_ANALYSIS_LEVEL_RANGE_WITH_CONTEXT: XlsIrAnalysisLevel = 1;
#[repr(C)]
pub struct XlsIrAnalysisOptions {
pub level: XlsIrAnalysisLevel,
}
#[repr(C)]
pub struct CDslxImportData {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxTypecheckedModule {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxModule {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxTypeInfo {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxStructDef {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxEnumDef {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxSumDef {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxTypeAlias {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxType {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxTypeDim {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxExpr {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxInterpValue {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxParametricEnv {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxEnumMember {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxStructMember {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxTypeAnnotation {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxArrayTypeAnnotation {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxTypeRefTypeAnnotation {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxTypeRef {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxImport {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxColonRef {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxTypeDefinition {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxConstantDef {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxModuleMember {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxFunction {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxParam {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxAttribute {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxParametricBinding {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxCallGraph {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxQuickcheck {
_private: [u8; 0], }
#[repr(C)]
pub struct CDslxInvocationCalleeDataArray {
_private: [u8; 0],
}
#[repr(C)]
pub struct CDslxInvocationCalleeData {
_private: [u8; 0],
}
#[repr(C)]
pub struct CDslxInvocationData {
_private: [u8; 0],
}
#[repr(C)]
pub struct CDslxInvocation {
_private: [u8; 0],
}
#[repr(C)]
pub struct CScheduleAndCodegenResult {
_private: [u8; 0], }
pub type XlsFormatPreference = i32;
pub type XlsValueKind = i32;
pub type XlsCallingConvention = i32;
pub type DslxTypeDefinitionKind = i32;
pub type DslxModuleMemberKind = i32;
pub type DslxAttributeKind = i32;
pub const XLS_DSLX_ATTRIBUTE_KIND_CFG: DslxAttributeKind = 0;
pub const XLS_DSLX_ATTRIBUTE_KIND_DSLX_FORMAT_DISABLE: DslxAttributeKind = 1;
pub const XLS_DSLX_ATTRIBUTE_KIND_EXTERN_VERILOG: DslxAttributeKind = 2;
pub const XLS_DSLX_ATTRIBUTE_KIND_SV_TYPE: DslxAttributeKind = 3;
pub const XLS_DSLX_ATTRIBUTE_KIND_TEST: DslxAttributeKind = 4;
pub const XLS_DSLX_ATTRIBUTE_KIND_TEST_PROC: DslxAttributeKind = 5;
pub const XLS_DSLX_ATTRIBUTE_KIND_QUICKCHECK: DslxAttributeKind = 6;
pub type DslxAttributeArgumentKind = i32;
pub const XLS_DSLX_ATTRIBUTE_ARGUMENT_KIND_STRING: DslxAttributeArgumentKind = 0;
pub const XLS_DSLX_ATTRIBUTE_ARGUMENT_KIND_STRING_KEY_VALUE: DslxAttributeArgumentKind = 1;
pub const XLS_DSLX_ATTRIBUTE_ARGUMENT_KIND_INT_KEY_VALUE: DslxAttributeArgumentKind = 2;
pub const XLS_DSLX_ATTRIBUTE_ARGUMENT_KIND_STRING_LITERAL: DslxAttributeArgumentKind = 3;
pub const XLS_CALLING_CONVENTION_TYPICAL: XlsCallingConvention = 0;
pub const XLS_CALLING_CONVENTION_IMPLICIT_TOKEN: XlsCallingConvention = 1;
pub const XLS_CALLING_CONVENTION_PROC_NEXT: XlsCallingConvention = 2;
#[repr(C)]
pub struct XlsDslxParametricEnvItem {
pub identifier: *const std::os::raw::c_char,
pub value: *const CDslxInterpValue,
}
#[repr(C)]
pub struct XlsDslxFunctionSpecializationRequest {
pub function_name: *const std::os::raw::c_char,
pub specialized_name: *const std::os::raw::c_char,
pub env: *mut CDslxParametricEnv,
}
#[repr(C)]
pub struct CDslxInvocationRewriteRule {
pub from_callee: *mut CDslxFunction,
pub to_callee: *mut CDslxFunction,
pub match_callee_env: *const CDslxParametricEnv,
pub to_callee_env: *const CDslxParametricEnv,
}
unsafe extern "C" {
pub fn xls_convert_dslx_to_ir(
dslx: *const std::os::raw::c_char,
path: *const std::os::raw::c_char,
module_name: *const std::os::raw::c_char,
dslx_stdlib_path: *const std::os::raw::c_char,
additional_search_paths: *const *const std::os::raw::c_char,
additional_search_paths_count: libc::size_t,
error_out: *mut *mut std::os::raw::c_char,
ir_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_convert_dslx_to_ir_with_warnings(
dslx: *const std::os::raw::c_char,
path: *const std::os::raw::c_char,
module_name: *const std::os::raw::c_char,
dslx_stdlib_path: *const std::os::raw::c_char,
additional_search_paths: *const *const std::os::raw::c_char,
additional_search_paths_count: libc::size_t,
enable_warnings: *const *const std::os::raw::c_char,
enable_warnings_count: libc::size_t,
disable_warnings: *const *const std::os::raw::c_char,
disable_warnings_count: libc::size_t,
warnings_as_errors: bool,
force_implicit_token_calling_convention: bool,
warnings_out: *mut *mut *mut std::os::raw::c_char,
warnings_out_count: *mut libc::size_t,
error_out: *mut *mut std::os::raw::c_char,
ir_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_convert_dslx_path_to_ir(
path: *const std::os::raw::c_char,
dslx_stdlib_path: *const std::os::raw::c_char,
additional_search_paths: *const *const std::os::raw::c_char,
additional_search_paths_count: libc::size_t,
error_out: *mut *mut std::os::raw::c_char,
ir_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_convert_dslx_path_to_ir_with_warnings(
path: *const std::os::raw::c_char,
dslx_stdlib_path: *const std::os::raw::c_char,
additional_search_paths: *const *const std::os::raw::c_char,
additional_search_paths_count: libc::size_t,
enable_warnings: *const *const std::os::raw::c_char,
enable_warnings_count: libc::size_t,
disable_warnings: *const *const std::os::raw::c_char,
disable_warnings_count: libc::size_t,
warnings_as_errors: bool,
force_implicit_token_calling_convention: bool,
warnings_out: *mut *mut *mut std::os::raw::c_char,
warnings_out_count: *mut libc::size_t,
error_out: *mut *mut std::os::raw::c_char,
ir_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_parse_typed_value(
text: *const std::os::raw::c_char,
error_out: *mut *mut std::os::raw::c_char,
value_out: *mut *mut CIrValue,
) -> bool;
pub fn xls_value_free(value: *mut CIrValue);
pub fn xls_value_clone(value: *const CIrValue) -> *mut CIrValue;
pub fn xls_value_get_bits(
value: *const CIrValue,
error_out: *mut *mut std::os::raw::c_char,
bits_out: *mut *mut CIrBits,
) -> bool;
pub fn xls_value_make_tuple(
value_count: libc::size_t,
values: *const *const CIrValue,
) -> *mut CIrValue;
pub fn xls_value_make_token() -> *mut CIrValue;
pub fn xls_value_make_array(
element_count: libc::size_t,
elements: *const *const CIrValue,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CIrValue,
) -> bool;
pub fn xls_value_get_element(
tuple: *const CIrValue,
index: libc::size_t,
error_out: *mut *mut std::os::raw::c_char,
element_out: *mut *mut CIrValue,
) -> bool;
pub fn xls_value_get_element_count(
value: *const CIrValue,
error_out: *mut *mut std::os::raw::c_char,
count_out: *mut i64,
) -> bool;
pub fn xls_value_make_ubits(
bit_count: i64,
value: u64,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CIrValue,
) -> bool;
pub fn xls_value_make_sbits(
bit_count: i64,
value: i64,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CIrValue,
) -> bool;
pub fn xls_value_from_bits(bits: *const CIrBits) -> *mut CIrValue;
pub fn xls_bits_make_ubits(
bit_count: i64,
value: u64,
error_out: *mut *mut std::os::raw::c_char,
bits_out: *mut *mut CIrBits,
) -> bool;
pub fn xls_bits_make_sbits(
bit_count: i64,
value: i64,
error_out: *mut *mut std::os::raw::c_char,
bits_out: *mut *mut CIrBits,
) -> bool;
pub fn xls_bits_free(bits: *mut CIrBits);
pub fn xls_bits_get_bit_count(bits: *const CIrBits) -> i64;
pub fn xls_bits_get_bit(bits: *const CIrBits, index: i64) -> bool;
pub fn xls_bits_eq(bits: *const CIrBits, other: *const CIrBits) -> bool;
pub fn xls_bits_ne(a: *const CIrBits, b: *const CIrBits) -> bool;
pub fn xls_bits_ult(a: *const CIrBits, b: *const CIrBits) -> bool;
pub fn xls_bits_ule(a: *const CIrBits, b: *const CIrBits) -> bool;
pub fn xls_bits_ugt(a: *const CIrBits, b: *const CIrBits) -> bool;
pub fn xls_bits_uge(a: *const CIrBits, b: *const CIrBits) -> bool;
pub fn xls_bits_slt(a: *const CIrBits, b: *const CIrBits) -> bool;
pub fn xls_bits_sle(a: *const CIrBits, b: *const CIrBits) -> bool;
pub fn xls_bits_sgt(a: *const CIrBits, b: *const CIrBits) -> bool;
pub fn xls_bits_sge(a: *const CIrBits, b: *const CIrBits) -> bool;
pub fn xls_bits_to_debug_string(bits: *const CIrBits) -> *mut std::os::raw::c_char;
pub fn xls_bits_make_bits_from_bytes(
bit_count: libc::size_t,
bytes: *const u8,
byte_count: libc::size_t,
error_out: *mut *mut std::os::raw::c_char,
bits_out: *mut *mut CIrBits,
) -> bool;
pub fn xls_mangle_dslx_name_full(
module_name: *const std::os::raw::c_char,
function_name: *const std::os::raw::c_char,
convention: XlsCallingConvention,
free_keys: *const *const std::os::raw::c_char,
free_keys_count: libc::size_t,
param_env: *const CDslxParametricEnv,
scope: *const std::os::raw::c_char,
error_out: *mut *mut std::os::raw::c_char,
mangled_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_bits_add(lhs: *const CIrBits, rhs: *const CIrBits) -> *mut CIrBits;
pub fn xls_bits_sub(lhs: *const CIrBits, rhs: *const CIrBits) -> *mut CIrBits;
pub fn xls_bits_umul(lhs: *const CIrBits, rhs: *const CIrBits) -> *mut CIrBits;
pub fn xls_bits_smul(lhs: *const CIrBits, rhs: *const CIrBits) -> *mut CIrBits;
pub fn xls_bits_udiv(lhs: *const CIrBits, rhs: *const CIrBits) -> *mut CIrBits;
pub fn xls_bits_sdiv(lhs: *const CIrBits, rhs: *const CIrBits) -> *mut CIrBits;
pub fn xls_bits_umod(lhs: *const CIrBits, rhs: *const CIrBits) -> *mut CIrBits;
pub fn xls_bits_smod(lhs: *const CIrBits, rhs: *const CIrBits) -> *mut CIrBits;
pub fn xls_bits_negate(bits: *const CIrBits) -> *mut CIrBits;
pub fn xls_bits_abs(bits: *const CIrBits) -> *mut CIrBits;
pub fn xls_bits_not(bits: *const CIrBits) -> *mut CIrBits;
pub fn xls_bits_and(lhs: *const CIrBits, rhs: *const CIrBits) -> *mut CIrBits;
pub fn xls_bits_or(lhs: *const CIrBits, rhs: *const CIrBits) -> *mut CIrBits;
pub fn xls_bits_xor(lhs: *const CIrBits, rhs: *const CIrBits) -> *mut CIrBits;
pub fn xls_bits_shift_left_logical(bits: *const CIrBits, shift_amount: i64) -> *mut CIrBits;
pub fn xls_bits_shift_right_logical(bits: *const CIrBits, shift_amount: i64) -> *mut CIrBits;
pub fn xls_bits_shift_right_arithmetic(bits: *const CIrBits, shift_amount: i64)
-> *mut CIrBits;
pub fn xls_bits_width_slice(bits: *const CIrBits, start: i64, width: i64) -> *mut CIrBits;
pub fn xls_bits_to_bytes(
bits: *const CIrBits,
error_out: *mut *mut std::os::raw::c_char,
bytes_out: *mut *mut u8,
byte_count_out: *mut libc::size_t,
) -> bool;
pub fn xls_bytes_free(bytes: *mut u8);
pub fn xls_bits_to_uint64(
bits: *const CIrBits,
error_out: *mut *mut std::os::raw::c_char,
value_out: *mut u64,
) -> bool;
pub fn xls_bits_to_int64(
bits: *const CIrBits,
error_out: *mut *mut std::os::raw::c_char,
value_out: *mut i64,
) -> bool;
pub fn xls_create_bits_rope(bit_count: i64) -> *mut CBitsRope;
pub fn xls_bits_rope_append_bits(bits_rope: *mut CBitsRope, bits: *const CIrBits);
pub fn xls_bits_rope_get_bits(bits_rope: *mut CBitsRope) -> *mut CIrBits;
pub fn xls_bits_rope_free(bits_rope: *mut CBitsRope);
pub fn xls_package_free(package: *mut CIrPackage);
pub fn xls_c_str_free(c_str: *mut std::os::raw::c_char);
pub fn xls_c_strs_free(c_strs: *mut *mut std::os::raw::c_char, count: libc::size_t);
pub fn xls_value_to_string(
value: *const CIrValue,
str_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_format_preference_from_string(
s: *const std::os::raw::c_char,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut XlsFormatPreference,
) -> bool;
pub fn xls_value_to_string_format_preference(
value: *const CIrValue,
fmt: XlsFormatPreference,
error_out: *mut *mut std::os::raw::c_char,
str_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_bits_to_string(
bits: *const CIrBits,
fmt: XlsFormatPreference,
include_bit_count: bool,
error_out: *mut *mut std::os::raw::c_char,
str_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_value_get_kind(
value: *const CIrValue,
error_out: *mut *mut std::os::raw::c_char,
kind_out: *mut XlsValueKind,
) -> bool;
pub fn xls_value_make_true() -> *mut CIrValue;
pub fn xls_value_make_false() -> *mut CIrValue;
pub fn xls_value_from_bits_owned(bits: *mut CIrBits) -> *mut CIrValue;
pub fn xls_value_flatten_to_bits(value: *const CIrValue) -> *mut CIrBits;
pub fn xls_value_eq(value: *const CIrValue, value: *const CIrValue) -> bool;
pub fn xls_parse_ir_package(
ir: *const std::os::raw::c_char,
filename: *const std::os::raw::c_char,
error_out: *mut *mut std::os::raw::c_char,
xls_package_out: *mut *mut CIrPackage,
) -> bool;
pub fn xls_ir_analysis_create_from_package(
p: *mut CIrPackage,
error_out: *mut *mut std::os::raw::c_char,
out: *mut *mut CIrAnalysis,
) -> bool;
pub fn xls_ir_analysis_create_from_package_with_options(
p: *mut CIrPackage,
options: *const XlsIrAnalysisOptions,
error_out: *mut *mut std::os::raw::c_char,
out: *mut *mut CIrAnalysis,
) -> bool;
pub fn xls_ir_analysis_free(a: *mut CIrAnalysis);
pub fn xls_ir_analysis_get_known_bits_for_node_id(
a: *const CIrAnalysis,
node_id: i64,
error_out: *mut *mut std::os::raw::c_char,
known_mask_out: *mut *mut CIrBits,
known_value_out: *mut *mut CIrBits,
) -> bool;
pub fn xls_ir_analysis_get_intervals_for_node_id(
a: *const CIrAnalysis,
node_id: i64,
error_out: *mut *mut std::os::raw::c_char,
intervals_out: *mut *mut CIrIntervalSet,
) -> bool;
pub fn xls_ir_analysis_at_most_one_bit_true(
a: *const CIrAnalysis,
node_id: i64,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut bool,
) -> bool;
pub fn xls_ir_analysis_at_least_one_bit_true(
a: *const CIrAnalysis,
node_id: i64,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut bool,
) -> bool;
pub fn xls_ir_analysis_exactly_one_bit_true(
a: *const CIrAnalysis,
node_id: i64,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut bool,
) -> bool;
pub fn xls_ir_analysis_known_not_equals(
a: *const CIrAnalysis,
lhs_node_id: i64,
lhs_bit_index: i64,
rhs_node_id: i64,
rhs_bit_index: i64,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut bool,
) -> bool;
pub fn xls_ir_analysis_implies(
a: *const CIrAnalysis,
lhs_node_id: i64,
lhs_bit_index: i64,
rhs_node_id: i64,
rhs_bit_index: i64,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut bool,
) -> bool;
pub fn xls_interval_set_get_interval_count(s: *const CIrIntervalSet) -> i64;
pub fn xls_interval_set_get_interval_bounds(
s: *const CIrIntervalSet,
i: i64,
error_out: *mut *mut std::os::raw::c_char,
lo_out: *mut *mut CIrBits,
hi_out: *mut *mut CIrBits,
) -> bool;
pub fn xls_interval_set_free(s: *mut CIrIntervalSet);
pub fn xls_type_to_string(
t: *const CIrType,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_type_get_kind(
t: *mut CIrType,
error_out: *mut *mut std::os::raw::c_char,
kind_out: *mut XlsValueKind,
) -> bool;
pub fn xls_type_get_flat_bit_count(t: *const CIrType) -> i64;
pub fn xls_type_get_leaf_count(t: *mut CIrType) -> i64;
pub fn xls_package_get_type_for_value(
package: *const CIrPackage,
value: *const CIrValue,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CIrType,
) -> bool;
pub fn xls_package_get_function(
package: *const CIrPackage,
function_name: *const std::os::raw::c_char,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CIrFunction,
) -> bool;
pub fn xls_package_get_functions(
package: *mut CIrPackage,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut *mut CIrFunction,
count_out: *mut libc::size_t,
) -> bool;
pub fn xls_function_ptr_array_free(function_pointer_array: *mut *mut CIrFunction);
pub fn xls_function_get_type(
function: *const CIrFunction,
error_out: *mut *mut std::os::raw::c_char,
xls_fn_type_out: *mut *mut CIrFunctionType,
) -> bool;
pub fn xls_function_type_to_string(
t: *const CIrFunctionType,
error_out: *mut *mut std::os::raw::c_char,
string_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_function_get_name(
function: *const CIrFunction,
error_out: *mut *mut std::os::raw::c_char,
name_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_function_to_z3_smtlib(
function: *mut CIrFunction,
error_out: *mut *mut std::os::raw::c_char,
string_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_interpret_function(
function: *const CIrFunction,
argc: libc::size_t,
args: *const *const CIrValue,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CIrValue,
) -> bool;
pub fn xls_optimize_ir(
ir: *const std::os::raw::c_char,
top: *const std::os::raw::c_char,
error_out: *mut *mut std::os::raw::c_char,
ir_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_mangle_dslx_name(
module_name: *const std::os::raw::c_char,
function_name: *const std::os::raw::c_char,
error_out: *mut *mut std::os::raw::c_char,
mangled_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_init_xls(
usage: *const std::os::raw::c_char,
argc: libc::c_int,
argv: *mut *mut std::os::raw::c_char,
);
pub fn xls_package_to_string(
p: *const CIrPackage,
string_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_function_to_string(
f: *const CIrFunction,
string_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_package_get_top(p: *mut CIrPackage) -> *mut CIrFunctionBase;
pub fn xls_package_set_top_by_name(
p: *mut CIrPackage,
name: *const std::os::raw::c_char,
error_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_verify_package(
p: *mut CIrPackage,
error_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_make_function_jit(
function: *const CIrFunction,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CIrFunctionJit,
) -> bool;
pub fn xls_aot_compile_function(
function: *mut CIrFunction,
error_out: *mut *mut std::os::raw::c_char,
object_code_out: *mut *mut u8,
object_code_count_out: *mut libc::size_t,
entrypoints_proto_out: *mut *mut u8,
entrypoints_proto_count_out: *mut libc::size_t,
) -> bool;
pub fn xls_aot_object_code_free(object_code: *mut u8);
pub fn xls_aot_entrypoints_proto_free(entrypoints_proto: *mut u8);
pub fn xls_aot_exec_context_create(
entrypoints_proto: *const u8,
entrypoints_proto_count: libc::size_t,
error_out: *mut *mut std::os::raw::c_char,
out: *mut *mut CXlsAotExecContext,
) -> bool;
pub fn xls_aot_exec_context_clear_events(context: *mut CXlsAotExecContext);
pub fn xls_aot_exec_context_free(context: *mut CXlsAotExecContext);
pub fn xls_aot_entrypoint_trampoline(
function_ptr: usize,
inputs: *const *const u8,
outputs: *const *mut u8,
temp_buffer: *mut libc::c_void,
context: *mut CXlsAotExecContext,
continuation_point: i64,
trace_messages_count_out: *mut libc::size_t,
assert_messages_count_out: *mut libc::size_t,
) -> i64;
pub fn xls_aot_exec_context_get_trace_message(
context: *const CXlsAotExecContext,
index: libc::size_t,
error_out: *mut *mut std::os::raw::c_char,
trace_message_out: *mut CTraceMessage,
) -> bool;
pub fn xls_aot_exec_context_get_assert_message(
context: *const CXlsAotExecContext,
index: libc::size_t,
error_out: *mut *mut std::os::raw::c_char,
assert_message_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_function_jit_free(jit: *mut CIrFunctionJit);
pub fn xls_function_jit_run(
jit: *const CIrFunctionJit,
argc: libc::size_t,
args: *const *const CIrValue,
error_out: *mut *mut std::os::raw::c_char,
trace_messages_out: *mut *mut CTraceMessage,
trace_messages_count_out: *mut libc::size_t,
assert_messages_out: *mut *mut *mut std::os::raw::c_char,
assert_messages_count_out: *mut libc::size_t,
result_out: *mut *mut CIrValue,
) -> bool;
pub fn xls_trace_messages_free(trace_messages: *mut CTraceMessage, count: libc::size_t);
pub fn xls_dslx_import_data_create(
dslx_stdlib_path: *const std::os::raw::c_char,
additional_search_paths: *const *const std::os::raw::c_char,
additional_search_paths_count: libc::size_t,
) -> *mut CDslxImportData;
pub fn xls_dslx_import_data_free(data: *mut CDslxImportData);
pub fn xls_dslx_parse_and_typecheck(
text: *const std::os::raw::c_char,
path: *const std::os::raw::c_char,
module_name: *const std::os::raw::c_char,
import_data: *const CDslxImportData,
error_out: *mut *mut std::os::raw::c_char,
typechecked_module_out: *mut *mut CDslxTypecheckedModule,
) -> bool;
pub fn xls_dslx_typechecked_module_clone_removing_functions(
tm: *mut CDslxTypecheckedModule,
functions: *mut *mut CDslxFunction,
function_count: libc::size_t,
install_subject: *const std::os::raw::c_char,
import_data: *mut CDslxImportData,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CDslxTypecheckedModule,
) -> bool;
pub fn xls_dslx_typechecked_module_clone_removing_members(
tm: *mut CDslxTypecheckedModule,
members: *mut *mut CDslxModuleMember,
member_count: libc::size_t,
install_subject: *const std::os::raw::c_char,
import_data: *mut CDslxImportData,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CDslxTypecheckedModule,
) -> bool;
pub fn xls_dslx_replace_invocations_in_module(
tm: *mut CDslxTypecheckedModule,
callers: *const *mut CDslxFunction,
callers_count: libc::size_t,
rules: *const CDslxInvocationRewriteRule,
rules_count: libc::size_t,
import_data: *mut CDslxImportData,
install_subject: *const std::os::raw::c_char,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CDslxTypecheckedModule,
) -> bool;
pub fn xls_dslx_typechecked_module_insert_function_specializations(
typechecked_module: *mut CDslxTypecheckedModule,
requests: *const XlsDslxFunctionSpecializationRequest,
request_count: libc::size_t,
import_data: *mut CDslxImportData,
install_subject: *const std::os::raw::c_char,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CDslxTypecheckedModule,
) -> bool;
pub fn xls_schedule_and_codegen_package(
p: *mut CIrPackage,
scheduling_options_flags_proto: *const std::os::raw::c_char,
codegen_flags_proto: *const std::os::raw::c_char,
with_delay_model: bool,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CScheduleAndCodegenResult,
) -> bool;
pub fn xls_schedule_and_codegen_result_get_verilog_text(
result: *mut CScheduleAndCodegenResult,
) -> *mut std::os::raw::c_char;
pub fn xls_schedule_and_codegen_result_free(result: *mut CScheduleAndCodegenResult);
pub fn xls_dslx_typechecked_module_free(module: *mut CDslxTypecheckedModule);
pub fn xls_dslx_typechecked_module_get_module(
module: *mut CDslxTypecheckedModule,
) -> *mut CDslxModule;
pub fn xls_dslx_typechecked_module_get_type_info(
module: *mut CDslxTypecheckedModule,
) -> *mut CDslxTypeInfo;
pub fn xls_dslx_module_to_string(module: *mut CDslxModule) -> *mut std::os::raw::c_char;
pub fn xls_dslx_module_get_name(module: *const CDslxModule) -> *mut std::os::raw::c_char;
pub fn xls_dslx_module_get_type_definition_count(module: *const CDslxModule) -> i64;
pub fn xls_dslx_module_get_member_count(module: *const CDslxModule) -> i64;
pub fn xls_dslx_module_get_member(module: *const CDslxModule, i: i64)
-> *mut CDslxModuleMember;
pub fn xls_dslx_module_get_type_definition_kind(
module: *const CDslxModule,
i: i64,
) -> DslxTypeDefinitionKind;
pub fn xls_dslx_module_get_type_definition_as_struct_def(
module: *const CDslxModule,
i: i64,
) -> *mut CDslxStructDef;
pub fn xls_dslx_module_get_type_definition_as_enum_def(
module: *const CDslxModule,
i: i64,
) -> *mut CDslxEnumDef;
pub fn xls_dslx_module_get_type_definition_as_sum_def(
module: *const CDslxModule,
i: i64,
) -> *mut CDslxSumDef;
pub fn xls_dslx_module_get_type_definition_as_type_alias(
module: *const CDslxModule,
i: i64,
) -> *mut CDslxTypeAlias;
pub fn xls_dslx_module_member_get_kind(
member: *const CDslxModuleMember,
) -> DslxModuleMemberKind;
pub fn xls_dslx_module_member_get_constant_def(
member: *const CDslxModuleMember,
) -> *mut CDslxConstantDef;
pub fn xls_dslx_module_member_get_type_alias(
member: *const CDslxModuleMember,
) -> *mut CDslxTypeAlias;
pub fn xls_dslx_module_member_get_struct_def(
member: *const CDslxModuleMember,
) -> *mut CDslxStructDef;
pub fn xls_dslx_module_member_get_enum_def(
member: *const CDslxModuleMember,
) -> *mut CDslxEnumDef;
pub fn xls_dslx_module_member_get_sum_def(member: *const CDslxModuleMember)
-> *mut CDslxSumDef;
pub fn xls_dslx_module_member_get_function(
member: *const CDslxModuleMember,
) -> *mut CDslxFunction;
pub fn xls_dslx_module_member_get_import(member: *const CDslxModuleMember) -> *mut CDslxImport;
pub fn xls_dslx_module_member_get_quickcheck(
member: *const CDslxModuleMember,
) -> *mut CDslxQuickcheck;
pub fn xls_dslx_module_member_from_constant_def(
constant_def: *mut CDslxConstantDef,
) -> *mut CDslxModuleMember;
pub fn xls_dslx_module_member_from_struct_def(
struct_def: *mut CDslxStructDef,
) -> *mut CDslxModuleMember;
pub fn xls_dslx_module_member_from_enum_def(
enum_def: *mut CDslxEnumDef,
) -> *mut CDslxModuleMember;
pub fn xls_dslx_module_member_from_sum_def(sum_def: *mut CDslxSumDef)
-> *mut CDslxModuleMember;
pub fn xls_dslx_module_member_from_type_alias(
type_alias: *mut CDslxTypeAlias,
) -> *mut CDslxModuleMember;
pub fn xls_dslx_module_member_from_function(
function: *mut CDslxFunction,
) -> *mut CDslxModuleMember;
pub fn xls_dslx_module_member_from_quickcheck(
quickcheck: *mut CDslxQuickcheck,
) -> *mut CDslxModuleMember;
pub fn xls_dslx_colon_ref_get_attr(
colon_ref: *const CDslxColonRef,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_type_info_get_type_struct_def(
type_info: *mut CDslxTypeInfo,
node: *mut CDslxStructDef,
) -> *mut CDslxType;
pub fn xls_dslx_type_info_get_type_enum_def(
type_info: *mut CDslxTypeInfo,
node: *mut CDslxEnumDef,
) -> *mut CDslxType;
pub fn xls_dslx_type_info_get_type_sum_def(
type_info: *mut CDslxTypeInfo,
node: *mut CDslxSumDef,
) -> *mut CDslxType;
pub fn xls_dslx_type_info_get_type_struct_member(
type_info: *mut CDslxTypeInfo,
member: *mut CDslxStructMember,
) -> *mut CDslxType;
pub fn xls_dslx_type_info_get_type_constant_def(
type_info: *mut CDslxTypeInfo,
node: *mut CDslxConstantDef,
) -> *mut CDslxType;
pub fn xls_dslx_type_info_get_type_type_annotation(
type_info: *mut CDslxTypeInfo,
type_annotation: *mut CDslxTypeAnnotation,
) -> *mut CDslxType;
pub fn xls_dslx_type_info_get_imported_type_info(
type_info: *mut CDslxTypeInfo,
module: *mut CDslxModule,
) -> *mut CDslxTypeInfo;
pub fn xls_dslx_type_info_get_unique_invocation_callee_data(
type_info: *mut CDslxTypeInfo,
function: *mut CDslxFunction,
) -> *mut CDslxInvocationCalleeDataArray;
pub fn xls_dslx_type_info_get_all_invocation_callee_data(
type_info: *mut CDslxTypeInfo,
function: *mut CDslxFunction,
) -> *mut CDslxInvocationCalleeDataArray;
pub fn xls_dslx_type_info_get_root_invocation_data(
type_info: *mut CDslxTypeInfo,
invocation: *mut CDslxInvocation,
) -> *mut CDslxInvocationData;
pub fn xls_dslx_type_info_build_function_call_graph(
type_info: *mut CDslxTypeInfo,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CDslxCallGraph,
) -> bool;
pub fn xls_dslx_type_info_build_function_call_graph_for_module(
type_info: *mut CDslxTypeInfo,
module: *mut CDslxModule,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CDslxCallGraph,
) -> bool;
pub fn xls_dslx_call_graph_free(call_graph: *mut CDslxCallGraph);
pub fn xls_dslx_call_graph_get_function_count(call_graph: *mut CDslxCallGraph) -> i64;
pub fn xls_dslx_call_graph_get_function(
call_graph: *mut CDslxCallGraph,
index: i64,
) -> *mut CDslxFunction;
pub fn xls_dslx_call_graph_get_callee_count(
call_graph: *mut CDslxCallGraph,
caller: *mut CDslxFunction,
) -> i64;
pub fn xls_dslx_call_graph_get_callee_function(
call_graph: *mut CDslxCallGraph,
caller: *mut CDslxFunction,
callee_index: i64,
) -> *mut CDslxFunction;
pub fn xls_dslx_invocation_callee_data_array_free(array: *mut CDslxInvocationCalleeDataArray);
pub fn xls_dslx_invocation_callee_data_array_get_count(
array: *mut CDslxInvocationCalleeDataArray,
) -> i64;
pub fn xls_dslx_invocation_callee_data_array_get(
array: *mut CDslxInvocationCalleeDataArray,
index: i64,
) -> *mut CDslxInvocationCalleeData;
pub fn xls_dslx_invocation_callee_data_clone(
data: *mut CDslxInvocationCalleeData,
) -> *mut CDslxInvocationCalleeData;
pub fn xls_dslx_invocation_callee_data_free(data: *mut CDslxInvocationCalleeData);
pub fn xls_dslx_invocation_callee_data_get_callee_bindings(
data: *mut CDslxInvocationCalleeData,
) -> *const CDslxParametricEnv;
pub fn xls_dslx_invocation_callee_data_get_caller_bindings(
data: *mut CDslxInvocationCalleeData,
) -> *const CDslxParametricEnv;
pub fn xls_dslx_invocation_callee_data_get_derived_type_info(
data: *mut CDslxInvocationCalleeData,
) -> *mut CDslxTypeInfo;
pub fn xls_dslx_invocation_callee_data_get_invocation(
data: *mut CDslxInvocationCalleeData,
) -> *mut CDslxInvocation;
pub fn xls_dslx_invocation_data_get_invocation(
data: *mut CDslxInvocationData,
) -> *mut CDslxInvocation;
pub fn xls_dslx_invocation_data_get_callee(
data: *mut CDslxInvocationData,
) -> *mut CDslxFunction;
pub fn xls_dslx_invocation_data_get_caller(
data: *mut CDslxInvocationData,
) -> *mut CDslxFunction;
pub fn xls_dslx_constant_def_get_name(
constant_def: *const CDslxConstantDef,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_constant_def_get_value(constant_def: *const CDslxConstantDef)
-> *mut CDslxExpr;
pub fn xls_dslx_type_alias_get_identifier(
type_alias: *const CDslxTypeAlias,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_type_alias_get_type_annotation(
type_alias: *const CDslxTypeAlias,
) -> *mut CDslxTypeAnnotation;
pub fn xls_dslx_type_annotation_get_type_ref_type_annotation(
type_annotation: *const CDslxTypeAnnotation,
) -> *mut CDslxTypeRefTypeAnnotation;
pub fn xls_dslx_type_annotation_get_array_type_annotation(
type_annotation: *const CDslxTypeAnnotation,
) -> *mut CDslxArrayTypeAnnotation;
pub fn xls_dslx_array_type_annotation_get_element_type(
array_type_annotation: *const CDslxArrayTypeAnnotation,
) -> *mut CDslxTypeAnnotation;
pub fn xls_dslx_type_ref_get_type_definition(
type_ref: *const CDslxTypeRef,
) -> *mut CDslxTypeDefinition;
pub fn xls_dslx_import_get_subject_count(import: *const CDslxImport) -> i64;
pub fn xls_dslx_import_get_subject(
import: *const CDslxImport,
i: i64,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_colon_ref_resolve_import_subject(
colon_ref: *const CDslxColonRef,
) -> *mut CDslxImport;
pub fn xls_dslx_type_definition_get_colon_ref(
type_definition: *const CDslxTypeDefinition,
) -> *mut CDslxColonRef;
pub fn xls_dslx_type_definition_get_type_alias(
type_definition: *const CDslxTypeDefinition,
) -> *mut CDslxTypeAlias;
pub fn xls_dslx_type_ref_type_annotation_get_type_ref(
type_ref_type_annotation: *const CDslxTypeRefTypeAnnotation,
) -> *mut CDslxTypeRef;
pub fn xls_dslx_type_ref_type_annotation_get_parametric_count(
type_ref_type_annotation: *const CDslxTypeRefTypeAnnotation,
) -> i64;
pub fn xls_dslx_type_ref_type_annotation_get_parametric_expr(
type_ref_type_annotation: *const CDslxTypeRefTypeAnnotation,
index: i64,
) -> *mut CDslxExpr;
pub fn xls_dslx_struct_def_get_identifier(
struct_def: *const CDslxStructDef,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_struct_def_is_parametric(struct_def: *const CDslxStructDef) -> bool;
pub fn xls_dslx_struct_def_get_parametric_binding_count(
struct_def: *const CDslxStructDef,
) -> i64;
pub fn xls_dslx_struct_def_get_parametric_binding(
struct_def: *const CDslxStructDef,
index: i64,
) -> *mut CDslxParametricBinding;
pub fn xls_dslx_struct_def_get_member_count(struct_def: *const CDslxStructDef) -> i64;
pub fn xls_dslx_struct_def_get_member(
struct_def: *const CDslxStructDef,
i: i64,
) -> *mut CDslxStructMember;
pub fn xls_dslx_struct_member_get_name(
member: *const CDslxStructMember,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_struct_member_get_type(
member: *const CDslxStructMember,
) -> *mut CDslxTypeAnnotation;
pub fn xls_dslx_enum_def_get_identifier(
enum_def: *const CDslxEnumDef,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_enum_def_get_member_count(enum_def: *const CDslxEnumDef) -> i64;
pub fn xls_dslx_enum_def_get_member(
enum_def: *const CDslxEnumDef,
i: i64,
) -> *mut CDslxEnumMember;
pub fn xls_dslx_enum_def_get_underlying(
enum_def: *const CDslxEnumDef,
) -> *mut CDslxTypeAnnotation;
pub fn xls_dslx_enum_member_get_name(
member: *const CDslxEnumMember,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_enum_member_get_value(member: *const CDslxEnumMember) -> *mut CDslxExpr;
pub fn xls_dslx_sum_def_get_identifier(
sum_def: *const CDslxSumDef,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_sum_def_is_parametric(sum_def: *const CDslxSumDef) -> bool;
pub fn xls_dslx_sum_def_get_variant_count(sum_def: *const CDslxSumDef) -> i64;
pub fn xls_dslx_expr_get_owner_module(expr: *mut CDslxExpr) -> *mut CDslxModule;
pub fn xls_dslx_interp_value_free(value: *mut CDslxInterpValue);
pub fn xls_dslx_interp_value_to_string(
value: *mut CDslxInterpValue,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_interp_value_clone(value: *const CDslxInterpValue) -> *mut CDslxInterpValue;
pub fn xls_dslx_parametric_env_create(
items: *const XlsDslxParametricEnvItem,
items_count: libc::size_t,
error_out: *mut *mut std::os::raw::c_char,
env_out: *mut *mut CDslxParametricEnv,
) -> bool;
pub fn xls_dslx_parametric_env_free(env: *mut CDslxParametricEnv);
pub fn xls_dslx_parametric_env_clone(env: *const CDslxParametricEnv)
-> *mut CDslxParametricEnv;
pub fn xls_dslx_parametric_env_equals(
lhs: *const CDslxParametricEnv,
rhs: *const CDslxParametricEnv,
) -> bool;
pub fn xls_dslx_parametric_env_less_than(
lhs: *const CDslxParametricEnv,
rhs: *const CDslxParametricEnv,
) -> bool;
pub fn xls_dslx_parametric_env_hash(env: *const CDslxParametricEnv) -> u64;
pub fn xls_dslx_parametric_env_to_string(
env: *const CDslxParametricEnv,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_parametric_env_get_binding_count(env: *const CDslxParametricEnv) -> i64;
pub fn xls_dslx_parametric_env_get_binding_identifier(
env: *const CDslxParametricEnv,
index: i64,
) -> *const std::os::raw::c_char;
pub fn xls_dslx_parametric_env_get_binding_value(
env: *const CDslxParametricEnv,
index: i64,
) -> *mut CDslxInterpValue;
pub fn xls_dslx_interp_value_make_ubits(bit_count: i64, value: u64) -> *mut CDslxInterpValue;
pub fn xls_dslx_interp_value_make_sbits(bit_count: i64, value: i64) -> *mut CDslxInterpValue;
pub fn xls_dslx_interp_value_make_enum(
def: *mut CDslxEnumDef,
is_signed: bool,
bits: *const CIrBits,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CDslxInterpValue,
) -> bool;
pub fn xls_dslx_interp_value_make_tuple(
element_count: libc::size_t,
elements: *mut *mut CDslxInterpValue,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CDslxInterpValue,
) -> bool;
pub fn xls_dslx_interp_value_make_array(
element_count: libc::size_t,
elements: *mut *mut CDslxInterpValue,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CDslxInterpValue,
) -> bool;
pub fn xls_dslx_interp_value_from_string(
text: *const std::os::raw::c_char,
dslx_stdlib_path: *const std::os::raw::c_char,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CDslxInterpValue,
) -> bool;
pub fn xls_dslx_interp_value_convert_to_ir(
value: *const CDslxInterpValue,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CIrValue,
) -> bool;
pub fn xls_dslx_type_to_string(
type_: *const CDslxType,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_dslx_function_to_string(function: *const CDslxFunction)
-> *mut std::os::raw::c_char;
pub fn xls_dslx_struct_def_to_string(
struct_def: *const CDslxStructDef,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_enum_def_to_string(enum_def: *const CDslxEnumDef) -> *mut std::os::raw::c_char;
pub fn xls_dslx_sum_def_to_string(sum_def: *const CDslxSumDef) -> *mut std::os::raw::c_char;
pub fn xls_dslx_type_alias_to_string(
type_alias: *const CDslxTypeAlias,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_constant_def_to_string(
constant_def: *const CDslxConstantDef,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_quickcheck_to_string(qc: *const CDslxQuickcheck) -> *mut std::os::raw::c_char;
pub fn xls_dslx_expr_to_string(expr: *const CDslxExpr) -> *mut std::os::raw::c_char;
pub fn xls_dslx_type_info_get_const_expr(
type_info: *mut CDslxTypeInfo,
expr: *mut CDslxExpr,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut *mut CDslxInterpValue,
) -> bool;
pub fn xls_dslx_type_get_total_bit_count(
type_: *const CDslxType,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut i64,
) -> bool;
pub fn xls_dslx_type_is_signed_bits(
type_: *const CDslxType,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut bool,
) -> bool;
pub fn xls_dslx_type_is_bits_like(
type_: *const CDslxType,
is_signed: *mut *mut CDslxTypeDim,
size: *mut *mut CDslxTypeDim,
) -> bool;
pub fn xls_dslx_type_is_enum(type_: *const CDslxType) -> bool;
pub fn xls_dslx_type_is_struct(type_: *const CDslxType) -> bool;
pub fn xls_dslx_type_is_array(type_: *const CDslxType) -> bool;
pub fn xls_dslx_type_dim_is_parametric(dim: *const CDslxTypeDim) -> bool;
pub fn xls_dslx_type_dim_get_as_bool(
dim: *const CDslxTypeDim,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut bool,
) -> bool;
pub fn xls_dslx_type_dim_get_as_int64(
dim: *const CDslxTypeDim,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut i64,
) -> bool;
pub fn xls_dslx_type_dim_free(dim: *mut CDslxTypeDim);
pub fn xls_dslx_type_get_enum_def(ty: *const CDslxType) -> *mut CDslxEnumDef;
pub fn xls_dslx_type_get_struct_def(ty: *const CDslxType) -> *mut CDslxStructDef;
pub fn xls_dslx_type_struct_get_member_count(ty: *const CDslxType) -> i64;
pub fn xls_dslx_type_struct_get_member_type(ty: *const CDslxType, index: i64)
-> *mut CDslxType;
pub fn xls_dslx_type_array_get_element_type(ty: *const CDslxType) -> *mut CDslxType;
pub fn xls_dslx_type_array_get_size(ty: *const CDslxType) -> *mut CDslxTypeDim;
pub fn xls_package_create(name: *const std::os::raw::c_char) -> *mut CIrPackage;
pub fn xls_package_get_bits_type(package: *mut CIrPackage, bit_count: i64) -> *mut CIrType;
pub fn xls_package_get_tuple_type(
package: *mut CIrPackage,
members: *mut *mut CIrType,
member_count: i64,
) -> *mut CIrType;
pub fn xls_package_get_array_type(
package: *mut CIrPackage,
element_type: *mut CIrType,
size: i64,
) -> *mut CIrType;
pub fn xls_package_get_token_type(package: *mut CIrPackage) -> *mut CIrType;
pub fn xls_function_type_get_param_count(fty: *mut CIrFunctionType) -> i64;
pub fn xls_function_type_get_param_type(
fty: *mut CIrFunctionType,
index: libc::size_t,
error_out: *mut *mut std::os::raw::c_char,
param_type_out: *mut *mut CIrType,
) -> bool;
pub fn xls_function_type_get_return_type(fty: *mut CIrFunctionType) -> *mut CIrType;
pub fn xls_function_get_param_name(
function: *mut CIrFunction,
index: libc::size_t,
error_out: *mut *mut std::os::raw::c_char,
name_out: *mut *mut std::os::raw::c_char,
) -> bool;
pub fn xls_dslx_function_is_parametric(function: *const CDslxFunction) -> bool;
pub fn xls_dslx_function_is_public(function: *const CDslxFunction) -> bool;
pub fn xls_dslx_function_get_identifier(
function: *const CDslxFunction,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_function_get_param_count(function: *const CDslxFunction) -> i64;
pub fn xls_dslx_function_get_parametric_binding_count(function: *const CDslxFunction) -> i64;
pub fn xls_dslx_function_get_param(
function: *const CDslxFunction,
index: i64,
) -> *mut CDslxParam;
pub fn xls_dslx_function_get_parametric_binding(
function: *const CDslxFunction,
index: i64,
) -> *mut CDslxParametricBinding;
pub fn xls_dslx_function_get_body(function: *const CDslxFunction) -> *mut CDslxExpr;
pub fn xls_dslx_function_get_return_type(
function: *const CDslxFunction,
) -> *mut CDslxTypeAnnotation;
pub fn xls_dslx_function_get_attribute_count(function: *const CDslxFunction) -> i64;
pub fn xls_dslx_function_get_attribute(
function: *const CDslxFunction,
index: i64,
) -> *mut CDslxAttribute;
pub fn xls_dslx_param_get_name(param: *const CDslxParam) -> *mut std::os::raw::c_char;
pub fn xls_dslx_param_get_type_annotation(param: *const CDslxParam)
-> *mut CDslxTypeAnnotation;
pub fn xls_dslx_attribute_get_kind(attribute: *const CDslxAttribute) -> DslxAttributeKind;
pub fn xls_dslx_attribute_get_argument_count(attribute: *const CDslxAttribute) -> i64;
pub fn xls_dslx_attribute_get_argument_kind(
attribute: *const CDslxAttribute,
index: i64,
) -> DslxAttributeArgumentKind;
pub fn xls_dslx_attribute_get_string_argument(
attribute: *const CDslxAttribute,
index: i64,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_attribute_get_string_literal_argument(
attribute: *const CDslxAttribute,
index: i64,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_attribute_get_key_value_argument_key(
attribute: *const CDslxAttribute,
index: i64,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_attribute_get_key_value_string_argument_value(
attribute: *const CDslxAttribute,
index: i64,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_attribute_get_key_value_int_argument_value(
attribute: *const CDslxAttribute,
index: i64,
) -> i64;
pub fn xls_dslx_attribute_to_string(
attribute: *const CDslxAttribute,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_parametric_binding_get_identifier(
binding: *const CDslxParametricBinding,
) -> *mut std::os::raw::c_char;
pub fn xls_dslx_parametric_binding_get_type_annotation(
binding: *const CDslxParametricBinding,
) -> *mut CDslxTypeAnnotation;
pub fn xls_dslx_parametric_binding_get_expr(
binding: *const CDslxParametricBinding,
) -> *mut CDslxExpr;
pub fn xls_dslx_parametric_binding_get_default_generic_type(
binding: *const CDslxParametricBinding,
) -> *mut CDslxTypeAnnotation;
pub fn xls_dslx_type_info_get_requires_implicit_token(
type_info: *mut CDslxTypeInfo,
function: *mut CDslxFunction,
error_out: *mut *mut std::os::raw::c_char,
result_out: *mut bool,
) -> bool;
pub fn xls_dslx_quickcheck_get_function(qc: *const CDslxQuickcheck) -> *mut CDslxFunction;
pub fn xls_dslx_quickcheck_is_exhaustive(qc: *const CDslxQuickcheck) -> bool;
pub fn xls_dslx_quickcheck_get_count(qc: *const CDslxQuickcheck, result_out: *mut i64) -> bool;
}
mod generated_artifact_paths {
include!(concat!(env!("OUT_DIR"), "/artifact_paths.rs"));
}
pub const DSLX_STDLIB_PATH: &str = generated_artifact_paths::DSLX_STDLIB_PATH;
pub const XLS_DSO_PATH: &str = generated_artifact_paths::XLS_DSO_PATH;