#include "spinlock.hpp"
#include <etl/format.h>
#include <atomic>
#include <cstdint>
#include "basic_info.hpp"
#include "cpu_io.h"
#include "system_test.h"
Go to the source code of this file.
◆ spinlock_test()
| auto spinlock_test |
( |
| ) |
-> bool |
Definition at line 348 of file spinlock_test.cpp.
348 {
349 bool ret = true;
351
352
355 ret = ret && test_basic_lock();
356 ret = ret && test_recursive_lock();
357 ret = ret && test_lock_guard();
358 ret = ret && test_interrupt_restore();
359 }
360
361
362
363 if (!spinlock_smp_test()) ret = false;
364 if (!spinlock_smp_buffer_test()) ret = false;
365 if (!spinlock_smp_string_test()) ret = false;
366
368 if (ret) {
370 } else {
372 }
373 }
374 return ret;
375}
auto GetCurrentCoreId() -> size_t
auto Err(etl::format_string< Args... > fmt, Args &&... args) -> void
以 ERROR 级别记录日志
auto Info(etl::format_string< Args... > fmt, Args &&... args) -> void
以 INFO 级别记录日志