# Meetily GPU Acceleration: How to Build with CUDA, Vulkan, or Metal Support

> Explore Meetily GPU acceleration options: build with CUDA, Vulkan, or Metal support using Cargo feature flags. Accelerate your projects on macOS, Windows, and Linux.

- Repository: [Zackriya Solutions/meetily](https://github.com/Zackriya-Solutions/meetily)
- Tags: how-to-guide
- Published: 2026-07-10

---

**Meetily supports three GPU acceleration backends—Metal for macOS, CUDA for NVIDIA GPUs on Windows/Linux, and Vulkan for AMD/Intel on Linux—controlled via Cargo feature flags at build time.**

Meetily’s transcription engine leverages Rust-based Whisper integration to offload inference from CPU to GPU. By compiling the appropriate backend feature into the Tauri desktop application, you can significantly reduce transcription latency depending on your hardware platform.

## Available GPU Acceleration Backends in Meetily

The `whisper_engine` crate in [`frontend/src-tauri/src/whisper_engine/acceleration.rs`](https://github.com/Zackriya-Solutions/meetily/blob/main/frontend/src-tauri/src/whisper_engine/acceleration.rs) abstracts three hardware acceleration APIs:

- **Metal + Core ML**: Automatically enabled on macOS 13+ builds with no additional Cargo flags required.
- **CUDA**: NVIDIA GPU support for Windows and Linux, enabled via the `cuda` feature flag.
- **Vulkan**: Cross-platform graphics API for AMD/Intel GPUs on Linux, enabled via the `vulkan` feature flag.

Each backend implementation lives in the acceleration module, providing a unified interface that maps to device-specific inference engines.

## Build Configuration and Cargo Features

GPU support is gated through Cargo features defined in [`frontend/src-tauri/Cargo.toml`](https://github.com/Zackriya-Solutions/meetily/blob/main/frontend/src-tauri/Cargo.toml). The workspace uses conditional compilation to pull in the appropriate GPU runtime libraries:

```toml
[features]
default = []                     # CPU-only build

cuda = ["whisper_engine/cuda"]   # Enable NVIDIA CUDA

vulkan = ["whisper_engine/vulkan"] # Enable Vulkan (Linux/Windows)

```

When you compile with a specific feature, the build system links against the corresponding GPU runtime (CUDA Toolkit or Vulkan SDK) and configures the engine factory to attempt GPU initialization before falling back to CPU.

### Building with CUDA Support (NVIDIA)

For NVIDIA GPUs on Windows or Linux, compile with the `cuda` feature:

```bash
RUST_LOG=debug cargo tauri build --features cuda

```

This command instructs the compiler to include the `CudaEngine` variant in `whisper_engine::load_model`. The build requires the NVIDIA CUDA Toolkit installed and `nvcc` accessible in your PATH.

### Building with Vulkan Support (AMD/Intel)

For AMD or Intel GPUs on Linux, use the `vulkan` feature flag:

```bash
RUST_LOG=debug cargo tauri build --features vulkan

```

This enables the `VulkanEngine` backend. Ensure you have the Vulkan Loader and appropriate Mesa or AMD GPU drivers installed on your system.

### Metal Support on macOS

Metal acceleration requires no manual feature flags. When building on macOS 13 or later, the `whisper_engine` automatically includes `MetalEngine` support via Core ML. Simply run:

```bash
cargo tauri build

```

The runtime detects macOS at compile-time using `cfg!(target_os = "macos")` and initializes the Metal backend when loading models.

### CPU-Only Fallback

To force a CPU-only build—useful for CI environments or machines without GPU drivers—disable default features:

```bash
cargo tauri build --no-default-features

```

This excludes all GPU backends and statically links only the `CpuEngine` implementation.

## Runtime Selection and Fallback Logic

The runtime selection logic in [`frontend/src-tauri/src/whisper_engine/whisper_engine.rs`](https://github.com/Zackriya-Solutions/meetily/blob/main/frontend/src-tauri/src/whisper_engine/whisper_engine.rs) handles backend initialization automatically. When you invoke `load_whisper_model` from the frontend, the engine executes the following sequence:

1. **Platform Detection**: Checks `cfg!(target_os = "macos")`, `cfg!(target_os = "linux")`, or `cfg!(target_os = "windows")` at compile-time.
2. **Feature Flag Check**: Verifies which Cargo features (`cuda`, `vulkan`) were enabled during compilation.
3. **GPU Initialization**: Attempts to instantiate `CudaEngine`, `VulkanEngine`, or `MetalEngine` based on platform and available drivers.
4. **Graceful Degradation**: If GPU initialization fails (missing drivers, incompatible hardware), it automatically falls back to `CpuEngine`.

This design means you only need to specify the feature flag at build time; the application handles runtime detection and fallback without additional configuration.

## Verifying GPU Acceleration at Runtime

To confirm which backend is active, run the application with debug logging enabled:

```bash
RUST_LOG=whisper_engine=debug cargo tauri dev

```

Look for initialization messages in the console output:

```

[DEBUG] whisper_engine::acceleration] Using CUDA backend (GPU: NVIDIA RTX 3080)
[DEBUG] whisper_engine::acceleration] Using Metal backend (GPU: Apple M3)
[DEBUG] whisper_engine::acceleration] Falling back to CPU – no GPU detected

```

The frontend TypeScript API remains backend-agnostic. Regardless of the compilation target, you load models using the same command:

```typescript
await invoke('load_whisper_model', { modelName: 'base' });

```

## Summary

- **Metal** provides automatic GPU acceleration on macOS 13+ without build flags.
- **CUDA** requires `cargo tauri build --features cuda` for NVIDIA GPUs on Windows and Linux.
- **Vulkan** requires `cargo tauri build --features vulkan` for AMD/Intel GPUs on Linux.
- The acceleration logic in [`frontend/src-tauri/src/whisper_engine/whisper_engine.rs`](https://github.com/Zackriya-Solutions/meetily/blob/main/frontend/src-tauri/src/whisper_engine/whisper_engine.rs) handles runtime detection and automatic CPU fallback.
- All GPU backends are defined in [`frontend/src-tauri/src/whisper_engine/acceleration.rs`](https://github.com/Zackriya-Solutions/meetily/blob/main/frontend/src-tauri/src/whisper_engine/acceleration.rs) behind Cargo feature gates.

## Frequently Asked Questions

### Does Meetily support AMD GPUs on Windows?

Currently, the Vulkan backend is primarily tested and supported on Linux. Windows builds focus on CUDA for NVIDIA hardware. AMD support on Windows may require additional configuration of the Vulkan SDK and is not officially guaranteed in the current `whisper_engine` implementation.

### What happens if I build with CUDA but run on a machine without an NVIDIA GPU?

The application gracefully falls back to CPU inference. The `whisper_engine::load_model` function attempts to initialize `CudaEngine` first; if the CUDA runtime is unavailable or no compatible GPU is detected, it automatically instantiates `CpuEngine` without crashing or requiring user intervention.

### Can I switch between GPU and CPU mode at runtime without rebuilding?

No. GPU backends are compiled into the binary at build time via Cargo features. To change acceleration methods, you must recompile with the appropriate flags (e.g., switching from `--features cuda` to `--no-default-features`). Runtime selection only chooses among the backends that were included during compilation.

### Which GPU backend offers the best performance for transcription?

Performance depends on your specific hardware. Metal on Apple Silicon (M1/M2/M3) typically provides excellent efficiency through Core ML optimization. NVIDIA CUDA generally offers the highest throughput on desktop GPUs. Vulkan performance varies by driver quality on AMD/Intel Linux systems. Benchmark your specific model size (tiny, base, small) against your hardware to determine the optimal backend.