Skip to content

Replacing iree_vm_variant_list_t with iree_vm_list_t and improving the C++ ref<T> wrapper - #2558

Merged
benvanik merged 8 commits into
mainfrom
benvanik-cleanup-variant-list
Jul 20, 2020
Merged

benvanik merged 8 commits into
mainfrom
benvanik-cleanup-variant-list

Conversation

@benvanik

@benvanik benvanik commented Jul 17, 2020 •

Copy link
Copy Markdown
Collaborator

This extends iree_vm_list_t to be a superset of iree_vm_variant_list_t and swaps it into place. Now we only have a single list type that can be used for both the VM vm.list.* ops and interacting with the API. This also enables better variadic outputs from the VM as now it can return lists within lists.

Future changes will add more utilities to work with vm::ref (such as dereferencing an opaque ref) and convert more usage of raw VM types to use vm::ref.

@benvanik benvanik added the runtime Relating to the IREE runtime library label Jul 17, 2020
@benvanik benvanik added this to the 2020Q3 Core milestone Jul 17, 2020
@benvanik
benvanik force-pushed the benvanik-cleanup-variant-list branch 4 times, most recently from b52d3f6 to 3316a92 Compare July 17, 2020 06:27
@benvanik
benvanik marked this pull request as ready for review July 17, 2020 06:40
@benvanik
benvanik force-pushed the benvanik-cleanup-variant-list branch 2 times, most recently from 9318bb9 to 3b597f3 Compare July 17, 2020 16:05

@ScottTodd ScottTodd left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for keeping the chain of commits so clean!

Comment thread iree/vm/list.c Resolved
Comment thread bindings/python/pyiree/rt/vm.cc Resolved
benvanik added 6 commits July 20, 2020 11:57
These make it easier (though not yet easy enough) to access ref elements.
Though this (in theory) grows the ref<T> size by a word, that's fine. This
avoids a bunch of additional code that would have been required to convert
into and out-of the C handles.
@benvanik
benvanik force-pushed the benvanik-cleanup-variant-list branch from 3b597f3 to e55a734 Compare July 20, 2020 18:57
@benvanik
benvanik force-pushed the benvanik-cleanup-variant-list branch from e55a734 to 280b771 Compare July 20, 2020 19:27
@benvanik
benvanik merged commit ef26761 into main Jul 20, 2020
@benvanik
benvanik deleted the benvanik-cleanup-variant-list branch July 20, 2020 19:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

runtime Relating to the IREE runtime library

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants