MetalLibraryExplorer
Parse and disassemble .metallib files in browser. https://yuao.github.io/MetalLibraryExplorer
This is a WebAssembly port of MetalLibraryArchive. In order to use this tool your browser must support WebAssembly.
Features
-
Inspect
.metallib
files. Get information about library type, target platform, Metal functions, etc. -
Disassemble Metal function bitcode.
-
Download Metal bitcode and assembly as a zip archive.
Technologies
Metal Library Archive Parser
The parser uses a WebAssembly version of the MetalLibraryArchive core library, built with SwiftWasm.
wasmer-js is used as WASI polyfill. However due to wasmer/issues/2792, the parser has to run in a Web Worker.
wasm-strip
from WABT and wasm-opt
from binaryen are used mainly to reduce the .wasm
binary size.
LLVM Disassembler
llvm-dis is used to convert the Metal bitcode into human-readable LLVM assembly language. This is also compiled to WebAssembly using this workflow.
User Interface
The UI is built with React and tailwindcss
Zip Archive & File Download
Building
To build this library you will need to have installed in your system:
Build
npm install
npm run build
Develop
npm install
npm run start
.metallib
Files
More About See MetalLibraryArchive.