Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • mesa mesa
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 3,059
    • Issues 3,059
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 997
    • Merge requests 997
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • MesaMesa
  • mesamesa
  • Merge requests
  • !7047

iris: Enable clover support with an environment variable

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Faith Ekstrand requested to merge gfxstrand/mesa:review/iris-clover into master Oct 07, 2020
  • Overview 12
  • Commits 5
  • Pipelines 12
  • Changes 10

This commit enables clover support for iris. It is intended as a compiler developer tool and not as a new OpenCL implementation from Intel. If you want competent OpenCL, we have a different open-source driver for that built on our LLVM-based IGC compiler stack. However, using clover with iris is becoming increasingly useful as a compiler development tool and I'm getting tired of carrying the patches in a private branch.

By default, clover will not initialize on iris. To enable clover, set the IRIS_ENABLE_CLOVER environment variable to "1" or "true". As we've done with the semi-sketchy platform support in ANV, it dumps a very loud WARNING to stderr when enabled. Use at your own risk.

NOTE: To anyone intending to benchmark this, the performance is going to be terrible and that is expected. This is in no way representative of the Intel/NIR compiler stack. As it currently stands, clover passes -O0 to clang when compiling OpenCL C to make SPIRV-LLVM-Transator work. When compiling the SPIR-V, clover currently doesn't run any NIR optimizations before it lowers memory access so any NIR optimizations iris attempts to do are severely hampered. One day, clover will get a NIR optimization loop or the ability to hand things off to the driver per-lowering but today is not that day.

Edited Oct 07, 2020 by Faith Ekstrand
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: review/iris-clover