From d3a84c25e0856e34585c613fe25c0e9c4aaa8bfd Mon Sep 17 00:00:00 2001 From: TermiNexus Date: Tue, 25 Aug 2026 15:53:44 +0800 Subject: [PATCH] =?UTF-8?q?feat(memhub):=20[DET]=20=E8=B6=8A=E7=95=8C?= =?UTF-8?q?=E5=86=99=E8=BF=BD=E5=8A=A0=E8=AE=B0=E5=BD=95=E8=A1=A8=E4=B8=8A?= =?UTF-8?q?=E4=B8=8B=E6=96=87=20-=20=E6=89=93=E5=8D=B0=E8=B6=8A=E7=95=8C?= =?UTF-8?q?=E5=9D=97=E5=89=8D=E5=90=8E=E5=90=843=E6=9D=A1=20{ptr,size}?= =?UTF-8?q?=EF=BC=8C=E6=8E=A8=E6=96=AD=E5=88=86=E9=85=8D=E9=98=B6=E6=AE=B5?= =?UTF-8?q?=EF=BC=88=E5=A6=82=20lexer/parser=20=E5=B0=8F=E7=BB=93=E6=9E=84?= =?UTF-8?q?=EF=BC=89=EF=BC=8C=E9=85=8D=E5=90=88=E8=B6=8A=E7=95=8C=E5=8C=BA?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E5=AE=9A=E4=BD=8D=20size=3D7=20=E5=9D=97?= =?UTF-8?q?=E5=86=99=E5=85=A5=E8=80=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- includes/memhub.vp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/includes/memhub.vp b/includes/memhub.vp index 2d94ac0..9204c39 100644 --- a/includes/memhub.vp +++ b/includes/memhub.vp @@ -898,6 +898,16 @@ class MemBuddy(MemManager): bvj: t.CUInt8T = (t.CUInt8T | t.CPtr)(t.CVoid(p + s + t.CUInt64T(bj3), t.CPtr))[0] stdio.printf("%02X ", t.CUInt32T(bvj)) bj3 += 1 + # 记录表上下文:该条前 3 + 后 3 的 {ptr,size},推断越界块分配阶段 + stdio.printf("\n记录上下文: ") + ci2: t.CInt = -3 + while ci2 <= 3: + idx2: t.CSizeT = t.CSizeT(t.CInt(i) + ci2) + if idx2 < self._det_count: + cip: t.CUInt64T = self._det_records[idx2 * 2] + cis: t.CUInt64T = self._det_records[idx2 * 2 + 1] + stdio.printf("[%d]ptr=%llu sz=%llu ", ci2, cip, cis & (free_flag - 1)) + ci2 += 1 stdio.printf("\n") stdlib.exit(1) i += 1