Files
github-actions[bot] 0e51ecbb7e sunnypilot v2026.09.09-4864
version: sunnypilot v2026.003.000 (dev)
date: 2026-09-09T15:43:49
master commit: b255314f5a
2026-09-09 15:43:49 +00:00

16 lines
642 B
Python

import ctypes, platform, unittest
from tinygrad import Device
from tinygrad.renderer.cstyle import ClangRenderer
class TestQCOM(unittest.TestCase):
# although part of the QCOM runtime, this tests flushing the CPU's dcache
@unittest.skipUnless(isinstance(Device["CPU"].renderer, ClangRenderer) and platform.machine().lower() in {"arm64", "aarch64"},
"dcache_flush's inline asm needs ClangRenderer, and runs on arm64")
def test_dcache_flush(self):
from tinygrad.runtime.ops_qcom import dcache_flush
buf = (ctypes.c_uint8 * 64)()
dcache_flush().fxn(buf, 0)
if __name__ == '__main__':
unittest.main()