Skip to content

bhouse-microsoft/VpuSimShaderCompiler

Repository files navigation

Introduction

This repository is intended to host the shader compiler to be used witht the Microsoft Compute Driver Model (MCDM) driver sample.

The shader compiler takes as input DXIL which is generated by the DXShaderCompiler and outputs bytecode. The shader compiler is being develeoped as a stand alone compiler but will eventually be incorporated into the MCDM driver sample at a later date.

The shader compiler is derived from LLVM 7.0.0 sources. This repository was created from the official LLVM repository at https://llvm.org/git/llvm. It is unlikely that we will merge any additional changes from LLVM.

Building

To build the compiler, we use the standard LLVM building steps.

Tool Chain Needed for build:

On a Windows 10 machine with Visual Studio 2017 and CMake 3.13.2, we follow these steps:

  • git clone -c core.autocrlf=false https://github.com/bhouse-microsoft/VpuSimShaderCompiler.git
  • cd VpuSimShaderCompiler
  • git checkout vpu
  • cd ..
  • mkdir VpuSimShaderCompiler.build32
  • cd VpuSimShaderCompiler.build32
  • cmake -DLLVM_TARGETS_TO_BUILD="X86" -DLLVM_OPTIMIZED_TABLEGEN=On path-to-repository -Thost=x64
  • cmake --build .
  • mkdir VpuSimShaderCompiler.build64
  • cd VpuSimShaderCompiler.build32
  • cmake -DLLVM_TARGETS_TO_BUILD="X86" -G "Visual Studio 15 2017 Win64" -DLLVM_OPTIMIZED_TABLEGEN=On path-to-repository -Thost=x64
  • cmake --build .

Configuring username

If you need to provide a different user name to submit changes to the repository, you can edit your .git/config adding the following:

[credential "https://github.com/bhouse-microsoft/VpuSimShaderCompiler.git"]
	useHttpPath = true
	helper = manager
	username = your-user-name