rust-lang/rust — pull request #18967 by aturon (2014-11-15 04:04:39+00:00)
Title: Finish runtime removal

This PR completes the removal of the runtime system and green-threaded abstractions as part of implementing [RFC 230](https://github.com/rust-lang/rfcs/pull/230).

Specifically:

* It removes the `Runtime` trait and `bookkeeping` module, welding the scheduling infrastructure directly to native threads, and allowing a Rust program to shut down immediately once its main thread has terminated even if others are still running.

* It removes `libgreen` entirely, and all of `libnative` except for a `stage0` stub needed for bootstrapping.

* It rewrites `sync::mutex` as a trivial layer on top of native mutexes. Eventually, the two modules will be merged.

* It hides the vast majority of `std::rt`.

This completes the basic task of removing the runtime system (I/O and scheduling) and components that depend on it.

After this lands, a follow-up PR will pull the `rustrt` crate back into `std`, turn `std::task` into `std::thread` (with API changes to go along with it). Other changes, including new [TLS](https://github.com/rust-lang/rfcs/pull/461) and synchronization are in the RFC or pre-RFC phase.

Closes #17325

[breaking-change]

r? @alexcrichton