Tag

ptmalloc

0 views collected around this technical thread.

Deepin Linux
Deepin Linux
Dec 19, 2024 · Fundamentals

Understanding the Implementation and Mechanisms of the C malloc Function

This article explains the purpose, prototype, and usage of C's malloc function, delves into its underlying implementation using free‑list mechanisms, virtual‑memory translation, system calls like brk and mmap, and compares it with related functions such as calloc, realloc and new, while providing practical code examples and best‑practice guidelines.

C++Memory Allocationdynamic memory
0 likes · 32 min read
Understanding the Implementation and Mechanisms of the C malloc Function
vivo Internet Technology
vivo Internet Technology
Dec 11, 2024 · Databases

RocksDB Memory Usage Analysis and Optimization: Troubleshooting Excessive Memory Consumption in Production

The article examines a production RocksDB memory‑usage problem where two instances consumed 59 GB on a 32‑CPU, 64‑GB server, identifies glibc ptmalloc’s unreclaimed free memory as the main cause, and shows that switching to jemalloc cuts usage by roughly 25 % while improving I/O and CPU efficiency.

Database PerformanceLinux Memory ManagementMemory Optimization
0 likes · 11 min read
RocksDB Memory Usage Analysis and Optimization: Troubleshooting Excessive Memory Consumption in Production
vivo Internet Technology
vivo Internet Technology
Nov 6, 2024 · Fundamentals

Analysis of glibc Memory Management and Solutions to an Online Memory Incident

The article examines a real‑world memory alarm in a Vivo service, explains how glibc’s ptmalloc allocator manages heap memory via brk, sbrk, and mmap, shows why freed chunks stay in bins, and recommends limiting heap growth or switching to jemalloc for faster reclamation.

Backend DevelopmentC runtimeMemory Management
0 likes · 20 min read
Analysis of glibc Memory Management and Solutions to an Online Memory Incident
Refining Core Development Skills
Refining Core Development Skills
Jan 23, 2024 · Fundamentals

Deep Dive into the Internal Working of malloc and the ptmalloc Memory Allocator

This article explains how the glibc malloc implementation (ptmalloc) manages memory by using arenas, chunks, and various bin structures such as fastbins, smallbins, largebins, and unsorted bins, and describes the step‑by‑step allocation process performed by public_mALLOc and its helper functions.

C++HeapMemory Allocation
0 likes · 14 min read
Deep Dive into the Internal Working of malloc and the ptmalloc Memory Allocator
Zhuanzhuan Tech
Zhuanzhuan Tech
Sep 14, 2023 · Fundamentals

Analysis and Comparison of ptmalloc and tcmalloc Memory Allocators on Linux

This article examines Linux memory management fundamentals, explains the brk/sbrk and mmap system calls, details the internal architectures, allocation and reclamation processes of ptmalloc and tcmalloc, analyzes key configuration parameters, and presents benchmark and production‑level results that demonstrate their impact on performance and memory usage.

BenchmarkMemory AllocationPerformance
0 likes · 32 min read
Analysis and Comparison of ptmalloc and tcmalloc Memory Allocators on Linux
Qunar Tech Salon
Qunar Tech Salon
Jan 31, 2023 · Operations

Root Cause Analysis and Mitigation of JVM GC‑Induced OOM and Memory Fragmentation in a Containerized Hotel Pricing Service

This article details how long JVM garbage‑collection pauses and glibc ptmalloc memory‑fragmentation caused container OOM kills in a hotel‑pricing system, and explains the step‑by‑step diagnosis, JVM tuning, Kubernetes health‑check adjustments, and the replacement of ptmalloc with jemalloc to eliminate the issue.

GCJVMKubernetes
0 likes · 9 min read
Root Cause Analysis and Mitigation of JVM GC‑Induced OOM and Memory Fragmentation in a Containerized Hotel Pricing Service
Baidu Geek Talk
Baidu Geek Talk
Dec 16, 2022 · Fundamentals

Exploring ptmalloc: Memory Management in Linux C++ Programs

The article explains how glibc’s default ptmalloc allocator structures memory into main and non‑main arenas, uses chunk‑based bins (fast, unsorted, small, large) for allocation and deallocation, details its locking and OS‑interaction mechanisms, and evaluates its design trade‑offs versus modern allocators.

C++Memory Managementfree
0 likes · 12 min read
Exploring ptmalloc: Memory Management in Linux C++ Programs
58 Tech
58 Tech
Dec 6, 2019 · Fundamentals

Analyzing Heap Memory Usage and Detecting Memory Leaks in C++ Processes with Core Analyzer

This article introduces common memory‑leak detection tools, explains how to analyze heap memory consumption of a C++ process using AddressSanitizer, Valgrind and the core_analyzer utility, and provides practical optimization suggestions for reducing memory bloat and fragmentation.

C++Memory LeakPerformance Debugging
0 likes · 18 min read
Analyzing Heap Memory Usage and Detecting Memory Leaks in C++ Processes with Core Analyzer