mirror of
https://git.eden-emu.dev/eden-emu/eden
synced 2026-10-29 14:22:52 +01:00
2026-09-20 07:03:36
Signed-off-by: lizzie <lizzie@eden-emu.dev>
This commit is contained in:
parent
815325ccec
commit
e853a577e3
6 changed files with 63 additions and 56 deletions
|
|
@ -170,13 +170,19 @@ template<>
|
|||
|
||||
// check for marked bit, use as unmapped if marked
|
||||
if (ctx.conf.page_table_marked_bit) {
|
||||
code.bt(page, *ctx.conf.page_table_marked_bit);
|
||||
code.jc(abort, code.T_NEAR);
|
||||
auto const marked_bit = *ctx.conf.page_table_marked_bit;
|
||||
if (s64(s32(1 << marked_bit)) == s64(1 << marked_bit)) {
|
||||
code.test(page, s32(1 << marked_bit));
|
||||
code.jnz(abort, code.T_NEAR);
|
||||
} else {
|
||||
code.bt(page, marked_bit);
|
||||
code.jc(abort, code.T_NEAR);
|
||||
}
|
||||
}
|
||||
// mask away attributes
|
||||
if (ctx.conf.page_table_pointer_mask == 0) {
|
||||
code.test(page, page);
|
||||
} else if (std::in_range<s32>(ctx.conf.page_table_pointer_mask)) {
|
||||
} else if (s64(s32(ctx.conf.page_table_pointer_mask)) == s64(ctx.conf.page_table_pointer_mask)) {
|
||||
code.and_(page, ctx.conf.page_table_pointer_mask);
|
||||
} else {
|
||||
code.mov(tmp, ctx.conf.page_table_pointer_mask);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue