Skip to content

Simple M:N task to OS thread support (Issue #508) #566

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 7 commits into from

Conversation

eholk
Copy link
Contributor

@eholk eholk commented Jun 23, 2011

These commits enable Rust programs to actually run in parallel. Domains (which have not yet been renamed) now spin up a certain number of threads, and tasks are scheduled between these threads.

The number of threads is controlled by the RUST_THREADS environment variable. By default, only one thread is used, so this should not impact anyone unless they intentionally enable multithreading.

The simplest way to get this working was to serialize all upcalls. This clearly won't give us optimal performance, but I imagine we can relax this some after more design and testing.

Eric Holk added 7 commits June 23, 2011 23:39
…el yet, but it will give us something fun to test threading with.
…ultaneously wake up a task blocked on a certain port.
…ck with RUST_THREADS=8, so we're probably fairly safe now. In the future we can relax the synchronization to get better performance.
…ered the minimum stack size to get the pfib benchmark to run without exhausting its address space on Windows.
@graydon
Copy link
Contributor

graydon commented Jun 27, 2011

Integrated, thanks. I'll open a bug on switching from rand to the provided isaac prng in the runtime.

@graydon graydon closed this Jun 27, 2011
keeperofdakeys pushed a commit to keeperofdakeys/rust that referenced this pull request Dec 12, 2017
Added O_EXEC, O_SEARCH to solaris and musl, O_PATH to musl.

See rust-lang#566.
bors pushed a commit to rust-lang-ci/rust that referenced this pull request Oct 26, 2020
celinval added a commit to celinval/rust-dev that referenced this pull request Jun 4, 2024
For now I just moved the reachability code to this new module. As a follow up PR, I am planning to move the unsized coercion related code into a separate module so it can be used to refactor and fix codegen casting logic (related issues rust-lang#1531, rust-lang#566, and rust-lang#1528) .
celinval added a commit to celinval/rust-dev that referenced this pull request Jun 4, 2024
We currently have a few issues with how we are generating code for casting (rust-lang#566, and rust-lang#1528). The structure of the code is also hard to understand and maintain (see rust-lang#1531 for more details).

This PR is the first part of the fix I developed. This change moves the coercion specific code to its own module and it introduces an iterator that traverses the coercion path.
celinval added a commit to celinval/rust-dev that referenced this pull request Jun 4, 2024
Fix issues with how we are generating code for casting (rust-lang#566, and rust-lang#1528).

Restructure the unsize casting to be done in one pass instead with deep recursion (rust-lang#1531). This also reuses the code from the reachability analysis, so we don't have to keep two ways of traversing the same structure.
antoyo added a commit to antoyo/rust that referenced this pull request Jan 13, 2025
Update GCC version to have the refactor CPU feature detection code
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants