{"record":{"id":"e6811c06c842116f","repo":"go-delve/delve","slug":"architectural-frame-rules-are-unsupported","errorCode":null,"errorMessage":"architectural frame rules are unsupported","messagePattern":"architectural frame rules are unsupported","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"pkg/proc/stack.go","lineNumber":841,"sourceCode":"\t\treturn it.readRegisterAt(regnum, uint64(cfa+rule.Offset))\n\tcase frame.RuleValOffset:\n\t\treturn op.DwarfRegisterFromUint64(uint64(cfa + rule.Offset)), nil\n\tcase frame.RuleRegister:\n\t\treturn it.regs.Reg(rule.Reg), nil\n\tcase frame.RuleExpression:\n\t\tv, _, err := op.ExecuteStackProgram(it.regs, rule.Expression, it.bi.Arch.PtrSize(), it.mem.ReadMemory)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\treturn it.readRegisterAt(regnum, uint64(v))\n\tcase frame.RuleValExpression:\n\t\tv, _, err := op.ExecuteStackProgram(it.regs, rule.Expression, it.bi.Arch.PtrSize(), it.mem.ReadMemory)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\treturn op.DwarfRegisterFromUint64(uint64(v)), nil\n\tcase frame.RuleArchitectural:\n\t\treturn nil, errors.New(\"architectural frame rules are unsupported\")\n\tcase frame.RuleCFA:\n\t\tif it.regs.Reg(rule.Reg) == nil {\n\t\t\treturn nil, nil\n\t\t}\n\t\treturn op.DwarfRegisterFromUint64(uint64(int64(it.regs.Uint64Val(rule.Reg)) + rule.Offset)), nil\n\tcase frame.RuleFramePointer:\n\t\tcurReg := it.regs.Reg(rule.Reg)\n\t\tif curReg == nil {\n\t\t\treturn nil, nil\n\t\t}\n\t\tif curReg.Uint64Val <= uint64(cfa) {\n\t\t\treturn it.readRegisterAt(regnum, curReg.Uint64Val)\n\t\t}\n\t\tnewReg := *curReg\n\t\treturn &newReg, nil\n\t}\n}\n","sourceCodeStart":823,"sourceCodeEnd":859,"githubUrl":"https://github.com/go-delve/delve/blob/a23773e6c31361e43246bc43a424ee009679b174/pkg/proc/stack.go#L823-L859","documentation":"During DWARF-based frame unwinding, executeFrameRegRule encounters a CFI rule of class 'architectural' (DWCFA_AARCH64/x86 architectural Augmentation). Delve does not implement architecture-defined augmentation rules, so it cannot compute the register value and errors instead of producing a wrong frame.","triggerScenarios":"Unwinding a frame whose DWARF FDE contains a RuleArchitectural register rule — typically when advancing registers through frames (advanceRegsDWARF) on binaries compiled with unusual CFI or architectures whose augmentation delve lacks.","commonSituations":"Debugging binaries produced by non-Go toolchains (C assemblies, system libraries) with architectural augmentation CFI; cgo frames; platform DWARF variants delve does not support.","solutions":["Rely on frames whose CFI delve supports (Go-compiled code), or step the frame boundary differently","Report/patch: implement the architectural rule for the target architecture in executeFrameRegRule","Use the frame-pointer-based fallback (debug with compiler flags that emit frame pointers)","Avoid debugging frames from foreign C libraries whose DWARF uses architectural augmentation"],"exampleFix":"// before\ncase frame.RuleArchitectural:\n    return nil, errors.New(\"architectural frame rules are unsupported\")\n// after\ncase frame.RuleArchitectural:\n    // implement arch-specific default rule, e.g. same as RuleSameVal or defined default\n    return op.DwarfRegisterFromUint64(it.regs.Uint64Val(rule.Reg)), nil","handlingStrategy":"fallback","validationCode":"// inspect CFI augmentation before unwinding\n// (dwarf) check FDE augmentation string for unsupported vendor/architectural augmentation","typeGuard":null,"tryCatchPattern":"reg, err := executeFrameRegRule(it, rule)\nif err != nil && strings.Contains(err.Error(), \"architectural frame rules are unsupported\") {\n    return fallbackToFramePointerUnwind(it)\n}","preventionTips":["Prefer frames from Go-compiled code with standard CFI","Compile C dependencies with frame pointers for fp-based fallback unwinding","Keep delve updated so newly supported augmentations are picked up"],"tags":["dwarf","cfi","stacktrace"],"backgroundTag":"unsupported-dwarf-rule","analyzedSha":"a23773e6c31361e43246bc43a424ee009679b174","analyzedAt":"2026-08-31T15:12:45.221Z","schemaVersion":2},"datasetVersion":"2026-08-31T19:17:28.585Z"}