Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions maul/renamed/src/cpu.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
#ifndef @OPT@_SRC_CPU_H
#define @OPT@_SRC_CPU_H

#include "@LIB@/base.h"

#include <stdbool.h>

// The backend the library's vector code was built for: "avx2", "neon"
Expand All @@ -17,13 +19,13 @@ const char* @P@GetSimdBackend(void);

// Whether this CPU runs the built backend.
// NOLINTNEXTLINE(readability-redundant-declaration): base.h may declare it
bool @P@IsCpuBackendSupported(void);
@PP@_NODISCARD bool @P@IsCpuBackendSupported(void);

// The CPU check without a world: stores the backend's name in *backend
// when backend is not null and returns whether this CPU runs it (when it
// does not, the build should be configured scalar). Safe from any thread;
// it keeps no state.
// NOLINTNEXTLINE(readability-redundant-declaration): base.h may declare it
bool @P@CheckCpu(const char** backend);
@PP@_NODISCARD bool @P@CheckCpu(const char** backend);

#endif
Loading