rust/doc
bors 47c9a35747 auto merge of #10830 : alexcrichton/rust/spsc-queue, r=brson
This pull request completely rewrites std::comm and all associated users. Some major bullet points

* Everything now works natively
* oneshots have been removed
* shared ports have been removed
* try_recv no longer blocks (recv_opt blocks)
* constructors are now Chan::new and SharedChan::new
* failure is propagated on send
* stream channels are 3x faster

I have acquired the following measurements on this patch. I compared against Go, but remember that Go's channels are fundamentally different than ours in that sends are by-default blocking. This means that it's not really a totally fair comparison, but it's good to see ballpark numbers for anyway

```
          oneshot         stream          shared1
std         2.111           3.073          1.730 
my          6.639           1.037          1.238 
native      5.748           1.017          1.250 
go8         1.774           3.575          2.948 
go8-inf     slow            0.837          1.376 
go8-128     4.832           1.430          1.504 
go1         1.528           1.439          1.251 
go2         1.753           3.845          3.166 
```

I had three benchmarks:

* oneshot - N times, create a "oneshot channel", send on it, then receive on it (no task spawning)
* stream - N times, send from one task to another task, wait for both to complete
* shared1 - create N threads, each of which sends M times, and a port receives N*M times.

The rows are as follows:

* `std` - the current libstd implementation (before this pull request)
* `my` - this pull request's implementation (in M:N mode)
* `native` - this pull request's implementation (in 1:1 mode)
* `goN` - go's implementation with GOMAXPROCS=N. The only relevant value is 8 (I had 8 cores on this machine)
* `goN-X` - go's implementation where the channels in question were created with buffers of size `X` to behave more similarly to rust's channels.
2013-12-17 01:16:43 -08:00
..
lib Remove fail keyword from lexer & parser and clean up remaining calls to 2013-02-01 00:15:42 -08:00
po std::vec: convert to(_mut)_ptr to as_... methods on &[] and &mut []. 2013-12-15 23:37:41 +11:00
favicon.inc doc: add favicon to tutorial/manual 2013-11-13 09:32:50 +01:00
manual.inc doc: CSS changes + commit improved favicon 2013-12-13 21:50:26 +01:00
po4a.conf doc: Generate .po files for Japanse translations 2013-08-12 22:39:31 +09:00
prep.js fix escape 2012-10-05 12:41:00 -07:00
README doc: switch pandoc to html5 2013-10-19 20:29:34 +02:00
rust.css doc: CSS changes + commit improved favicon 2013-12-13 21:50:26 +01:00
rust.md doc: Update the documentation to describe the Pod trait. 2013-12-16 22:38:02 -08:00
rustdoc.md auto merge of #10944 : metajack/rust/pkgid-docs, r=cmr 2013-12-14 08:11:29 -08:00
rustpkg.md Update documentation for new pkgid attribute. 2013-12-12 15:22:23 -07:00
tutorial-borrowed-ptr.md remove the float type 2013-10-01 14:54:10 -04:00
tutorial-conditions.md test: Remove all remaining non-procedure uses of do. 2013-11-26 08:25:27 -08:00
tutorial-container.md Forbid privacy in inner functions 2013-11-17 21:28:18 -08:00
tutorial-ffi.md std::vec: convert to(_mut)_ptr to as_... methods on &[] and &mut []. 2013-12-15 23:37:41 +11:00
tutorial-macros.md Forbid privacy in inner functions 2013-11-17 21:28:18 -08:00
tutorial-rustpkg.md Add missing .com 2013-12-09 17:40:10 +01:00
tutorial-tasks.md Test fallout from std::comm rewrite 2013-12-16 22:55:49 -08:00
tutorial.md auto merge of #10944 : metajack/rust/pkgid-docs, r=cmr 2013-12-14 08:11:29 -08:00
version_info.html.template doc/rust.HTML: proper version box 2013-10-19 20:31:53 +02:00

Pandoc, a universal document converter, is required to generate docs as HTML
from Rust's source code. It's available for most platforms here:
http://johnmacfarlane.net/pandoc/installing.html

Node.js (http://nodejs.org/) is also required for generating HTML from
the Markdown docs (reference manual, tutorials, etc.) distributed with
this git repository.

To generate all the docs, run `make docs` from the root of the repository.
This will convert the distributed Markdown docs to HTML and generate HTML doc
for the 'std' and 'extra' libraries.

To generate HTML documentation from one source file/crate, do something like:

  rustdoc --output-dir html-doc/ --output-format html ../src/libstd/path.rs

(This, of course, requires that you've built/installed the `rustdoc` tool.)

To generate an HTML version of a doc from Markdown, without having Node.js
installed, do something like:

  pandoc --from=markdown --to=html5 --number-sections -o rust.html rust.md

The syntax for pandoc flavored markdown can be found at:
http://johnmacfarlane.net/pandoc/README.html#pandocs-markdown

A nice quick reference (for non-pandoc markdown) is at:
http://kramdown.rubyforge.org/quickref.html