jweinst1
5/11/2018 - 11:07 PM

This is a desing/mockup chart for the wind programming language

This is a desing/mockup chart for the wind programming language

# Design doc for mapping and other apply operations

* exec_map
   call equalize (active, alt)
   call reset alt
   = active_ptr
   = active_end
   
   * loop active
         # Args to map that have been loaded
         = load_ptr
         = load_end
         
         * loop load
               switch (deref load)
                   -> <sym>:
                        call_apply [sym, 
                                        dest: alt_buf
                                        src: const active_ptr
                                        ins: const load_ptr]
        * end loop
        inc active_ptr
   * end loop
   
   call swap_buf active, alt
   
   
done