2 * Copyright (C) 2024 Mikulas Patocka
4 * This file is part of Ajla.
6 * Ajla is free software: you can redistribute it and/or modify it under the
7 * terms of the GNU General Public License as published by the Free Software
8 * Foundation, either version 3 of the License, or (at your option) any later
11 * Ajla is distributed in the hope that it will be useful, but WITHOUT ANY
12 * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
13 * A PARTICULAR PURPOSE. See the GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License along with
16 * Ajla. If not, see <https://www.gnu.org/licenses/>.
24 typedef unsigned cpu_feature_mask_t
;
26 extern cpu_feature_mask_t cpu_feature_flags
;
36 cpu_feature_static_flags
= 0
37 #define ASM_INC_STATIC
42 #define cpu_feature_mask(feature) ((cpu_feature_mask_t)1 << (feature))
44 #define cpu_test_feature(feature) (!!(cpu_feature_flags & cpu_feature_mask(feature)))
46 #define cpu_test_feature(feature) (cpu_feature_static_flags & cpu_feature_mask(feature) || cpu_feature_flags & cpu_feature_mask(feature))
50 void asm_setup_thread(void);
51 code_t
code_alt(code_t code
);