Skip to content

Instantly share code, notes, and snippets.

View MangaD's full-sized avatar
📚
studying

David Gonçalves MangaD

📚
studying
View GitHub Profile
@MangaD
MangaD / evolution_programming_languages.md
Created May 10, 2026 12:30
The Evolution of Programming Languages: From Machine Code to Modern Paradigms

The Evolution of Programming Languages: From Machine Code to Modern Paradigms

CC0

Disclaimer: ChatGPT generated document.

The “first programming languages” depend on what you count as a programming language. There is a progression from mechanical instructions, to assembly-like systems, to high-level symbolic languages. The history is fascinating because it mirrors the evolution of computers themselves.

Before Electronic Computers

@MangaD
MangaD / oop_why_term_objects.md
Created May 10, 2026 10:48
Why Are They Called “Objects” in Object-Oriented Programming?

Why Are They Called “Objects” in Object-Oriented Programming?

CC0

Disclaimer: ChatGPT generated document.

The term “object” in Object-Oriented Programming comes from the idea that a program should be built from independent entities that resemble real-world things --- things that have:

  • state (data, properties),
  • behavior (actions, methods),
@MangaD
MangaD / unified_diff_format.md
Created April 23, 2026 13:01
Unified Diff Format

Unified Diff Format

CC0

Disclaimer: ChatGPT generated document.

The unified diff format is one of those deceptively simple tools that quietly powers a huge portion of modern software development. Whether you’re reviewing a pull request, debugging a regression, or applying a patch from a mailing list, you’re almost certainly interacting with unified diffs—often without thinking about it.

Let’s unpack what it is, how it works, and the ecosystem of tools built around it.

@MangaD
MangaD / command_line_arguments.md
Created April 22, 2026 12:21
Understanding Command-Line Arguments: Flags, Options, and Beyond

Understanding Command-Line Arguments: Flags, Options, and Beyond

CC0

Disclaimer: ChatGPT generated document.

When working with command-line programs, one of the first concepts you encounter is the idea of passing inputs directly to a program at launch. These inputs control behavior, configure execution, or provide data. While many developers casually refer to all such inputs as “flags,” the reality is more nuanced.

This article provides a clear, structured understanding of what these inputs are actually called, how they are categorized, and why the distinctions matter—especially for developers building robust CLI tools.

@MangaD
MangaD / cpp_sanitizers.md
Last active April 10, 2026 21:07
The Complete C/C++ Sanitizers Handbook

The Complete C/C++ Sanitizers Handbook

CC0

Disclaimer: ChatGPT generated document.

Below is the guide I would want if I were onboarding a senior C++ engineer to sanitizers and wanted both practical depth and architectural understanding.

1. What sanitizers are

@MangaD
MangaD / callgrind.md
Created April 9, 2026 16:41
Callgrind for C++ Engineers: The Exhaustive Guide

Callgrind for C++ Engineers: The Exhaustive Guide

CC0

Disclaimer: ChatGPT generated document.

Callgrind is Valgrind’s call-graph profiling tool. Officially, it records the call history among functions as a call graph and, by default, collects the number of instructions executed, their mapping to source lines, caller/callee relationships, and call counts. It can also optionally simulate cache and branch prediction behavior, similar to Cachegrind. (valgrind.org)

For a C++ engineer, the most important way to think about Callgrind is this:

@MangaD
MangaD / cpp_debuggers_compared.md
Last active April 1, 2026 17:31
🧠 A Deep Dive into Debuggers: Names, Philosophy, and Design Trade-offs

🧠 A Deep Dive into Debuggers: Names, Philosophy, and Design Trade-offs

CC0

Disclaimer: ChatGPT generated document.

Modern systems programming—especially in C and C++—relies heavily on powerful debugging and profiling tools. Names like gdb, lldb, perf, valgrind, and rr come up constantly, but they represent very different philosophies and approaches to understanding program behavior.

This article gives you a complete, structured overview:

@MangaD
MangaD / x11_vs_wayland.md
Last active April 1, 2026 17:17
X11 vs Wayland — A Deep, Complete Guide

🖥️ X11 vs Wayland — A Deep, Complete Guide

CC0

Disclaimer: ChatGPT generated document.


🧠 1. What Are X11 and Wayland?

@MangaD
MangaD / rr_debugger.md
Last active April 1, 2026 16:52
rr Debugger — The Complete, In-Depth Guide for C++ Engineers (Record, Replay, and Reverse Debugging Mastery)

rr Debugger — The Complete, In-Depth Guide for C++ Engineers (Record, Replay, and Reverse Debugging Mastery)

CC0

Disclaimer: ChatGPT generated document.

Here’s the most complete practical guide I can give you about rr as a C++ engineer.

What rr is

@MangaD
MangaD / valgrind.md
Last active May 17, 2026 02:09
Valgrind for C++ Engineers: The Complete Deep-Dive into Memory Analysis, Debugging, and Runtime Instrumentation

Valgrind for C++ Engineers: The Complete Deep-Dive into Memory Analysis, Debugging, and Runtime Instrumentation

CC0

Disclaimer: ChatGPT generated document.

Valgrind is a dynamic binary instrumentation framework and tool suite. In practice, that means it runs your compiled program on a synthetic CPU, intercepts memory allocation and threading primitives, and attaches tool-specific analyses to every relevant instruction. The current official release is 3.26.0 dated 24 October 2025. The Valgrind distribution includes Memcheck, Cachegrind, Callgrind, Massif, Helgrind, DRD, DHAT, plus some other and experimental tools. ([valgrind.org][1])

For a C++ engineer, the one-sentence summary is: **Valgrind is still one of the best “truth serum” tools for native code correctness and low-level runtime inspection, especially for heap misuse, leaks, uninitialized-value flow, allocator mismatches, and ce