Files
core_zero/tjp/core/system/Optimization.h
Timothy Prepscius 996151a56a flatten 20260225
2026-02-25 12:43:06 -05:00

27 lines
602 B
C

// License: Modified MIT (NON-AI)
// See the LICENSE file in the root directory for license information.
// Copyright 2025 Timothy Prepscius
#pragma once
#include "System.h"
#ifdef COMPILER_LLVM
#define LLVM_NO_OPTIMIZATION_FUNCTION __attribute__ ((optnone))
#else
#define LLVM_NO_OPTIMIZATION_FUNCTION
#endif
#ifdef COMPILER_GCC
#define GCC_NO_OPTIMIZATION_BLOCK_BEGIN \
#pragma GCC push_options \
#pragma GCC optimize ("O0") \
#define GCC_NO_OPTIMIZATION_BLOCK_END \
#pragma GCC pop_options
#else
#define GCC_NO_OPTIMIZATION_BLOCK_BEGIN
#define GCC_NO_OPTIMIZATION_BLOCK_END
#endif