rust/src/libstd
bors 8b00355119 Auto merge of #36339 - brson:emscripten-new, r=alexcrichton
Working asmjs and wasm targets

This patch set results in a working standard library for the asmjs-unknown-emscripten and wasm32-unknown-emscripten targets. It is based on the work of @badboy and @rschulman.

It does a few things:

- Updates LLVM with the emscripten [fastcomp](https://github.com/rust-lang/llvm/pull/50) patches, which include the pnacl IR legalizer and the asm.js backend. This patch is thought not to have any significant effect on existing targets.
- Teaches rustbuild to correctly link C code with emscripten
- Updates gcc-rs to work correctly with emscripten
- Teaches rustbuild to run crate tests for emscripten with node
- Modifies Thread::new to return an error on emscripten, to facilitate debugging a common failure mode
- Modifies libtest to run in single-threaded mode for emscripten
- Ignores a host of tests that don't work yet, mostly dealing with threads and I/O
- Updates libc with wasm32 definitions (presently the same as asmjs)
- Adds a wasm32-unknown-emscripten target that feeds the output of LLVM's asmjs backend through emcc to generate wasm

Notes and caveats:

- This is only known to work with `--enable-rustbuild`.
- The wasm32 target can't be tested correctly yet because of issues in compiletest and limitations in node https://github.com/kripken/emscripten/issues/4542, but hello.rs does seem to work when run on node via the binaryen interpreter
- This requires an up to date installation of the emscripten sdk from its incoming branch
- Unwinding is very broken
- When enabling the emscripten targets jemalloc is disabled for all targets, which results in test failures for the host

Next steps are to fix the jemalloc issue, start building the two emscripten targets on the auto builders, then start producing nightlies.

https://github.com/rust-lang/rust/issues/36317 tracks work on this.

Fixes https://github.com/rust-lang/rust/issues/36515
Fixes https://github.com/rust-lang/rust/issues/36515
Fixes https://github.com/rust-lang/rust/issues/36356
2016-09-30 19:00:36 -07:00
..
collections Auto merge of #36557 - sfackler:fix-hashdos-docs, r=alexcrichton 2016-09-29 20:25:45 -07:00
ffi Remove CString drop test. 2016-09-26 20:50:32 +03:00
io Auto merge of #36339 - brson:emscripten-new, r=alexcrichton 2016-09-30 19:00:36 -07:00
net Ignore various entire test modules on emscripten 2016-09-30 14:02:56 -07:00
num Use #[prelude_import] in libstd. 2016-08-24 22:12:48 +00:00
os Preliminary wasm32 support 2016-09-30 14:02:45 -07:00
prelude End stdlib module summaries with a full stop. 2016-03-04 17:37:11 -05:00
rand Ignore lots and lots of std tests on emscripten 2016-09-30 14:02:48 -07:00
sync Ignore various entire test modules on emscripten 2016-09-30 14:02:56 -07:00
sys Call emcc with ERROR_ON_UNDEFINED_SYMBOLS 2016-09-30 14:02:57 -07:00
thread Auto merge of #36339 - brson:emscripten-new, r=alexcrichton 2016-09-30 19:00:36 -07:00
time Reword description of SystemTimeError. 2016-09-29 20:08:46 +02:00
ascii.rs Use #[prelude_import] in libstd. 2016-08-24 22:12:48 +00:00
build.rs Report which required build-time environment variable is not set 2016-09-25 12:18:09 -04:00
Cargo.toml crate-ify compiler-rt into compiler-builtins 2016-09-12 21:22:15 -07:00
env.rs Ignore lots and lots of std tests on emscripten 2016-09-30 14:02:48 -07:00
error.rs Implement TryFrom<u32> for char 2016-08-29 17:34:02 +02:00
fs.rs Ignore various entire test modules on emscripten 2016-09-30 14:02:56 -07:00
lib.rs Remove stage0 hacks 2016-09-28 23:17:56 +00:00
macros.rs Add links between format_args! macro and std::fmt::Arguments struct 2016-09-16 15:33:53 -06:00
memchr.rs memrchr: Use a conditional instead of subtracting a complicated min 2016-08-24 21:41:23 +02:00
panic.rs Use #[prelude_import] in libstd. 2016-08-24 22:12:48 +00:00
panicking.rs Add basic doc examples for std::panic::{set_hook, take_hook}. 2016-09-18 10:03:34 -04:00
path.rs Rollup merge of #36314 - tshepang:not-needed, r=GuillaumeGomez 2016-09-10 15:57:50 +02:00
primitive_docs.rs Tweak array docs 2016-09-11 12:36:24 -07:00
process.rs Auto merge of #36339 - brson:emscripten-new, r=alexcrichton 2016-09-30 19:00:36 -07:00
rt.rs Use #[prelude_import] in libstd. 2016-08-24 22:12:48 +00:00
rtdeps.rs Add support for the Haiku operating system on x86 and x86_64 machines 2016-09-25 11:12:23 -05:00