onnxruntime
caf20d93 - Exclude BFloat16 CPU kernels from WebAssembly builds

Commit
78 days ago
Exclude BFloat16 CPU kernels from WebAssembly builds WebAssembly does not support bfloat16 types natively. This commit adds preprocessor guards (__wasm__ and __EMSCRIPTEN__) to exclude BFloat16 Gemm and MatMul kernels from WebAssembly builds. Changes: - Guard BFloat16 kernel declarations in cpu_execution_provider.cc - Guard BFloat16 kernel registrations in cpu_execution_provider.cc - Guard BFloat16 Gemm kernel and implementation in gemm.cc - Guard BFloat16 MatMul kernel in matmul.cc - Guard BFloat16 Gemm and MatMul implementations in math_cpu.cc This follows the existing pattern used throughout the codebase for WebAssembly-specific code exclusion (see profiler.h, threadpool.cc, etc.) and prevents build failures when compiling for WebAssembly platforms.
Author
Gemini
Parents
Loading