Skip to main content

Questions tagged [mmap]

All about using memory mapped files. Questions on programming should be asked on Stack Overflow SE.

2 votes
2 answers
176 views

I'm making a custom ELF loader to learn how the dynamic loader works behind the scenes, and one of the program headers often found in them is PT_GNU_RELRO, which tells the loader to make that segment ...
Electro_593's user avatar
0 votes
1 answer
191 views

I wrote a simple Python script to scan /proc/{pid}/maps for regions that are writable and executable on my computer. It came up with a few hits surprisingly, all private anonymous. Wondering why a ...
spinkus's user avatar
  • 510
1 vote
0 answers
333 views

I am writing a real-time linux application where I need to prevent any page faults from occuring after the initial startup of my application. My initial thought was just to call mlockall(MCL_CURRENT | ...
Jay S.'s user avatar
  • 61
0 votes
1 answer
56 views

I am using Open File Description (OFD) owned locks on Linux (fcntl with command F_OFD_SETLK). After locking a file, I memory mapped it, and closed the file descriptor. Another process tried to lock ...
Érico Rolim's user avatar
6 votes
1 answer
2k views

Based on my research on mmap(), I understand that mmap uses demand paging to copy in data to the kernel page cache only when the virtual memory address is touched, through page fault. If we are ...
prajasek's user avatar
2 votes
0 answers
294 views

On Linux, POSIX shared memory objects [1] use a tmpfs via /dev/shm. A tmpfs in turn is said to "live completely in the page cache" [2] (I'm assuming swap has not been enabled). I am ...
Philipp Friese's user avatar
3 votes
1 answer
140 views

I have been the dev/maintainer of an open source IRC bot since the late 90s. The goal was always to make it as versatile & useful as possible in a small memory footprint. During the 2000s I also ...
Alonda's user avatar
  • 131
4 votes
1 answer
1k views

I see in the web many conflicting or unclear descriptions of the memory layout of a Linux process. Usually the common diagram looks like: And a common description would say that: The data segment ...
aviro's user avatar
  • 6,965
0 votes
0 answers
324 views

I want to read the Intel iTCO watchdog registers on my Intel Lynx Point system. I found the watchdog here: [ 5598.341020] iTCO_wdt iTCO_wdt.1.auto: Found a Lynx Point TCO device (Version=2, TCOBASE=...
defoe's user avatar
  • 153
0 votes
1 answer
165 views

I'm interested in writing a program that can create two files, second file would be a "view" of first file and if modified, the first file would also be modified. Is this possible to do with ...
trickingLethargy's user avatar
0 votes
0 answers
108 views

I'm performing data recovery after an accident with dd. In the longer term, I'll need to use some recovery tools to try and repair the file system In the meantime, there's an image on the system that ...
user587941's user avatar
0 votes
1 answer
234 views

I have an application which appears to be slowing/blocking at the same time there's a lot of disk I/O going on, so I suspect it's I/O operations within the application which are blocking. I can't ...
phemmer's user avatar
  • 73.9k
5 votes
1 answer
1k views

Moved Post Notice I just moved this question (with slight modifications) from a StackOverflow question (which I have deleted, since cross-posting is strongly discouraged), which has not been answered ...
Lukas Barth's user avatar
0 votes
1 answer
386 views

My desire is conceptually simple, I have a file (really a PCIe resource file from /sys/bus/pci/device/.... but that isn't too relevant) on the host that I want to make available somewhere in guest ...
Seth Robertson's user avatar
1 vote
1 answer
331 views

I'm writing my own data store directly on top of a block device. To ensure durability I want to sync to disk. But here's the thing: I want to sync only part of it. I'm keeping a journal for crash ...
Jille Timmermans's user avatar

15 30 50 per page
1
2 3 4 5 6