Commit Graph

12 Commits

Author SHA1 Message Date
Wang Xuerui
a28c01bdf9 Remove mention of mipsel target_arch
The `mipsel` `target_arch` was introduced with the initial MIPSel
support (rust-lang/rust@82ec1aef29),
but was subsequently removed with implementation of the Flexible Target
Specification (Rust RFC 0131,
rust-lang/rust@3a8f4ec32a).
This is the only remaining instance in rustc. All others are in the libc
repo, and are fixed in rust-lang/libc@b3676593f6.
2016-11-07 14:15:58 +08:00
Srinivas Reddy Thatiparthy
1cc1dcce7d
run rustfmt on libpanic_unwind 2016-10-18 23:09:47 +05:30
Manish Goregaokar
c1a19b8481 Rollup merge of #37031 - fitzgen:typo-in-gcc-rs-comment, r=alexcrichton
Fix a typo in a comment describing gcc.rs's eh_frame_registry module

s/reigster/register/

r? @alexcrichton
2016-10-08 16:52:43 +05:30
Nick Fitzgerald
75c0d3f657 Fix a typo in a comment describing gcc.rs's eh_frame_registry module
s/reigster/register/
2016-10-07 15:00:48 -07:00
Ulrich Weigand
19b84088d7 Add s390x support
This adds support for building the Rust compiler and standard
library for s390x-linux, allowing a full cross-bootstrap sequence
to complete.  This includes:

- Makefile/configure changes to allow native s390x builds
- Full Rust compiler support for the s390x C ABI
  (only the non-vector ABI is supported at this point)
- Port of the standard library to s390x
- Update the liblibc submodule to a version including s390x support
- Testsuite fixes to allow clean "make check" on s390x

Caveats:

- Resets base cpu to "z10" to bring support in sync with the default
  behaviour of other compilers on the platforms.  (Usually, upstream
  supports all older processors; a distribution build may then chose
  to require a more recent base version.)  (Also, using zEC12 causes
  failures in the valgrind tests since valgrind doesn't fully support
  this CPU yet.)

- z13 vector ABI is not yet supported.  To ensure compatible code
  generation, the -vector feature is passed to LLVM.  Note that this
  means that even when compiling for z13, no vector instructions
  will be used.  In the future, support for the vector ABI should be
  added (this will require common code support for different ABIs
  that need different data_layout strings on the same platform).

- Two test cases are (temporarily) ignored on s390x to allow passing
  the test suite.  The underlying issues still need to be fixed:
  * debuginfo/simd.rs fails because of incorrect debug information.
    This seems to be a LLVM bug (also seen with C code).
  * run-pass/union/union-basic.rs simply seems to be incorrect for
    all big-endian platforms.

Signed-off-by: Ulrich Weigand <ulrich.weigand@de.ibm.com>
2016-09-09 22:28:19 +01:00
Jorge Aparicio
43615a03f3 fix cross compilation of std 2016-08-27 01:40:29 -05:00
Brian Anderson
fce605e1f2 Remove old stage0 compatibility 2016-08-19 20:26:10 +00:00
Vadim Chugunov
6cef93d400 Implement ARM personality routine in Rust.
Remove the `eh_personality_catch` lang item.
Use a simplified version of `cfg_if!` in libunwind.
2016-07-24 01:53:27 -07:00
Vadim Chugunov
051c2d14fb Implement rust_eh_personality in Rust, remove rust_eh_personality_catch.
Well, not quite: ARM EHABI platforms still use the old scheme -- for now.
2016-07-22 14:58:35 -07:00
Tobias Bucher
81e95c18b7 Use ptr::{null, null_mut} instead of 0 as *{const, mut} 2016-07-12 10:40:40 +02:00
Srinivas Reddy Thatiparthy
00bbc27276 run rustfmt on libpanic_unwind folder 2016-06-05 23:34:23 +05:30
Alex Crichton
0ec321f7b5 rustc: Implement custom panic runtimes
This commit is an implementation of [RFC 1513] which allows applications to
alter the behavior of panics at compile time. A new compiler flag, `-C panic`,
is added and accepts the values `unwind` or `panic`, with the default being
`unwind`. This model affects how code is generated for the local crate, skipping
generation of landing pads with `-C panic=abort`.

[RFC 1513]: https://github.com/rust-lang/rfcs/blob/master/text/1513-less-unwinding.md

Panic implementations are then provided by crates tagged with
`#![panic_runtime]` and lazily required by crates with
`#![needs_panic_runtime]`. The panic strategy (`-C panic` value) of the panic
runtime must match the final product, and if the panic strategy is not `abort`
then the entire DAG must have the same panic strategy.

With the `-C panic=abort` strategy, users can expect a stable method to disable
generation of landing pads, improving optimization in niche scenarios,
decreasing compile time, and decreasing output binary size. With the `-C
panic=unwind` strategy users can expect the existing ability to isolate failure
in Rust code from the outside world.

Organizationally, this commit dismantles the `sys_common::unwind` module in
favor of some bits moving part of it to `libpanic_unwind` and the rest into the
`panicking` module in libstd. The custom panic runtime support is pretty similar
to the custom allocator support with the only major difference being how the
panic runtime is injected (takes the `-C panic` flag into account).
2016-05-09 08:22:36 -07:00