GDB Debugging Method (5) – Debugging Dynamic Libraries

GDB Debugging Method (5) - Debugging Dynamic Libraries

In my personal experience, in most cases, GDB debugging can be used to debug the behavior of a specific dynamic library independently. This allows for convenient problem localization directly on the device where the anomaly occurs. This article introduces how to use GDB to locate issues for a single dynamic library on a production device. … Read more

GDB Debugging Methods (6) – Debugging Techniques

GDB Debugging Methods (6) - Debugging Techniques

With good debugging information, using GDB for debugging becomes very simple. This article introduces common debugging techniques that are frequently used in operating systems. Compilation Environment and Runtime Environment Before discussing common debugging techniques, we must clarify what a compilation environment is and what a runtime environment is. Essentially, when operating systems are released, the … Read more

GDB Debugging Methods (4) – Debugging Information

GDB Debugging Methods (4) - Debugging Information

The key to whether a program is easy to debug lies in the completeness of the debugging information. This article provides a brief introduction to what DWARF debugging information is based on this premise. What is DWARF Debugging With Attributed Record Formats is a debugging information format used by many compilers, which allows for easy … Read more

GDB Debugging Methods (3) – Simple Debugging

GDB Debugging Methods (3) - Simple Debugging

We know that ptrace frequently issues PTRACE_GETREGS and PTRACE_SETREGS commands, modifying the PC register, allowing the process to be controlled by gdb and execute related commands at the trace point. This article uses a simple program to demonstrate basic debugging tasks using gdb. What to Debug Based on the understanding of ptrace, we can summarize … Read more

Understanding NOR Flash Memory Structure and Operations

Understanding NOR Flash Memory Structure and Operations

Welcome FPGA engineers to join the official WeChat technical group. This article mainly introduces the structure, external interfaces, and operations of NOR Flash. In NOR Flash, the ‘N’ stands for NOT, meaning that when there is a charge in the Floating Gate, it reads ‘0’, and when there is no charge, it reads ‘1’. This … Read more

Understanding C++ Exception Mechanism: A Small Program Example

Understanding C++ Exception Mechanism: A Small Program Example

AliMei Introduction The author encountered C++ exceptions while investigating a bug, and takes this opportunity to clarify the C++ exception mechanism for everyone’s reference. Recently, while investigating a bug, we encountered C++ exceptions. Since we rarely use C++ exceptions, this is a good opportunity to clarify the C++ exception mechanism. There is not much existing … Read more