Skip to main content
The 2024 Developer Survey results are live! See the results

Questions tagged [memory-management]

Process of dynamically allocating and freeing portions of physical memory in order to respond to program requests with, if possible, fairness and no starvation among the requesters.

memory-management
0 votes
0 answers
15 views

How to force releasing memory

I’m trying to iterate over a large file tree reading URL’s and creating hash values, but there’s a memory leak I can’t fix. The consumed memory is growing until the app stopp working. For testing ...
MatFetsch's user avatar
1 vote
0 answers
85 views

Difference in Memory Usage Between malloc and new in C++

I'm observing a difference in the total memory allocation when using malloc versus new in a simple C++ program, as reported by Valgrind. Below are the two versions of my program and the corresponding ...
sajad's user avatar
  • 13
1 vote
0 answers
48 views

How to Get Total Memory Usage of a Chrome Tab

I am trying to obtain the total memory usage (similar to what is shown in Chrome's Task Manager as "Memory Footprint") of a Chrome tab. While I can get the JavaScript heap size using ...
Anton's user avatar
  • 11
0 votes
0 answers
13 views

Memory Issue with Ray in Cluster Environment

I'm new to using Ray, and I've set up a workflow to read and process several .csv files using Pandas. Here's a snippet of my setup: with on_ray( num_cpus=6, object_store_memory=10 * 1024 * ...
Vgamero's user avatar
0 votes
0 answers
14 views

Customizing PyTorch memory allocator on CPUs

The PyTorch docs only have documentation on how to tweak its memory management for CUDA allocations. It uses the caching allocator for it's memory management which maintains the allocated memory ...
Sathvik Swaminathan's user avatar
0 votes
2 answers
68 views

Why does std::coroutine_handle only refer to a coroutine (via raw pointer) instead of owning it (via std::unique_ptr)?

I'm interested in understanding the reason behind the design choice of having std::coroutine_handle be effectively a non-owner of the coroutine state/frame. I understand that (at least usually?) the ...
Enlico's user avatar
  • 26.7k
-3 votes
0 answers
24 views

What is the difference between internal and external fragmentation? [closed]

I've read that internal has something to do with pre-defined blocks of memory and that external is scattered. What does this even mean? Which is more widely used? I tried searching this on ...
VickySekhon's user avatar
1 vote
1 answer
27 views

JFR not dumping file contents

I am trying to have my process run with JFR enabled. Recently, when the process ends, contents are not dumped to the JFR file, so it’s just empty. If I run the process for maybe 3 minutes and stop it, ...
rmh99's user avatar
  • 21
0 votes
0 answers
61 views
+50

Large allocation metadata is causing fragmentation and wasting DRAM in jemalloc when using extent hooks

I am writing a simple custom extent allocator that returns extents from a pre mapped area (this way I can explicitly control the mapped area -- and the allocations in it). I am using the dev branch of ...
idle_cycles's user avatar
-1 votes
0 answers
12 views

Change partition for the C drive if its on different MBR disk [closed]

Trying to get unused space from E drive to C drive but for some reason cannot find a way to migrate them between Disk 1 MBR and Disk 2 MBR even when split it into unallocated space. Does anyone know ...
Artur Stanski's user avatar
-1 votes
0 answers
38 views

Is there a way to force an NSObject to be allocated in stack or static memory?

I am asking this out of curiosity, because even if this can technically be done, this is almost certainly unsupported by Apple. As far as I can tell, only NSString literals, and possibly NSDictionary ...
CPlus's user avatar
  • 4,374
0 votes
0 answers
6 views

NVIDIA cufft Memory free-up

When I loop through the following code, the GPU memory continues to increase #include <iostream> #include <cuda_runtime.h> #include "device_launch_parameters.h" #include <...
潘光健's user avatar
-1 votes
0 answers
25 views

How to traverse VMA in Linux 6.6 version? [duplicate]

In the old version of Linux(5.10), we can traverse VMA like that : static void walk_vma_range(struct mm_struct *mm, u32 *nr_vma, u32 *nr_pages) { struct vm_area_struct *vma = mm->mmap; u32 ...
Askemi Wang's user avatar
0 votes
1 answer
63 views

Do processes share the read-only sections of common dynamically loaded libraries?

I would like to verify how the memory consumption works when I have two different executables that depend on the same dynamically loaded library and the library has both "state" (i.e., ...
A.G's user avatar
  • 1
0 votes
0 answers
24 views

getting aligned pointer inside storage to place object

I have a storage in a form of an array of bytes. On the stack // storage on the stack, no requirement on alignment unsigned char storage[N]; Or on the heap // storage on the heap, no requirement on ...
Oersted's user avatar
  • 1,706

15 30 50 per page
1
2 3 4 5
1839