Skip to content

Vectorize HLO dialect dispatch regions #25

Closed

Description

@benvanik

To enable better SPIR-V and SIMD codegen we should vectorize dispatch regions. There's a vectorization transform in MLIR however it's specific to the affine dialect and not easily usable for our purposes - something much simpler would do, especially considering our starting point with variable-width vector HLO ops.

Input:

  %c = xla_hlo.mul %a, %b : tensor<1024xf32>

Output:

  { iree.workload_divisor = {4, 4, 4} }
  %c = xla_hlo.mul %a, %b : tensor<4xf32>

We could do this as part of lowering to SPIR-V or SIMD directly however both would benefit and having a common path through the index map would be nice if we need to adjust that to take the divisors into account.

Activity

  1. added
    enhancement ➕
    on Oct 13, 2019
  2. added this to the milestone on Oct 13, 2019
  3. removed this from the milestone on Mar 19, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancement ➕

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions