#include "run-time.h"

/* Typedefs for referenced classes */

typedef struct {
  D wrapper;
  D instanceQ_iep_;
  D debug_name_;
  D class_implementation_class_;
  D class_subtype_bit_;
  D class_module_;
} _KLclassGVKd;

#define  define__KLmm_wrapperGVKi(nrepeated) \
  typedef struct { \
    D wrapper; \
    D mm_wrapper_implementation_class_; \
    D mm_wrapper_subtype_mask_; \
    DWORD mm_wrapper_fixed_part_; \
    DWORD mm_wrapper_variable_part_; \
    D mm_wrapper_number_patterns_; \
    DWORD mm_wrapper_pattern_element_[nrepeated+1]; \
  } _KLmm_wrapperGVKi_##nrepeated;
define__KLmm_wrapperGVKi(1);
define__KLmm_wrapperGVKi(0);

typedef struct {
  D wrapper;
} _KLobjectGVKd;

typedef struct {
  D wrapper;
} _KLunboundGVKe;

typedef struct {
  D wrapper;
} _KLbooleanGVKd;

typedef struct {
  D wrapper;
  D namespace_name_;
  D home_library_;
} _KLmoduleGVKe;

#define  define__KLbyte_stringGVKd(nrepeated) \
  typedef struct { \
    D wrapper; \
    D size_; \
    char string_element_[nrepeated+1]; \
  } _KLbyte_stringGVKd_##nrepeated;
define__KLbyte_stringGVKd(5);
define__KLbyte_stringGVKd(12);

typedef struct {
  D wrapper;
  D namespace_name_;
  D library_major_version_;
  D library_minor_version_;
  D library_build_count_;
  D used_libraries_;
  D all_used_libraries_;
  D runtime_module_;
  D library_defined_generics_;
  D library_number_static_dispatches_;
  D library_number_dynamic_dispatches_;
} _KLlibraryGVKe;

#define  define__KLsimple_object_vectorGVKd(nrepeated) \
  typedef struct { \
    D wrapper; \
    D size_; \
    D vector_element_[nrepeated+1]; \
  } _KLsimple_object_vectorGVKd_##nrepeated;
define__KLsimple_object_vectorGVKd(11);
define__KLsimple_object_vectorGVKd(14);
define__KLsimple_object_vectorGVKd(0);

typedef struct {
  D wrapper;
  D library_major_version_;
  D library_minor_version_;
  D library_build_count_;
  D used_library_;
  D used_library_binding_;
} _KLused_libraryGVKe;

typedef struct {
  D wrapper;
  D symbol_name_;
} _KLsymbolGVKd;

typedef struct {
  D wrapper;
  D mangler_;
  D cg_variables_;
  D registers_;
  D variables_;
} _KLdummy_harp_back_endGVdfmc_harp_cg;

typedef struct {
  D wrapper;
  D runtime_object_name_;
} _KLruntime_objectGVdfmc_harp_cg;

typedef struct {
  D wrapper;
  D runtime_object_name_;
} _KLdood_runtime_objectGVdfmc_harp_cg;

typedef struct {
  D wrapper;
  D runtime_object_name_;
} _KLlocal_runtime_objectGVdfmc_harp_cg;

typedef struct {
  D wrapper;
  D runtime_object_name_;
} _KLc_runtime_objectGVdfmc_harp_cg;

typedef struct {
  D wrapper;
  D object_dood_state_;
  D dood_proxy_runtime_object_;
} _KLdood_runtime_object_proxyGVdfmc_harp_cg;

typedef struct {
  D wrapper;
  D runtime_object_name_;
  D dylan_model_object_;
} _KLdylan_objectGVdfmc_harp_cg;

typedef struct {
  D wrapper;
  D mv_register_;
  D mv_elements_;
} _KLcg_multiple_valuesGVdfmc_harp_cg;

typedef struct {
  D wrapper;
  D branch_;
  D operands_;
  D result_;
  D continue_tag_;
  D true_tag_;
  D true_tag_internal_;
  D false_tag_;
  D false_tag_internal_;
} _KLtest_resultGVdfmc_harp_cg;

typedef struct {
  D wrapper;
  D cg_register_;
  D loop_register_;
  D values_register_;
} _KLcg_registerGVdfmc_harp_cg;

typedef struct {
  D wrapper;
  D cg_symbol_name_;
  D cg_uninterned_symbol_;
  D cg_indirect_symbol_;
} _KLsymbol_objectGVdfmc_harp_cg;


/* Typedefs for defined classes */


/* Referenced object declarations */

D Kinitialize_class_dispatch_keys_vectoredVKgI (D);
D KPlibrary_version_checkVKeI (D, D);
extern _KLclassGVKd KLclassGVKd;
extern _KLmm_wrapperGVKi_0 KLclassGVKdW;
extern _KLclassGVKd KLmm_wrapperGVKi;
extern _KLmm_wrapperGVKi_1 KLmm_wrapperGVKiW;
extern _KLclassGVKd KLobjectGVKd;
extern _KLmm_wrapperGVKi_0 KLobjectGVKdW;
extern _KLunboundGVKe KPunboundVKi;
extern _KLclassGVKd KLunboundGVKe;
extern _KLmm_wrapperGVKi_0 KLunboundGVKeW;
extern _KLbooleanGVKd KPtrueVKi;
extern _KLclassGVKd KLbooleanGVKd;
extern _KLmm_wrapperGVKi_0 KLbooleanGVKdW;
extern _KLbooleanGVKd KPfalseVKi;
extern _KLclassGVKd KLmoduleGVKe;
extern _KLmm_wrapperGVKi_0 KLmoduleGVKeW;
extern _KLclassGVKd KLbyte_stringGVKd;
extern _KLmm_wrapperGVKi_0 KLbyte_stringGVKdW;
extern _KLclassGVKd KLlibraryGVKe;
extern _KLmm_wrapperGVKi_0 KLlibraryGVKeW;
extern _KLsimple_object_vectorGVKd_0 KPempty_vectorVKi;
extern _KLclassGVKd KLsimple_object_vectorGVKd;
extern _KLmm_wrapperGVKi_0 KLsimple_object_vectorGVKdW;
extern _KLclassGVKd KLused_libraryGVKe;
extern _KLmm_wrapperGVKi_0 KLused_libraryGVKeW;
extern _KLlibraryGVKe Kdylan_libraryYdylan_userVdylan;
extern _KLclassGVKd KLsymbolGVKd;
extern _KLmm_wrapperGVKi_0 KLsymbolGVKdW;
extern _KLlibraryGVKe Kcommon_dylan_libraryYdylan_userVcommon_dylan;
extern _KLlibraryGVKe Kio_libraryYdylan_userVio;
extern _KLlibraryGVKe Kbig_integers_libraryYdylan_userVbig_integers;
extern _KLlibraryGVKe Kdfmc_core_libraryYdylan_userVdfmc_core;
extern _KLlibraryGVKe Kdfmc_back_end_libraryYdylan_userVdfmc_back_end;
extern _KLlibraryGVKe Kdfmc_reader_libraryYdylan_userVdfmc_reader;
extern _KLlibraryGVKe Kdfmc_conversion_libraryYdylan_userVdfmc_conversion;
extern _KLlibraryGVKe Kdfmc_optimization_libraryYdylan_userVdfmc_optimization;
extern _KLlibraryGVKe Kdfmc_typist_libraryYdylan_userVdfmc_typist;
extern _KLlibraryGVKe Kdfmc_management_libraryYdylan_userVdfmc_management;
extern _KLlibraryGVKe Kharp_cg_back_end_libraryYdylan_userVharp_cg_back_end;
extern _KLlibraryGVKe Kharp_native_libraryYdylan_userVharp_native;
extern _KLlibraryGVKe Kmnemonic_assembler_libraryYdylan_userVmnemonic_assembler;
extern _KLclassGVKd KLdummy_harp_back_endGVdfmc_harp_cg;
extern _KLclassGVKd KLruntime_objectGVdfmc_harp_cg;
extern _KLclassGVKd KLdood_runtime_objectGVdfmc_harp_cg;
extern _KLclassGVKd KLlocal_runtime_objectGVdfmc_harp_cg;
extern _KLclassGVKd KLc_runtime_objectGVdfmc_harp_cg;
extern _KLclassGVKd KLdood_runtime_object_proxyGVdfmc_harp_cg;
extern _KLclassGVKd KLdylan_objectGVdfmc_harp_cg;
extern _KLclassGVKd KLcg_multiple_valuesGVdfmc_harp_cg;
extern _KLclassGVKd KLtest_resultGVdfmc_harp_cg;
extern _KLclassGVKd KLcg_registerGVdfmc_harp_cg;
extern _KLclassGVKd KLsymbol_objectGVdfmc_harp_cg;

/* Defined object declarations */

extern _KLlibraryGVKe Kdfmc_harp_cg_libraryYdylan_userVdfmc_harp_cg;
extern _KLmoduleGVKe Kdfmc_harp_cg_moduleYdylan_userVdfmc_harp_cg;
static _KLbyte_stringGVKd_12 K5;
static _KLsimple_object_vectorGVKd_14 K6;
static _KLused_libraryGVKe K7;
static _KLused_libraryGVKe K8;
static _KLused_libraryGVKe K9;
static _KLused_libraryGVKe K10;
static _KLused_libraryGVKe K11;
static _KLused_libraryGVKe K12;
static _KLused_libraryGVKe K13;
static _KLused_libraryGVKe K14;
static _KLused_libraryGVKe K15;
static _KLused_libraryGVKe K16;
static _KLused_libraryGVKe K17;
static _KLused_libraryGVKe K18;
static _KLused_libraryGVKe K19;
static _KLused_libraryGVKe K20;
static _KLsymbolGVKd KJtight_;
static _KLbyte_stringGVKd_5 K22;
static _KLsimple_object_vectorGVKd_11 K23;

/* Indirection variables */

static D IKJtight_ = &KJtight_;

/* Variables */

D dfmc_harp_cg_moduleYdylan_userVdfmc_harp_cg = &Kdfmc_harp_cg_moduleYdylan_userVdfmc_harp_cg;
D dfmc_harp_cg_libraryYdylan_userVdfmc_harp_cg = &Kdfmc_harp_cg_libraryYdylan_userVdfmc_harp_cg;

/* Objects */

_KLlibraryGVKe Kdfmc_harp_cg_libraryYdylan_userVdfmc_harp_cg = {
  &KLlibraryGVKeW /* wrapper */,
  &K5,
  (D) 1,
  (D) 1,
  (D) 129903765,
  &K6,
  &KPempty_vectorVKi,
  &KPfalseVKi,
  &KPempty_vectorVKi,
  (D) 5493,
  (D) 6469
};

_KLmoduleGVKe Kdfmc_harp_cg_moduleYdylan_userVdfmc_harp_cg = {
  &KLmoduleGVKeW /* wrapper */,
  &K5,
  &Kdfmc_harp_cg_libraryYdylan_userVdfmc_harp_cg
};

static _KLbyte_stringGVKd_12 K5 = {
  &KLbyte_stringGVKdW /* wrapper */,
  (D) 49,
  "dfmc-harp-cg"
};

static _KLsimple_object_vectorGVKd_14 K6 = {
  &KLsimple_object_vectorGVKdW /* wrapper */,
  (D) 57,
  &K7,
  &K8,
  &K9,
  &K10,
  &K11,
  &K12,
  &K13,
  &K14,
  &K15,
  &K16,
  &K17,
  &K18,
  &K19,
  &K20
};

static _KLused_libraryGVKe K7 = {
  &KLused_libraryGVKeW /* wrapper */,
  (D) 1,
  (D) 1,
  (D) 129950229,
  &Kmnemonic_assembler_libraryYdylan_userVmnemonic_assembler,
  &KJtight_
};

static _KLused_libraryGVKe K8 = {
  &KLused_libraryGVKeW /* wrapper */,
  (D) 1,
  (D) 1,
  (D) 129700821,
  &Kharp_native_libraryYdylan_userVharp_native,
  &KJtight_
};

static _KLused_libraryGVKe K9 = {
  &KLused_libraryGVKeW /* wrapper */,
  (D) 1,
  (D) 1,
  (D) 129690453,
  &Kharp_cg_back_end_libraryYdylan_userVharp_cg_back_end,
  &KJtight_
};

static _KLused_libraryGVKe K10 = {
  &KLused_libraryGVKeW /* wrapper */,
  (D) 1,
  (D) 1,
  (D) 129422229,
  &Kdfmc_management_libraryYdylan_userVdfmc_management,
  &KJtight_
};

static _KLused_libraryGVKe K11 = {
  &KLused_libraryGVKeW /* wrapper */,
  (D) 1,
  (D) 1,
  (D) 128802773,
  &Kdfmc_typist_libraryYdylan_userVdfmc_typist,
  &KJtight_
};

static _KLused_libraryGVKe K12 = {
  &KLused_libraryGVKeW /* wrapper */,
  (D) 1,
  (D) 1,
  (D) 129095061,
  &Kdfmc_optimization_libraryYdylan_userVdfmc_optimization,
  &KJtight_
};

static _KLused_libraryGVKe K13 = {
  &KLused_libraryGVKeW /* wrapper */,
  (D) 1,
  (D) 1,
  (D) 129170325,
  &Kdfmc_conversion_libraryYdylan_userVdfmc_conversion,
  &KJtight_
};

static _KLused_libraryGVKe K14 = {
  &KLused_libraryGVKeW /* wrapper */,
  (D) 1,
  (D) 1,
  (D) 128659797,
  &Kdfmc_reader_libraryYdylan_userVdfmc_reader,
  &KJtight_
};

static _KLused_libraryGVKe K15 = {
  &KLused_libraryGVKeW /* wrapper */,
  (D) 1,
  (D) 1,
  (D) 128997685,
  &Kdfmc_back_end_libraryYdylan_userVdfmc_back_end,
  &KJtight_
};

static _KLused_libraryGVKe K16 = {
  &KLused_libraryGVKeW /* wrapper */,
  (D) 1,
  (D) 1,
  (D) 128793621,
  &Kdfmc_core_libraryYdylan_userVdfmc_core,
  &KJtight_
};

static _KLused_libraryGVKe K17 = {
  &KLused_libraryGVKeW /* wrapper */,
  (D) 9,
  (D) 5,
  (D) 128648757,
  &Kbig_integers_libraryYdylan_userVbig_integers,
  &KJtight_
};

static _KLused_libraryGVKe K18 = {
  &KLused_libraryGVKeW /* wrapper */,
  (D) 9,
  (D) 5,
  (D) 128021525,
  &Kio_libraryYdylan_userVio,
  &KJtight_
};

static _KLused_libraryGVKe K19 = {
  &KLused_libraryGVKeW /* wrapper */,
  (D) 1,
  (D) 1,
  (D) 128002773,
  &Kcommon_dylan_libraryYdylan_userVcommon_dylan,
  &KJtight_
};

static _KLused_libraryGVKe K20 = {
  &KLused_libraryGVKeW /* wrapper */,
  (D) 9,
  (D) 5,
  (D) 128132821,
  &Kdylan_libraryYdylan_userVdylan,
  &KJtight_
};

static _KLsymbolGVKd KJtight_ = {
  &KLsymbolGVKdW /* wrapper */,
  &K22
};

static _KLbyte_stringGVKd_5 K22 = {
  &KLbyte_stringGVKdW /* wrapper */,
  (D) 21,
  "tight"
};

static _KLsimple_object_vectorGVKd_11 K23 = {
  &KLsimple_object_vectorGVKdW /* wrapper */,
  (D) 45,
  &KLdummy_harp_back_endGVdfmc_harp_cg,
  &KLruntime_objectGVdfmc_harp_cg,
  &KLdood_runtime_objectGVdfmc_harp_cg,
  &KLlocal_runtime_objectGVdfmc_harp_cg,
  &KLc_runtime_objectGVdfmc_harp_cg,
  &KLdood_runtime_object_proxyGVdfmc_harp_cg,
  &KLdylan_objectGVdfmc_harp_cg,
  &KLcg_multiple_valuesGVdfmc_harp_cg,
  &KLtest_resultGVdfmc_harp_cg,
  &KLcg_registerGVdfmc_harp_cg,
  &KLsymbol_objectGVdfmc_harp_cg
};

/* Code */


/* SYSTEM INIT CODE */

void _Init_dfmc_harp_cg__X_harp_cg_library_for_system () {
  extern D KPresolve_symbolVKiI(D);
  {
    D T0;

    T0 = KPresolve_symbolVKiI(&KJtight_);
    if (T0 != &KJtight_) {
      primitive_slot_value_setter(T0, &K7, 4);
      primitive_slot_value_setter(T0, &K8, 4);
      primitive_slot_value_setter(T0, &K9, 4);
      primitive_slot_value_setter(T0, &K10, 4);
      primitive_slot_value_setter(T0, &K11, 4);
      primitive_slot_value_setter(T0, &K12, 4);
      primitive_slot_value_setter(T0, &K13, 4);
      primitive_slot_value_setter(T0, &K14, 4);
      primitive_slot_value_setter(T0, &K15, 4);
      primitive_slot_value_setter(T0, &K16, 4);
      primitive_slot_value_setter(T0, &K17, 4);
      primitive_slot_value_setter(T0, &K18, 4);
      primitive_slot_value_setter(T0, &K19, 4);
      primitive_slot_value_setter(T0, &K20, 4);
    }
  }
  return;
}

/* USER INIT CODE */

void _Init_dfmc_harp_cg__X_harp_cg_library_for_user () {
{
  D T0;

  T0 = Kinitialize_class_dispatch_keys_vectoredVKgI(&K23);
  goto I0;
}
I0:

{
  D T0;

  T0 = &KPfalseVKi;
  goto I1;
}
I1:

{
  D T0;
  D T1;

  // /Users/bruce/Development/dylan/opendylan/sources/dfmc/harp-cg/harp-cg-library.dylan:8
  T0 = primitive_runtime_module_handle();
  // /Users/bruce/Development/dylan/opendylan/sources/dfmc/harp-cg/harp-cg-library.dylan:8
  T1 = KPlibrary_version_checkVKeI(&Kdfmc_harp_cg_libraryYdylan_userVdfmc_harp_cg, T0);
  goto I2;
}
I2:

  return;
}


/* eof */
