<feed xmlns='http://www.w3.org/2005/Atom'>
<title>eglantine-cirakg/src/common/virtual_buffer.h, branch nx2</title>
<subtitle>Mirror of github.com/cira0100/Eglantine-public nx2, a fork of Djihads80/Eglantine.</subtitle>
<id>https://git.cirakg.xyz/eglantine-cirakg/atom?h=nx2</id>
<link rel='self' href='https://git.cirakg.xyz/eglantine-cirakg/atom?h=nx2'/>
<link rel='alternate' type='text/html' href='https://git.cirakg.xyz/eglantine-cirakg/'/>
<updated>2026-09-09T19:35:49+00:00</updated>
<entry>
<title>[common/core/dynarmic] Optimize page table allocations (#4219)</title>
<updated>2026-09-09T19:35:49+00:00</updated>
<author>
<name>Exverge</name>
<email>exverge@exverge.xyz</email>
</author>
<published>2026-09-09T19:35:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cirakg.xyz/eglantine-cirakg/commit/?id=5f142c7926d0c7fcbbd0ce30794d72f638a43b2a'/>
<id>urn:sha1:5f142c7926d0c7fcbbd0ce30794d72f638a43b2a</id>
<content type='text'>
Reduces the page entries from 32 bytes to 8 and rewrites `VirtualBuffer` to be more efficient in memory usage and specifically for large zero regions.

The page table will now only reserve 1GiB instead of 4GiB and of this memory it should only use at most ~8MiB.

This PR has the side effect of using Eden on Windows on low memory systems much more plausible since it would previously require ~10GiB of committable memory at front (despite using ~5-6 at most, inadvertently stalling other processes) where as now it should only require around the amount that it'll actually use.

Co-authored-by: Lizzie &lt;lizzie@eden-emu.dev&gt;
Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/4219
Reviewed-by: Maufeat &lt;sahyno1996@gmail.com&gt;
Reviewed-by: lizzie &lt;lizzie@eden-emu.dev&gt;
Reviewed-by: CamilleLaVey &lt;camillelavey99@gmail.com&gt;
</content>
</entry>
<entry>
<title>[common/virtual_buffer] fix technically wrong usage of std::exchange() (#3992)</title>
<updated>2026-05-21T01:18:41+00:00</updated>
<author>
<name>lizzie</name>
<email>lizzie@eden-emu.dev</email>
</author>
<published>2026-05-21T01:18:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cirakg.xyz/eglantine-cirakg/commit/?id=889545e1ee17ef5e0a88faf18861f47a0e9e7523'/>
<id>urn:sha1:889545e1ee17ef5e0a88faf18861f47a0e9e7523</id>
<content type='text'>
simpleish fix https://en.cppreference.com/cpp/utility/exchange

Signed-off-by: lizzie &lt;lizzie@eden-emu.dev&gt;

Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/3992
Reviewed-by: crueter &lt;crueter@eden-emu.dev&gt;
Reviewed-by: MaranBr &lt;maranbr@eden-emu.dev&gt;
</content>
</entry>
<entry>
<title>[hle] reuse previous pagetable when initializing new processes on the same KProcessPageTable (#3891)</title>
<updated>2026-04-27T23:15:21+00:00</updated>
<author>
<name>lizzie</name>
<email>lizzie@eden-emu.dev</email>
</author>
<published>2026-04-27T23:15:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cirakg.xyz/eglantine-cirakg/commit/?id=c172abfb53e664b1f1e2cd11c6dfb99e6202553e'/>
<id>urn:sha1:c172abfb53e664b1f1e2cd11c6dfb99e6202553e</id>
<content type='text'>
VirtualBuffer&lt;&gt; would be recreated each time due to the `operator=()` from the unique_ptr&lt;&gt; when initializing a new process, this change makes it so said thing doesn't happen (instead it resizes the existing buffer)

this means that consecutive launches of the same process that happen to have the same process page table (or reuse it) will no longer incur a ctor/dtor path for VirtualBuffer and instead just resize the existing one

Signed-off-by: lizzie &lt;lizzie@eden-emu.dev&gt;

Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/3891
Reviewed-by: crueter &lt;crueter@eden-emu.dev&gt;
Reviewed-by: CamilleLaVey &lt;camillelavey99@gmail.com&gt;
</content>
</entry>
<entry>
<title>general: Convert source file copyright comments over to SPDX</title>
<updated>2022-04-23T09:55:32+00:00</updated>
<author>
<name>Morph</name>
<email>39850852+Morph1984@users.noreply.github.com</email>
</author>
<published>2022-04-23T08:59:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cirakg.xyz/eglantine-cirakg/commit/?id=2b87305d319f0bd04da36fb96314934f37b12637'/>
<id>urn:sha1:2b87305d319f0bd04da36fb96314934f37b12637</id>
<content type='text'>
This formats all copyright comments according to SPDX formatting guidelines.
Additionally, this resolves the remaining GPLv2 only licensed files by relicensing them to GPLv2.0-or-later.
</content>
</entry>
<entry>
<title>common: Reduce unused includes</title>
<updated>2022-03-19T19:01:31+00:00</updated>
<author>
<name>ameerj</name>
<email>52414509+ameerj@users.noreply.github.com</email>
</author>
<published>2022-03-19T04:23:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cirakg.xyz/eglantine-cirakg/commit/?id=e70b4f3fc52c2d4315ded26979cee67d81a07099'/>
<id>urn:sha1:e70b4f3fc52c2d4315ded26979cee67d81a07099</id>
<content type='text'>
</content>
</entry>
<entry>
<title>core/memory: Read and write page table atomically</title>
<updated>2020-12-30T00:54:49+00:00</updated>
<author>
<name>ReinUsesLisp</name>
<email>reinuseslisp@airmail.cc</email>
</author>
<published>2020-12-30T00:16:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cirakg.xyz/eglantine-cirakg/commit/?id=8bfa4d6dbf196dcde5f7348f668e730d8506f4fb'/>
<id>urn:sha1:8bfa4d6dbf196dcde5f7348f668e730d8506f4fb</id>
<content type='text'>
Squash attributes into the pointer's integer, making them an uintptr_t
pair containing 2 bits at the bottom and then the pointer. These bits
are currently unused thanks to alignment requirements.

Configure Dynarmic to mask out these bits on pointer reads.

While we are at it, remove some unused attributes carried over from
Citra.

Read/Write and other hot functions use a two step unpacking process that
is less readable to stop MSVC from emitting an extra AND instruction in
the hot path:

 mov         rdi,rcx
 shr         rdx,0Ch
 mov         r8,qword ptr [rax+8]
 mov         rax,qword ptr [r8+rdx*8]
 mov         rdx,rax
-and         al,3
 and         rdx,0FFFFFFFFFFFFFFFCh
 je          Core::Memory::Memory::Impl::Read&lt;unsigned char&gt;
 mov         rax,qword ptr [vaddr]
 movzx       eax,byte ptr [rdx+rax]
</content>
</entry>
<entry>
<title>virtual_buffer: Do nothing on resize() calls with same sizes</title>
<updated>2020-11-19T12:54:03+00:00</updated>
<author>
<name>Lioncash</name>
<email>mathew1800@gmail.com</email>
</author>
<published>2020-11-19T12:54:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cirakg.xyz/eglantine-cirakg/commit/?id=638f982efc70251ec901cd1881d442a4858f0916'/>
<id>urn:sha1:638f982efc70251ec901cd1881d442a4858f0916</id>
<content type='text'>
Prevents us from churning memory by freeing and reallocating a memory
block that would have already been adequate as is.
</content>
</entry>
<entry>
<title>virtual_buffer: Add compile-time type-safety guarantees with VirtualBuffer</title>
<updated>2020-11-18T01:09:58+00:00</updated>
<author>
<name>Lioncash</name>
<email>mathew1800@gmail.com</email>
</author>
<published>2020-11-18T01:09:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cirakg.xyz/eglantine-cirakg/commit/?id=d02005bbe9f97bbad973d47a91acee9b3e5f8c3f'/>
<id>urn:sha1:d02005bbe9f97bbad973d47a91acee9b3e5f8c3f</id>
<content type='text'>
VirtualBuffer makes use of VirtualAlloc (on Windows) and mmap() (on
other platforms). Neither of these ensure that non-trivial objects are
properly constructed in the allocated memory.

To prevent potential undefined behavior occurring due to that, we can
add a static assert to loudly complain about cases where that is done.
</content>
</entry>
<entry>
<title>page_table: Allow page tables to be moved</title>
<updated>2020-11-18T01:08:20+00:00</updated>
<author>
<name>Lioncash</name>
<email>mathew1800@gmail.com</email>
</author>
<published>2020-11-18T00:58:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cirakg.xyz/eglantine-cirakg/commit/?id=b9b02276ebd81b0579784c97006ce9d9cc18fb06'/>
<id>urn:sha1:b9b02276ebd81b0579784c97006ce9d9cc18fb06</id>
<content type='text'>
Makes page tables and virtual buffers able to be moved, but not copied,
making the interface more flexible.

Previously, with the destructor specified, but no move assignment or
constructor specified, they wouldn't be implicitly generated.
</content>
</entry>
<entry>
<title>common: Make use of [[nodiscard]] where applicable</title>
<updated>2020-08-15T21:17:52+00:00</updated>
<author>
<name>Lioncash</name>
<email>mathew1800@gmail.com</email>
</author>
<published>2020-08-14T13:38:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cirakg.xyz/eglantine-cirakg/commit/?id=2ef7815422f4584b334ff196efd72e40ad03e094'/>
<id>urn:sha1:2ef7815422f4584b334ff196efd72e40ad03e094</id>
<content type='text'>
Now that clang-format makes [[nodiscard]] attributes format sensibly, we
can apply them to several functions within the common library to allow
the compiler to complain about any misuses of the functions.
</content>
</entry>
</feed>
