/* * File: simd/basic_simd.hpp * Purpose: Basic SIMD backend C++ library. * Author: Amlal El Mahrouss (founder@snu.systems) * Copyright 2025, Amlal El Mahrouss, and SNU Systems, Corp, licensed under the BSL 1.0 license. */ #pragma once #include #include #ifdef __x86_64__ #include using simd_type = __m256; #endif #ifdef __aarch64__ #include using simd_type = float32x4_t; #endif namespace scl::snu::simd { struct basic_simd_backend final { struct simd_traits final { simd_type __val; private: static bool bad; friend class basic_simd_backend; }; using register_type = simd_traits; const bool& is_bad() noexcept { return register_type::bad; } std::basic_string isa() { return "basic-backend"; } }; } // namespace scl::snu::simd