iree/tools/iree-e2e-matmul-test.c
static iree_status_t allocate_buffer_like(iree_hal_allocator_t* hal_allocator,
                                          iree_hal_buffer_view_t* src,
                                          iree_hal_buffer_view_t** dst) {
  return iree_hal_buffer_view_allocate_buffer(
      hal_allocator, iree_hal_buffer_view_shape_dims(src),
      iree_hal_buffer_view_shape_rank(src),
      iree_hal_buffer_view_element_type(src),
      iree_hal_buffer_view_encoding_type(src),
      IREE_HAL_MEMORY_TYPE_HOST_LOCAL | IREE_HAL_MEMORY_TYPE_DEVICE_VISIBLE,
      IREE_HAL_BUFFER_USAGE_ALL, iree_const_byte_span_empty(), dst);
}
// Allocates |dst| to have the same shape as |src|, without copying contents.
Allocates |dst| to have the same shape as |src|, without copying contents.
Allocates |dst| to have the same shape as |src| without copying contents .
static iree_status_t allocate_buffer_like(iree_hal_allocator_t* hal_allocator,
                                          iree_hal_buffer_view_t* src,
                                          iree_hal_buffer_view_t** dst) {
  return iree_hal_buffer_view_allocate_buffer(
      hal_allocator, iree_hal_buffer_view_shape_dims(src),
      iree_hal_buffer_view_shape_rank(src),
      iree_hal_buffer_view_element_type(src),
      iree_hal_buffer_view_encoding_type(src),
      IREE_HAL_MEMORY_TYPE_HOST_LOCAL | IREE_HAL_MEMORY_TYPE_DEVICE_VISIBLE,
      IREE_HAL_BUFFER_USAGE_ALL, iree_const_byte_span_empty(), dst);
}
static iree_status_t allocate_buffer_like ( iree_hal_allocator_t * hal_allocator , iree_hal_buffer_view_t * src , iree_hal_buffer_view_t * * dst ) { return iree_hal_buffer_view_allocate_buffer ( hal_allocator , iree_hal_buffer_view_shape_dims ( src ) , iree_hal_buffer_view_shape_rank ( src ) , iree_hal_buffer_view_element_type ( src ) , iree_hal_buffer_view_encoding_type ( src ) , IREE_HAL_MEMORY_TYPE_HOST_LOCAL | IREE_HAL_MEMORY_TYPE_DEVICE_VISIBLE , IREE_HAL_BUFFER_USAGE_ALL , iree_const_byte_span_empty ( ) , dst ) ; }
Allocates |dst| to have the same shape as |src|, without copying contents.
Allocates |dst| to have the same shape as |src| without copying contents .