Inspiration

Developers building on QNX Neutrino 8.0 — especially teams migrating from QNX 7.1 or onboarding via QNX Everywhere — repeatedly hit two high-friction bottlenecks:

  1. Silent mkifs .build regressions: legacy io-pkt networking, libc.so.5, forgetting procnto-smp-instr when invoking tracelogger, launching device drivers before slogger2, unbounded waitfor timeouts, and user-space resource managers accidentally running as uid=0 (root).
  2. Manual, non-automated kernel trace analysis: tracelogger + traceprinter produce rich microsecond-level Neutrino IPC (MsgSend/MsgReceive/MsgReply) and Adaptive Partitioning Scheduler (APS) logs, yet developers lack a fast, cross-platform CLI + web visualizer that catches priority inheritance stalls, p99 latency spikes, and APS CPU budget overruns automatically in CI/CD.

What it does

QNXScope is an MIT-licensed Developer Tooling & Host Tools suite + interactive 7-Step QNX 8.0 Codelab consisting of five integrated components:

  • mkifs Buildfile Static Auditor & Auto-Remediator (src/core/ifsParser.ts): Audits .build manifests against 8 QNX 8.0 migration and hardening rules (io-pkt → io-sock, libc.so.5 → libc.so.6, procnto-smp-instr, slogger2 boot order, uid=0 exposure, bounded waitfor, +compress, secpolpush), computes a 0–100 Health Score and raw/compressed flash footprint, and generates a remediated QNX 8.0 .build with one click or --write-fix.
  • Neutrino IPC & APS Real-Time Trace Profiler (src/core/traceAnalyzer.ts, src/components/TraceTimelineSvg.tsx): Parses traceprinter logs, correlates synchronous MSG_SENDV → MSG_RECEIVEV → MSG_REPLYV RTT (p50, p95, p99, max), renders an SVG multi-process swimlane timeline, flags Neutrino priority inheritance inversions and APS partition bankruptcy risks, and enforces configurable CI p99 latency gates.
  • Cross-Platform Host CLI (src/cli.ts): Zero-hardware CI/CD runner (qnxscope audit-ifs, qnxscope analyze-trace --max-p99-us 250, qnxscope demo, --json, --write-fix) returning non-zero exit codes on CRITICAL IFS findings or real-time gate breaches.
  • Hardened QNX 8.0 C Reference Target (examples/qnx8-sensor-resmgr/): Idiomatic QNX Neutrino 8.0 /dev/lidar0 resource manager (sensor_resmgr.c) using dispatch_create_channel(), resmgr_attach(), slog2f(), and procmgr_ability() privilege dropping to uid=100:100, paired with a real-time adas_planner.c client using ClockCycles() / SYSPAGE_ENTRY(qtime), dual-architecture Makefile (qcc -Vgcc_ntox86_64 & gcc_ntoaarch64le), and a 100/100 hardened qemu-x86_64.build.
  • Interactive 7-Step QNX 8.0 Codelab (https://torpedas.github.io/qnxscope/?tab=codelab & CODELAB.md): Guides developers from QNX SDP 8.0 setup to booting a hardened 4-core QEMU x86_64 image, capturing a .kev kernel trace, and enforcing CI timing gates in ~29 minutes with zero physical hardware required.

Evidence of QNX 8.0 Use & Verification

  • Target & Toolchain: QNX SDP 8.0, QEMU x86_64 (4-vCPU SMP, startup-x86, procnto-smp-instr, io-sock + vtnet) & Raspberry Pi 4 aarch64le (startup-bcm2711-rpi4, io-sock + genet); cross-compiled with qcc -Vgcc_ntox86_64 / gcc_ntoaarch64le and assembled with mkifs.
  • Exact QNX 8.0 files & APIs in repo:
    • examples/qnx8-sensor-resmgr/sensor_resmgr.c: dispatch_create_channel(), iofunc_func_init(), resmgr_attach(), procmgr_ability(PROCMGR_ADN_NONROOT | PROCMGR_AOP_ALLOW | PROCMGR_AID_PATHSPACE), slog2_register(), slog2f().
    • examples/qnx8-sensor-resmgr/adas_planner.c: ClockCycles(), SYSPAGE_ENTRY(qtime)->cycles_per_sec.
    • examples/qnx8-sensor-resmgr/qemu-x86_64.build: [virtual=x86_64,bios +compress], procnto-smp-instr, slogger2, secpolpush, io-sock, libc.so.6, tracelogger, [uid=100 gid=100 perms=0755].
  • Verified CLI outputs:
    • node dist-cli/cli.mjs audit-ifs examples/qnx8-sensor-resmgr/qemu-x86_64.build → Health: 100/100 | Estimated IFS Size: 6205 KB raw (~3351 KB compressed) | PASS (exit code 0).
    • node dist-cli/cli.mjs analyze-trace examples/qnx8-sensor-resmgr/sample_adas_trace.txt --max-p99-us 250 → p50=75us p95=345us p99=345us | Gate (<=250us): FAIL, flags [CRITICAL] PRIORITY_INVERSION (adas_planner prio 48 blocked 345us on telemetry_logger prio 14) and [CRITICAL] APS_BUDGET_OVERRUN (telemetry_bg 34% vs 20% budget) (exit code 1).

How we built it

Built with TypeScript 5.8, React 19, Tailwind CSS v4, Vite 6, custom SVG real-time timeline rendering, Node 22 native unit testing (node --test), esbuild single-file CLI bundling, and idiomatic QNX Neutrino 8.0 C (<sys/dispatch.h>, <sys/iofunc.h>, <sys/neutrino.h>, <sys/procmgr.h>, <sys/slog2.h>).

Challenges we ran into

Parsing real-world mkifs bootstrap blocks where environment prefixes (PATH=... LD_LIBRARY_PATH=... procnto-smp-instr -v) precede the kernel binary required regex token extraction rather than naive whitespace splitting — caught and fixed via our automated unit test suite (npm run verify).

What's next for QNXScope

Direct .kev binary decoding without an intermediate traceprinter pass, VS Code / GitHub Action Marketplace publishing, and automated QNX secpol policy diffing across releases.

Built With

Share this project:

Updates

Submission history