checkpoint before deleting Node/Link opting instead for latent link
authorThomas Walker Lynch <eknp9n@reasoningtechnology.com>
Mon, 10 Mar 2025 09:09:07 +0000 (09:09 +0000)
committerThomas Walker Lynch <eknp9n@reasoningtechnology.com>
Mon, 10 Mar 2025 09:09:07 +0000 (09:09 +0000)
developer/cc馃枆/Core.lib.c

index 4e05a7f..3be49b7 100644 (file)
@@ -3,7 +3,7 @@
 
   'ATP'  Used in comments. 'At This Point' in the code. 
 
-  'Area' refers to an area (in contrast to a point) in the address space.
+  'Tape' refers to an tape (in contrast to a point) in the address space.
 
    A non-exist array is said to be non-existent.
    An array with zero elements has 'length == 0' or is 'empty'.
@@ -13,6 +13,9 @@
    It is better to separate the tableau than have a union, and let the
    optimizer figure out the memory life times, and what can be reused.
 
+   Nodes include neighbor links, that makes traversal more efficient.
+
+
 */
 
 #define Core路DEBUG
   #include <stdint.h>
   #include <stddef.h>
 
-  #define extentof(x)(sizeof(x) - 1)
-  #define extent_t size_t
+  //----------------------------------------
+  // fundamental
+
+    #define extentof(x)(sizeof(x) - 1)
+    #define extent_t size_t
+
+    // AU == Addressable Unit
+    // given an AU is an 8 bit byte, 4AU is 32 bits, and 8 AU is 64 bits.
+    #define AU uint8_t;
+
+    void *offset(void *p ,size_t 螖);
+    void *offset_8AU(void *p ,size_t 螖);
+    bool is_aligned_8AU(void *p);
+
+    // given an 8AU aligned window, return the AU pointer to the least and greatest index
+    void *floor_within_aligned_8AU(void *p);
+    void *ceiling_within_aligned_8AU(void *p);
+
+  //----------------------------------------
+  // Sequencer
+
+    typedef struct Core路Node;
+
+    typedef Core路Node *(*Core路Function)(Core路Node *node);
+
+    typedef struct{
+      Core路Function function;
+    } Core路Node;
+
+    void call(Core路Node *node){
+      while(node) node = node->function(node));
+    }
+
+  //----------------------------------------
+  // Tape Machine
+
+    // tape
+
+    typedef struct{
+      uint8_t *position;
+      extent_t extent;
+    } Core路Area;
+
+    // tape machine
+
+    typedef struct{
+      Core路Area *tape;
+      AU *hd;
+    } Core路TM;
+
+    // Step
+
+    typedef struct{
+      Core路Node node;
+      Core路Node *next;
+      Core路TM *tm;
+    } Core路Step路Node;
+
+    Local Node *Core路step_AU(Node *node){
+      Core路Step路Node *step_node = (Core路Step路Node *)node;
+      step_node->hd = Core路offset(step_node->tm->hd ,1);
+      return node->next;
+    }
+
+    Local Node *Core路step_8AU(Node *node){
+      Core路Step路Node *step_node = (Core路Step路Node *)node;
+      step_node->hd = Core路offset_8AU(step_node->tm->hd ,1);
+      return node->next;
+    }
+
+    // Status
+
+    typedef struct{
+      Core路Node node;
+      Core路Node *not_on_tape;
+      Core路Node *interim;
+      Core路Node *rightmost;
+      Core路TM *tm;
+    } Core路Status路Node;
+
+    // Copy Cell
+
+    typedef struct{
+      Core路Node node;
+      Core路Node *not_on_tape;
+      Core路Node *interim;
+      Core路Node *rightmost;
+      Core路TM *tm;
+    } Core路CopyCell路Node;
+
+    uint8_t Area路read_8_zero(Core路Area *area ,void *r);
+    uint8_t Area路read_8_fwd(Core路Area *area ,void *r);
+    uint8_t Area路read_8_rev(Core路Area *area ,uint8_t *r);
+
+typedef struct{
+  Core路TM read;
+  Core路TM write;
+  Core路Function init;
+  Core路Function copy_cell;
+  Core路Function step;
+  Core路Function status;
+} Core路Copy路Tableau
+
+
+
+
+// wire these in advance, on the tableau, then insert critical functions before call
+void wire_loop_AU(Core路TM *tm_read ,Core路TM *tm_write){
+  CopyCell路Node copy_cell;
+
+  Status路Node read_status_node;
+
+  Step路Node read_step_node;
+  Step路Node write_step_node;
+
+  copy_cell.node.function = Core路copy_AU;
+  copy_cell.next = &read_status_node;
+
+  read_status.node.function = Core路status;
+  read_status.not_on_tape = NULL; // needs to be an error node
+  read_status.interim = &step_node;
+  read_status.rightmost = NULL;
+  
+  read_step_node.node.function = Core路stepAU;
+  read_step_node.next = &write_step_node;
+
+  write_step_node.node.function = Core路stepAU;
+  write_step_node.next = &write_step_node;
+
+}
+
+  //----------------------------------------
+  // Tape
+
+    typedef struct Core路Area;
+
+    typedef enum {
+      Core路Area路Topology路nonexistent  // TapeMachine is unmounted (tape pointer is NULL)
+      ,Core路Area路Topology路empty       // Tape exists but contains no elements (extent == 0)
+      ,Core路Area路Topology路singleton   // Tape has exactly one element (extent == 1)
+      ,Core路Area路Topology路finite      // Tape has a fixed, finite length (extent > 1)
+      ,Core路Area路Topology路unbounded   // Tape conceptually extends infinitely
+      ,Core路Area路Topology路cycles      // Tape has a repeating pattern but no explicit wraparound
+      ,Core路Area路Topology路circular    // Tape is explicitly circular (head can wrap around)
+    } Core路Area路Topology;
+
+    typedef struct{
+      Core路Area.Topology (*topology)(Tape *tape);
+    } Core路Area路M
+
+    typedef struct{
+      Core路Area路M tape_m;
+      void init_ppe(Core路Area *area ,void *position ,extent_t extent);
+      void init_pp(Core路Area *area ,void *position_left ,void *position_right);
+      void set_position(Core路Area *area ,uint8_t *new_position);
+      void set_position_left(Core路Area *area ,uint8_t *new_position); // synonym
+      extent_t set_extent(Core路Area *area);
+      void set_position_right(Core路Area *area ,uint8_t *new_position_right);
+
+      // read area properties
+      bool empty(Core路Area *area);
+      uint8_t *position(Core路Area *area);
+      uint8_t *position_left(Core路Area *area); // synonym
+      uint8_t *position_right(Core路Area *area);
+      extent_t extent(Core路Area *area);
+      uint8_t length_Kung(Core路Area *area); // saturates at 3
+
+      // area relationships
+      bool encloses_pt(uint8_t *pt ,Core路Area *area);
+      bool encloses_pt_strictly(uint8_t *pt ,Core路Area *area);
+      bool encloses_area(Core路Area *outer ,Core路Area *inner);
+      bool encloses_area_strictly(Core路Area *outer ,Core路Area *inner);
+      bool overlap(Core路Area *a ,Core路Area *b);
+      void largest_aligned_64(Core路Area *outer ,Core路Area *inner_64);
+      uint8_t *complement(Core路Area *area ,uint8_t *r);
+    } Core路Area路M
+
+
+
+
+
+typedef enum {
+  Core路Head路Status路uinitialied 
+  ,Core路Head路Status路debug
+  ,Core路Head路Status路production
+} Core路Head路Status;
+
+typedef struct{
+  Core路Node parent;
+  uint8_t *pt;
+} Core路Node路Head;
+
+
+
+
+Local路Topology Area路topology_byte_array(Area *area){
+  if(!area) return Core路Area路Topology路nonexistent;
+  if(!area->position) return Core路Area路Topology路empty;
+  if(area->extent == 0) return Core路Area路Topology路singleton;
+  return Core路Area路Topology路finite;
+}
 
-  typedef struct Core路Area;
 
   typedef uint8_t (*ReadFn8)(Area * ,uint8_t *);
   typedef uint64_t (*ReadFn64)(Area * ,uint64_t *);
 
+  typedef enum {
+    Core路Copy路Read路Status路argument_guard=0     // No data available (invalid read)
+    ,Core路Copy路Read路Status路empty     // No data available (invalid read)
+    ,Core路Copy路Read路Status路singleton // Only one value exists
+    ,Core路Copy路Read路Status路first     // First value in a sequence
+    ,Core路Copy路Read路Status路interim   // Not first, not last  
+    ,Core路Copy路Read路Status路last       // Last value in a sequence
+  } Core路Copy路Read路Status;
+
   typedef enum{
-    ,Core路Copy路Status路uninitialied = 0
+    Core路Copy路Status路uninitialized = 0
     ,Core路Copy路Status路argument_guard = 1
     ,Core路Copy路Status路perfect_fit = 2
     ,Core路Copy路Status路read_surplus = 4
     ,Core路Copy路Status路read_surplus_write_gap = 8
     ,Core路Copy路Status路write_available = 16
     ,Core路Copy路Status路write_gap = 32
-  }Core路Copy路Status;
+  } Core路Copy路Status;
+
+
+
 
   struct{
     struct{
       Core路Copy路Status status;
     }copy;
   } Core路TableauFace
-  Core路TableauFace tf;
+  Core路TableauFace Core路tf;
 
   typedef Core路Copy路Fn (*Core路Copy路Fn)();
 
     void *ceiling_64(void *p);
 
     // initialize an area
-    void Area路init_pe(Core路Area *area ,void *position ,extent_t extent);
-    void Area路init_pp(Core路Area *area ,void *position_left ,void *position_right);
-    void Area路set_position(Core路Area *area ,uint8_t *new_position);
-    void Area路set_position_left(Core路Area *area ,uint8_t *new_position); // synonym
-    extent_t Area路set_extent(Core路Area *area);
-    void Area路set_position_right(Core路Area *area ,uint8_t *new_position_right);
-
-    // read area properties
-    bool Area路empty(Core路Area *area);
-    uint8_t *Area路position(Core路Area *area);
-    uint8_t *Area路position_left(Core路Area *area); // synonym
-    uint8_t *Area路position_right(Core路Area *area);
-    extent_t Area路extent(Core路Area *area);
-    uint8_t Area路length_Kung(Core路Area *area); // saturates at 3
-
-    // area relationships
-    bool Area路encloses_pt(uint8_t *pt ,Core路Area *area);
-    bool Area路encloses_pt_strictly(uint8_t *pt ,Core路Area *area);
-    bool Area路encloses_area(Core路Area *outer ,Core路Area *inner);
-    bool Area路encloses_area_strictly(Core路Area *outer ,Core路Area *inner);
-    bool Area路overlap(Core路Area *a ,Core路Area *b);
-    void Area路largest_aligned_64(Core路Area *outer ,Core路Area *inner_64);
-    uint8_t *Area路complement(Core路Area *area ,uint8_t *r);
 
     // read from an area
     uint8_t Area路read_8_zero(Core路Area *area ,void *r);
     uint8_t hex_to_byte(uint16_t hex);
 
     // copy one area to another, possibly with a transformation
-    Copy路Status Core路copy(Core路Copy路Fn fn ,Core路TableauFace *ap);
+    Copy路Status Core路copy(Core路Copy路Fn fn);
     Copy路Fn Copy路byte_by_byte;
     Copy路Fn Copy路by_word_64;
     Copy路Fn Copy路write_hex;
     typedef struct{
       uint8_t *position;
       extent_t extent;
-    } Core路Area
+    } Core路Area;
 
     // I removed the unions, as they are debugging hazards, and also might confuse the optimizer
     typedef struct{
         struct{
-          ReadFn8 read_fn;
         } byte_by_byte;
         struct{
-          ReadFn64 read_fn;
           Area area_64;
         } copy_64;
         struct{
-          uint8_t (*hex_to_byte)(uint16_t);
         } read_hex;
         struct{
-          uint16_t (*byte_to_hex)(uint8_t);
         } write_hex;
     } Core路TableauLocal;
 
       return 0;
     }
 
+    Local uint8_t Core路Area路read_8_fwd(){
+      Core路Area a = Core路tf.read;
+      uint8_t **r = &Core路tf.read_pt;
+
+      #ifdef Core路Debug
+        if(!a || !*r){
+          fprintf(stderr ,"Core路Area路read_8_fwd:: read read_pt: %p %p\n" ,a ,*r); 
+          return Core路Copy路Read路Status路argument_guard;
+        }
+        if( !Core路Area路enclose_pt(area ,r) ){
+          fprintf(stderr,"Core路Area路read_8_fwd:: out of interval read\n");
+        }
+      #endif
+      return *(uint8_t *)r;
+    }
+
     Local uint8_t Core路Area路read_8_fwd(Core路Area *area ,void *r){
       #ifdef Core路Debug
       if(!area || !r){
       #ifdef Core路Debug
       if(!fn){
         fprintf(stderr,"Core路copy:: given null function");
-        return Core路Copy路argument_guard
+        return Core路Copy路argument_guard;
       }
       if(
          true
          && fn != Core路read_hex
       ){
         fprintf(stderr,"Core路copy:: unrecognized copy function\n");
-        return Core路Copy路argument_guard
+        return Core路Copy路argument_guard;
       ) 
       #endif
 
       while(fn) fn = fn();
-      return tableau->status;
+      return tf.copy.status;
     }
 
     //----------------------------------------
     // copy byte_by_byte 
 
-    Core路Copy路Fn Core路Copy路byte_by_byte;
-    Core路Copy路Fn Core路Copy路Copy8路bulk;
+    Core路Copy路Fn Core路Copy路Copy路ByteByByte路perfect_fit;
+    Core路Copy路Fn Core路Copy路Copy路ByteByByte路read_surplus;
+    Core路Copy路Fn Core路Copy路Copy路ByteByByte路write_available;
 
     Local Core路Copy路Fn Core路Copy路byte_by_byte(){
       if(Core路Area路extent(Core路tf.copy.read) == Core路Area路extent(Core路tf.copy.write))
-        return Core路Copy8路perfect_fit;
+        return Core路Copy路ByteByByte路perfect_fit;
 
       if(Core路Area路extent(Core路tf.copy.read) > Core路Area路extent(Core路tf.copy.write))
-        return Core路Copy8路read_surplus;
+        return Core路Copy路ByteByByte路read_surplus;
 
-      return Core路Copy8路write_available;
+      return Core路Copy路ByteByByte路write_available;
     }
 
-    Core路Copy路Fn Core路Copy路byte_by_byte;
-    Core路Copy路Fn Core路Copy路Copy8路bulk;
-
-    Local Core路Copy路Fn Core路Copy路byte_by_byte(){
-      if(Core路Area路extent(Core路tf.copy.read) == Core路Area路extent(Core路tf.copy.write)){
-        return Core路Copy8路perfect_fit;
-      }
-      if(Core路Area路extent(Core路tf.copy.read) > Core路Area路extent(Core路tf.copy.write)){
-        return Core路Copy8路read_surplus;
-      }
-      return Core路Copy8路write_available;
-    }
-
-    Local Core路Copy路Fn Core路Copy8路perfect_fit(){
+    Local Core路Copy路Fn Core路Copy路ByteByByte路perfect_fit(){
       uint8_t **r = &Core路tf.copy.read_pt;
       uint8_t *r1 = Core路Area路position_right(Core路tf.copy.read);
       uint8_t **w = &Core路tf.copy.write_pt;
 
       do{
-        **w = Core路tf.copy.read_fn_8(Core路tf.copy.read ,r1 ,*r);
+        **w = Core路tf.copy.read_fn_8(Core路tf.copy.read ,*r);
         if(*r == r1) break;
         (*r)++;
         (*w)++;
       return NULL;
     }
 
-    Local Core路Copy路Fn Core路Copy8路read_surplus(){
+    Local Core路Copy路Fn Core路Copy路ByteByByte路read_surplus(){
       uint8_t **r = &Core路tf.copy.read_pt;
       uint8_t *r1 = Core路Area路position_right(Core路tf.copy.read);
       uint8_t **w = &Core路tf.copy.write_pt;
+      uint8_t *w1 = Core路Area路position_right(Core路tf.copy.write);
 
       do{
-        **w = Core路tf.copy.read_fn_8(Core路tf.copy.read ,r1 ,*r);
-        if(*r == r1) break;
+        **w = Core路tf.copy.read_fn_8(Core路tf.copy.read ,*r);
+        if(*w == w1) break;
         (*r)++;
         (*w)++;
       }while(true);
 
-      Core路tf.copy.status = Core路Copy路Status路read_surplus;
+      Core路tf.copy.status = Core路Copy路Status路write_available;
       return NULL;
     }
 
-    Local Core路Copy路Fn Core路Copy8路write_available(){
+    Local Core路Copy路Fn Core路Copy路ByteByByte路write_avalable(){
       uint8_t **r = &Core路tf.copy.read_pt;
       uint8_t *r1 = Core路Area路position_right(Core路tf.copy.read);
       uint8_t **w = &Core路tf.copy.write_pt;
-      uint8_t *w1 = Core路Area路position_right(Core路tf.copy.write);
 
       do{
-        **w = Core路tf.copy.read_fn_8(Core路tf.copy.read ,r1 ,*r);
-        if(*w == w1) break;
+        **w = Core路tf.copy.read_fn_8(Core路tf.copy.read ,*r);
+        if(*r == r1) break;
         (*r)++;
         (*w)++;
       }while(true);
 
-      Core路tf.copy.status = Core路Copy路Status路write_available;
+      Core路tf.copy.status = Core路Copy路Status路read_surplus;
       return NULL;
     }
 
     //----------------------------------------
     // copy copy_64
 
-    //----------------------------------------
-    // copy copy_64
-
-    // 64-bit copy function with updated TableauFace terminology
-    Core路Copy路Fn Core路Copy路by_word_64;
-    Core路Copy路Fn Core路Copy64路leadin;
-    Core路Copy路Fn Core路Copy64路bulk;
-    Core路Copy路Fn Core路Copy64路tail;
-
-    //----------------------------------------
-    // copy copy_64
-
     // 64-bit copy function with updated TableauFace terminology
     Core路Copy路Fn Core路Copy路by_word_64;
-    Core路Copy路Fn Core路Copy64路leadin;
-    Core路Copy路Fn Core路Copy64路bulk;
-    Core路Copy路Fn Core路Copy64路tail;
+    Core路Copy路Fn Core路Copy路ByWord64路leadin;
+    Core路Copy路Fn Core路Copy路ByWord64路bulk;
+    Core路Copy路Fn Core路Copy路ByWord64路tail;
 
     // Initialize the copy_64 process
     Local Core路Copy路Fn Core路Copy路by_word_64(){
       Core路Area路largest_aligned_64(Core路tf.copy.read ,&Core路tl.copy_64.area_64);
 
       // Choose the correct function based on alignment
-      if(Core路Area路empty(&Core路tl.copy_64.area_64)) return Core路Copy64路tail;
-      if(Core路is_aligned_64(Core路Area路position(Core路tf.copy.read))) return Core路Copy64路bulk;
-      return Core路Copy64路leadin;
+      if(Core路Area路empty(&Core路tl.copy_64.area_64)) return Core路Copy路ByWord64路tail;
+      if(Core路is_aligned_64(Core路Area路position(Core路tf.copy.read))) return Core路Copy路ByWord64路bulk;
+      return Core路Copy路ByWord64路leadin;
     }
 
     // Lead-in byte copy (until alignment)
-    Local Core路Copy路Fn Core路Copy64路leadin(){
+    Local Core路Copy路Fn Core路Copy路ByWord64路leadin(){
       uint8_t **r = &Core路tf.copy.read_pt;
       uint8_t *r0_64 = Core路Area路position(&Core路tl.copy_64.area_64);
       uint8_t **w = &Core路tf.copy.write_pt;
         (*w)++;
       }while(true);
 
-      return Core路Copy64路bulk;
+      return Core路Copy路ByWord64路bulk;
     }
 
     // Bulk word copy
-    Local Core路Copy路Fn Core路Copy64路bulk(){
+    Local Core路Copy路Fn Core路Copy路ByWord64路bulk(){
       uint64_t **r = (uint64_t **)&Core路tf.copy.read_pt;
       uint64_t **w = (uint64_t **)&Core路tf.copy.write_pt;
       uint64_t *r1_64 = Core路Area路position_right(&Core路tl.copy_64.area_64);
         (*w)++;
       }while(true);
 
-      return Core路Copy64路tail;
+      return Core路Copy路ByWord64路tail;
     }
 
     // Tail byte copy (unaligned trailing bytes)
-    Local Core路Copy路Fn Core路Copy64路tail(){
+    Local Core路Copy路Fn Core路Copy路ByWord64路tail(){
       uint8_t **r = &Core路tf.copy.read_pt;
       uint8_t *r1 = Core路Area路position_right(&Core路tl.copy_64.area_64);
       uint8_t **w = &Core路tf.copy.write_pt;
 
     // Forward Declarations
     Core路Copy路Fn Core路Copy路write_hex;
-    Core路Copy路Fn Core路Copy路write_hex_bulk;
-    Core路Copy路Fn Core路Copy路write_hex_read_surplus;
-    Core路Copy路Fn Core路Copy路write_hex_write_available;
+    Core路Copy路Fn Core路Copy路WriteHex路perfect_fit;
+    Core路Copy路Fn Core路Copy路WriteHex路read_surplus;
+    Core路Copy路Fn Core路Copy路WriteHex路write_available;
 
     // Hex Encoding: Initialize Copy
     Local Core路Copy路Fn Core路Copy路write_hex(){
       if(Core路Area路extent(Core路tf.copy.read) == (Core路Area路extent(Core路tf.copy.write) >> 1)){
-        return Core路Copy路write_hex_bulk;
+        return Core路Copy路WriteHex路perfect_fit;
       }
       if(Core路Area路extent(Core路tf.copy.read) > (Core路Area路extent(Core路tf.copy.write) >> 1)){
-        return Core路Copy路write_hex_read_surplus;
+        return Core路Copy路WriteHex路read_surplus;
       }
-      return Core路Copy路write_hex_write_available;
+      return Core路Copy路WriteHex路write_available;
     }
 
-    // Hex Encoding: Bulk Processing (Perfect Fit)
-    Local Core路Copy路Fn Core路Copy路write_hex_bulk(){
+    Local Core路Copy路Fn Core路Copy路WriteHex路perfect_fit(){
       uint8_t **r = &Core路tf.copy.read_pt;
       uint8_t *r1 = Core路Area路position_right(Core路tf.copy.read);
       uint8_t **w = &Core路tf.copy.write_pt;
 
       do {
-        *(uint16_t *)*w = Core路tf.write_hex.byte_to_hex(**r);
+        *(uint16_t *)*w = Core路hex.byte_to_hex(**r);
         if(*r == r1) break;
         (*r)++;
         (*w) += 2;
     }
 
     // Hex Encoding: Read Surplus
-    Local Core路Copy路Fn Core路Copy路write_hex_read_surplus(){
+    Local Core路Copy路Fn Core路Copy路WriteHex路read_surplus(){
       uint8_t **r = &Core路tf.copy.read_pt;
       uint8_t *r1 = Core路Area路position_right(Core路tf.copy.write);
       uint8_t **w = &Core路tf.copy.write_pt;
 
       do {
-        *(uint16_t *)*w = Core路tf.write_hex.byte_to_hex(**r);
+        *(uint16_t *)*w = Core路write_hex.byte_to_hex(**r);
         if(*r == r1) break;
         (*r)++;
         (*w) += 2;
     }
 
     // Hex Encoding: Write Available
-    Local Core路Copy路Fn Core路Copy路write_hex_write_available(){
+    Local Core路Copy路Fn Core路Copy路WriteHex路write_available(){
       uint8_t **r = &Core路tf.copy.read_pt;
       uint8_t *r1 = Core路Area路position_right(Core路tf.copy.read);
       uint8_t **w = &Core路tf.copy.write_pt;
       uint8_t *w1 = Core路Area路position_right(Core路tf.copy.write);
 
       do {
-        *(uint16_t *)*w = Core路tf.write_hex.byte_to_hex(**r);
+        *(uint16_t *)*w = Core路write_hex.byte_to_hex(**r);
         if(*w == w1) break;
         (*r)++;
         (*w) += 2;
     }
 
     Core路Copy路Fn Core路Copy路read_hex;
-    Core路Copy路Fn Core路Copy路read_hex_bulk;
-    Core路Copy路Fn Core路Copy路read_hex_read_surplus;
-    Core路Copy路Fn Core路Copy路read_hex_write_available;
+    Core路Copy路Fn Core路Copy路ReadHex路perfect_fit;
+    Core路Copy路Fn Core路Copy路ReadHex路read_surplus;
+    Core路Copy路Fn Core路Copy路ReadHex路write_available;
 
     Local Core路Copy路Fn Core路Copy路read_hex(){
       if((Core路Area路extent(Core路tf.copy.read) >> 1) == Core路Area路extent(Core路tf.copy.write)){
-        return Core路Copy路read_hex_bulk;
+        return Core路Copy路ReadHex路perfect_fit;
       }
       if((Core路Area路extent(Core路tf.copy.read) >> 1) > Core路Area路extent(Core路tf.copy.write)){
-        return Core路Copy路read_hex_read_surplus;
+        return Core路Copy路ReadHex路read_surplus;
       }
-      return Core路Copy路read_hex_write_available;
+      return Core路Copy路ReadHex路write_available;
     }
 
-    // Hex Decoding: Bulk Processing (Perfect Fit)
-    Local Core路Copy路Fn Core路Copy路read_hex_bulk(){
+    Local Core路Copy路Fn Core路Copy路ReadHex路perfect_fit(){
       uint8_t **r = &Core路tf.copy.read_pt;
       uint8_t *r1 = Core路Area路position_right(Core路tf.copy.read);
       uint8_t **w = &Core路tf.copy.write_pt;
 
       do {
-        **w = Core路tf.read_hex.hex_to_byte(*(uint16_t *)*r);
+        **w = Core路hex_to_byte(*(uint16_t *)*r);
         if(*r == r1) break;
         (*r) += 2;
         (*w)++;
       return NULL;
     }
 
-    // Hex Decoding: Read Surplus
-    Local Core路Copy路Fn Core路Copy路read_hex_read_surplus(){
+    Local Core路Copy路Fn Core路Copy路ReadHex路read_surplus(){
       uint8_t **r = &Core路tf.copy.read_pt;
       uint8_t *r1 = Core路Area路position_right(Core路tf.copy.write);
       uint8_t **w = &Core路tf.copy.write_pt;
       return NULL;
     }
 
-    // Hex Decoding: Write Available
-    Local Core路Copy路Fn Core路Copy路read_hex_write_available(){
+    Local Core路Copy路Fn Core路Copy路ReadHex路write_available(){
       uint8_t **r = &Core路tf.copy.read_pt;
       uint8_t *r1 = Core路Area路position_right(Core路tf.copy.read);
       uint8_t **w = &Core路tf.copy.write_pt;
       return NULL;
     }
 
-    //----------------------------------------
-    // Tableaux
-
-    Core路TableauFace tf = {
-       .Copy.read = NULL
-       ,Copy.write = NULL
-       ,Copy..read_fn_8 = read_8_fwd
-       ,Copy..read_fn_64 = read_64_fwd
-       ,Copy..read_pt = NULL
-       ,Copy..write_pt = NULL
-       ,Copy..status = Core路Copy路Status路uninitialied
-    }
-
     //----------------------------------------
     // copy read hex
 
     Core路Copy路Fn Core路Copy路read_hex;
-    Core路Copy路Fn Core路Copy路read_hex_bulk;
-    Core路Copy路Fn Core路Copy路read_hex_read_surplus;
-    Core路Copy路Fn Core路Copy路read_hex_write_available;
+    Core路Copy路Fn Core路Copy路ReadHex路perfect_fit;
+    Core路Copy路Fn Core路Copy路ReadHex路read_surplus;
+    Core路Copy路Fn Core路Copy路ReadHex路write_available;
 
     Local Core路Copy路Fn Core路Copy路read_hex(){
       if((Core路Area路extent(Core路tf.copy.read) >> 1) == Core路Area路extent(Core路tf.copy.write)){
-        return Core路Copy路read_hex_bulk;
+        return Core路Copy路ReadHex路perfect_fit;
       }
       if((Core路Area路extent(Core路tf.copy.read) >> 1) > Core路Area路extent(Core路tf.copy.write)){
-        return Core路Copy路read_hex_read_surplus;
+        return Core路Copy路ReadHex路read_surplus;
       }
-      return Core路Copy路read_hex_write_available;
+      return Core路Copy路ReadHex路write_available;
     }
 
-    // Hex Decoding: Bulk Processing (Perfect Fit)
-    Local Core路Copy路Fn Core路Copy路read_hex_bulk(){
+    Local Core路Copy路Fn Core路Copy路ReadHex路perfect_fit(){
       uint8_t **r = &Core路tf.copy.read_pt;
       uint8_t *r1 = Core路Area路position_right(Core路tf.copy.read);
       uint8_t **w = &Core路tf.copy.write_pt;
 
       do {
-        **w = Core路tf.read_hex.hex_to_byte(*(uint16_t *)*r);
+        **w = Core路hex_to_byte(*(uint16_t *)*r);
         if(*r == r1) break;
         (*r) += 2;
         (*w)++;
       return NULL;
     }
 
-    // Hex Decoding: Read Surplus
-    Local Core路Copy路Fn Core路Copy路read_hex_read_surplus(){
+    Local Core路Copy路Fn Core路Copy路ReadHex路read_surplus(){
       uint8_t **r = &Core路tf.copy.read_pt;
       uint8_t *r1 = Core路Area路position_right(Core路tf.copy.write);
       uint8_t **w = &Core路tf.copy.write_pt;
 
       do {
-        **w = Core路tf.read_hex.hex_to_byte(*(uint16_t *)*r);
+        **w = Core路hex_to_byte(*(uint16_t *)*r);
         if(*r == r1) break;
         (*r) += 2;
         (*w)++;
       return NULL;
     }
 
-    // Hex Decoding: Write Available
-    Local Core路Copy路Fn Core路Copy路read_hex_write_available(){
+    Local Core路Copy路Fn Core路Copy路ReadHex路write_available(){
       uint8_t **r = &Core路tf.copy.read_pt;
       uint8_t *r1 = Core路Area路position_right(Core路tf.copy.read);
       uint8_t **w = &Core路tf.copy.write_pt;
       uint8_t *w1 = Core路Area路position_right(Core路tf.copy.write);
 
       do {
-        **w = Core路tf.read_hex.hex_to_byte(*(uint16_t *)*r);
+        **w = Core路hex_to_byte(*(uint16_t *)*r);
         if(*w == w1) break;
         (*r) += 2;
         (*w)++;
     }
 
     //----------------------------------------
-    // Initialization Block
+    // Initialization Blocks
+
+    //----------------------------------------
+    // Tableaux
+
+    Core路TableauFace tf = {
+       .copy = {
+          .read = NULL
+          ,.write = NULL
+          ,.read_fn_8 = Core路Area路read_8_fwd
+          ,.read_fn_64 = Core路Area路read_64_fwd
+          ,.read_pt = NULL
+          ,.write_pt = NULL
+          ,.status = Core路Copy路Status路uninitialized
+       }
+    };
+
+    Core路TableauLocal tl = {
+      .copy_64 = {
+        .area_64 = {NULL ,0}
+      }
+    };
 
     Core路M m = {
       .Area路init_pe = Core路Area路init_pe
       ,.byte_to_hex = Core路byte_to_hex
       ,.hex_to_byte = Core路hex_to_byte
 
-      ,.Core路copy = Core路copy
+      ,.copy = Core路copy
       ,.Copy路byte_by_byte = Core路Copy路byte_by_byte
       ,.Copy路by_word_64 = Core路Copy路by_word_64
       ,.Copy路write_hex = Core路Copy路write_hex