rust-lang / rust-lang/rfcs

Cross-memory model data

Open
#318 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

A-machine T-compiler T-lang
Dominant language
Markdown
Stars
6.6k
Forks
1.7k
Avg merge
16h 14m
Merged PRs (30d)
1

Description

Issue by larsbergstrom
Wednesday Jul 16, 2014 at 13:31 GMT

For earlier discussion, see https://github.com/rust-lang/rust/issues/15715

This issue was labelled with: A-servo in the Rust repository


In our current model, any time that we return a JS object to Rust, we carefully thread in some Rust code that ensures the JS GC adds it to the root set and unregister it when Rust drops the value.

The ultimate goal would be for the Rust compiler to generate stack / register maps for JS-owned values so that the JS GC can directly walk the Rust stack. This would eliminate the need for explicit rooting and would reduce constraints on JS GC implementation.

CC: @zwarich @pcwalton

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading the earlier discussion in rust-lang/rust issue 15715 and the issue's description of Rust stacks, register maps, and JavaScript GC rooting. No files or tests are named. Done would mean the Rust compiler can generate maps that let the JavaScript GC walk Rust-owned values directly, reducing the need for explicit rooting.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, rust
Domain
compilers
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.