DevWeave logoDevWeave
CommunitiesDiscoverHelp ForumFeaturesWhy DevWeaveAI & Verification
Log inGet started
Back to Issue Discovery
Nixitov/Riptide-Native #21closedRustOpen-Source Beginners

Offline: property tests for riptide-mem alias/continue/commit

Opened by @Nixitov · Assignees: None

View on GitHub
good first issuememory

Solve & Merge Reward: Up to +210 XP & +60 Coins

+30 XP on PR open · +180 XP & +60 coins on merge

3 GitHub Stars

Claim Status & GitHub Signal

Unassigned, with 2 comments. Unassigned does not guarantee unclaimed—read comments and linked PRs first.

AI Issue Assessment · Grounded Analyzer
2.8 / 10 · 3–4 · Beginner

Estimated from issue labels (good first issue, memory), Rust context, and discussion depth. There are 2 GitHub comments to review for maintainer clarifications. Note: this is an estimate, not a guarantee.

What It's About

Offline: property tests for riptide-mem alias/continue/commit. Why PLAN N1 acceptance already states the invariants: no two live pages alias unless explicitly mapped; continuing an allocation preserves every byte; decommit then recommit returns zeroed storage. crates/riptide-mem/tests/page_table.rs covers examples; random

Why It Matters

Resolving #21 improves reliability and developer experience in Nixitov/Riptide-Native.

Expected Outcome

A focused pull request addressing #21 with relevant checks or tests verified locally.

Skill Match Breakdown

Log in to compare this issue's requirements against your profile skills. Required concepts: Machine Learning, C / C++ & Memory.

Progressive AI Hints

Hint #1 is always free and calibrated to your experience level. Extra hints unlock with coins without spoiling the full solution.

Log in to receive your free level-adapted Hint #1 grounded in this repository's files.

Skill-Gap Learning

Gap-Targeted
Learn Memory Management in C

Stack vs. heap allocation, pointers, and low-level memory patterns.

Addresses skill gap: C / C++ & Memory

Hands-On CodeCrafters Practice
Skill-Gap Challenge
Build your own Shell
Rust

Parse commands, manage PATH lookups, pipes, and process execution.

Practice skill gap: C / C++ & Memory

Build your own Git
Rust

Implement .git storage, blob/tree objects, SHA hashing, and plumbing commands.

Practice skill gap: C / C++ & Memory

Issue Description

Why

PLAN N1 acceptance already states the invariants: no two live pages alias unless explicitly mapped; continuing an allocation preserves every byte; decommit then recommit returns zeroed storage. crates/riptide-mem/tests/page_table.rs covers examples; randomized sequences would catch the edge cases before the live path does.

Scope

  • Add deterministic property/randomized tests (fixed seed, printed on failure) in crates/riptide-mem/tests/, or a new tests/properties.rs.
  • Cover: reserve/commit/free interleavings, continuing runs across page boundaries, aliases via map, free_physical, and double-free/re-commit.
  • Test only. Do not change AddressSpace semantics.

Acceptance

  • cargo test -p riptide-mem passes.
  • A failing case prints the exact operation sequence and the seed.
  • No title, no dump, no GPU.

Good first issue?

Yes. Pure Rust, fast, and it hardens the memory model the whole port stands on.

Linked Pull Requests (0)

No linked or cross-referenced pull requests detected via GitHub timeline. Check comments below for informal claims before starting.

GitHub Comments (2)

@Quat3rnionCONTRIBUTOR
View comment →

Claimed in #25 (@Quat3rnion).

@Quat3rnionCONTRIBUTOR
View comment →

Question for the maintainer, from the property-test work in #25: are AddressSpace range operations meant to be all-or-nothing?

Minimal repro on unmodified master (native Rust probe):

reserve(0 .. 2*PAGE_SIZE)
commit(0 .. PAGE_SIZE)
p = allocate_physical(1); map(PAGE_SIZE, &p)
# before: page 0 Committed, page 1 Mapped
decommit(0 .. 2*PAGE_SIZE) -> Err(MappedPage(0x10000))
# after:  page 0 Reserved (already decommitted), page 1 Mapped

The call fails, but it has already changed page 0. release and unmap follow the same loop pattern. N1 does not say which behaviour is intended.

The #25 tests do not change any semantics. They model the current behaviour (the pages before the failing page are applied) in one named helper, labelled "mirrors current behaviour, not a documented contract". If you want these operations to be atomic (validate the whole range first), that is a separate fix, and I can claim it. Otherwise, the docs could state the prefix rule.

Peer Help Forum · Nixitov/Riptide-Native #21

Issue Troubleshooting Threads (0)

Ask Peers for Help

No troubleshooting threads opened for this issue yet. If you hit a test, build, or navigation blocker, post what you've tried so fellow contributors can help.

PR Verification & Rewards

Sign in and link GitHub to verify your PR against this issue and earn XP + coins.

Sign In

Contribution Workflow

Track your local progress before opening a pull request on GitHub.

Repository Context

Top Repository Paths

[dir] .github
[dir] .github/workflows
.github/workflows/ci.yml
.github/workflows/mirror-codeberg.yml
.gitignore
CONTRIBUTING.md
Cargo.lock
Cargo.toml
LICENSE
NEXT.md
NOTICE
PROCESS.md
README.md
[dir] crates
[dir] crates/riptide-dump
crates/riptide-dump/Cargo.toml
[dir] crates/riptide-dump/examples
crates/riptide-dump/examples/duplicates.rs
crates/riptide-dump/examples/layout.rs
crates/riptide-dump/examples/nested.rs
crates/riptide-dump/examples/verify.rs
[dir] crates/riptide-dump/src
crates/riptide-dump/src/dump.rs
crates/riptide-dump/src/header.rs

CONTRIBUTING.md Excerpt

Contributing

The three rules

  1. No game files, game-derived binaries or assets. Everything the renderer needs from the title is supplied by the user at runtime or produced locally into a path outside this repository. A pull request that adds a .bin, .xvd, extracted texture, shader dump, frame capture or screenshot containing title content is rejected. Logs with addresses and counts are fine; dumps of title memory are not.
  2. No DRM circumvention. Do not add code whose purpose is to break copy protection. Loading a user-supplied executable for interoperability is the scope; anything beyond that is out.
  3. Every merged change carries an evidence line. The commit message or the PR description says how the change was verified: a command and its output, a test name, or a log path under docs/evidence/. "Should work" is not evidence.

Build

Prerequisites: Windows 10/11 x64, Rust 1.98.1 (see rust-toolchain.toml), a D3D12 capable GPU and the Windows SDK.

cargo build --locked
cargo test --workspace

The first milestone does not need the game. Later milestones that do need it will say so in NEXT.md; never launch the title while another session holds the measurement lock (C:\Users\Nix\Desktop\play-riptide.ps1 and the tools in public-v082\tools document it).

Linux (Proton) local runs

Install the repository's Rust toolchain, the x86_64-pc-windows-gnu Rust target, a MinGW-w64 cross linker, and Proton Experimental. The script uses Bash, GNU coreutils, setsid, pgrep, and Bubblewrap (bwrap). Headless runs also need Xvfb, xvfb-run, and xauth. If you cannot use Bubblewrap, pass --no-sandbox. Use a dedicated Wine prefix with G: and T: free and Z: mapped to /. The script initializes a new prefix if needed. Give each run a new cache directory outside the checkout.

tools/run-bounded-proton.sh --exe "$TITLE_DIR/game_scarlett_master.exe" \
    --prefix "$HOME/.local/share/riptide/proton-prefix" \
    --cache "$HOME/.cache/riptide/run-1" --real-device --headless

Run only one title instance at a time. Label these results local Proton. They do not count as the gated run in PROCESS.md.

Picking a task

  1. Read NEXT.md, PROCESS.md and docs/STATUS.md.
  2. Check the claims before you pick anything: powershell -File tools/claims.ps1 (or

... (truncated)

Advisory PR Assistant

Helps structure your PR description or unpack reviewer feedback. Does not perform GitHub actions.