Commit Graph

68459 Commits

Author SHA1 Message Date
steveklabnik
1bbf41da6f update mdbook
Fixes #44704
2017-10-02 10:16:32 -04:00
Michael Woerister
dbab705f04 incr.comp.: Do some cleanup. 2017-10-02 16:09:23 +02:00
Michael Woerister
df06a7e532 incr.comp.: Remove legacy dep-graph runtime. 2017-10-02 16:09:19 +02:00
Vitaly _Vi Shukela
acef039de8
rustdoc: Remove cruft from the test
per @GuillaumeGomez's sample, but with one change.
2017-10-02 16:54:35 +03:00
Michael Woerister
171c020857 incr.comp.: Remove saving and loading of legacy dep-graph. 2017-10-02 15:47:11 +02:00
Michael Woerister
272c324b25 incr.comp.: Build DepGraphQuery from new dep-graph impl. 2017-10-02 15:45:46 +02:00
Michael Woerister
e6badfd449 incr.comp.: Use red/green tracking for CGU re-use. 2017-10-02 15:45:46 +02:00
Michael Woerister
c9a17ef174 incr.comp.: Add some logging to DepGraph::try_mark_green(). 2017-10-02 15:38:57 +02:00
Michael Woerister
e1994bd27b incr.comp.: Make some DepNodes non-anonymous. 2017-10-02 15:38:57 +02:00
Michael Woerister
f0bbf4e1f2 incr.comp.: Re-execute queries during red/green marking in order to find out their color. 2017-10-02 15:38:57 +02:00
Michael Woerister
6db27d9f90 incr.comp.: Add minimal version of try_mark_green procedure. 2017-10-02 15:36:47 +02:00
Michael Woerister
a948be81cd incr.comp.: Determine red/green state of every new node. 2017-10-02 15:36:47 +02:00
Alex Burka
fc5e8dc1b5 fix comment on DefaultImpl 2017-10-02 07:30:09 -04:00
bors
0f0f5db465 Auto merge of #44959 - arielb1:generic-errors, r=eddyb
handle nested generics in Generics::type_param/region_param

Fixes #44952.

r? @eddyb
2017-10-02 10:06:32 +00:00
Alex Burka
5517a1ce79 fix ItemKind::DefaultImpl doc comment
Upgrade comment to doc comment.
2017-10-02 05:59:56 -04:00
Ariel Ben-Yehuda
706e52e2cc fix handling of Self 2017-10-02 10:43:36 +02:00
bors
9ae6ed78ac Auto merge of #44942 - zackmdavis:lint_suggestions, r=estebank
code suggestions for unused-mut, while-true, deprecated-attribute, and unused-parens lints

![lint_suggestions](https://user-images.githubusercontent.com/1076988/31044068-b2074de8-a57c-11e7-9319-6668508b6d1f.png)

r? @estebank
2017-10-02 07:03:26 +00:00
Zack M. Davis
8a14022c5d correct unused-parens lint suggestion to strip exact pair 2017-10-01 20:15:24 -07:00
bors
2146c613d1 Auto merge of #44960 - SeanPrashad:master, r=steveklabnik
Resolves #36284 - vec.rs documentation

Removed comments associated with `[into_vec]` being equivalent to `[shrink_to_fit]` as requested.
2017-10-02 02:17:14 +00:00
Zack M. Davis
b989101a55 make non_snake_case lint allow extern no-mangle functions
Resolves #31924.
2017-10-01 17:20:06 -07:00
Michal Budzynski
e6c3c7f2dc Corrected the CONTRIBUTING.md "External Dependencies" section 2017-10-02 00:18:19 +02:00
bors
a4af9309d0 Auto merge of #44955 - laumann:small-typo-fix, r=steveklabnik
Fix typo: geneartor -> generator
2017-10-01 22:16:04 +00:00
Ariel Ben-Yehuda
ad9986605f fix handling of Self 2017-10-01 23:03:48 +02:00
bors
f1b5225e8b Auto merge of #44919 - diwic:79-pretty-mir, r=arielb1
Mir pretty print: Add cleanup comment

I found it useful to add a comment indicating whether or not a
BasicBlock is a cleanup block or not. Hopefully you'll find it
useful too.
2017-10-01 19:57:01 +00:00
bors
cef4a3ebfa Auto merge of #44897 - Havvy:doc-size_of, r=steveklabnik
Docs for size_of::<#[repr(C)]> items.

Most of this info comes from camlorn's blog post on optimizing struct layout and the Rustonomicon.

I don't really like my wording in the first paragraph.

I also cannot find a definition of what `#[repr(C)]` does for enums that have variants with fields. They're allowed, unlike `#[repr(C)] enum`s with no variants.
2017-10-01 17:32:34 +00:00
Sean Prashad
1ebc7bba79 Resolves #36284 - vec.rs documentation 2017-10-01 12:15:05 -04:00
Ariel Ben-Yehuda
622a78cd54 handle nested generics in Generics::type_param/region_param
Fixes #44952.
2017-10-01 17:15:15 +02:00
Douglas Campos
11e141eba3 stray comma 2017-10-01 11:14:47 -04:00
Thomas Jespersen
30b19c9e8b Fix typo: geneartor -> generator 2017-10-01 15:40:00 +02:00
bors
3651cddc44 Auto merge of #44945 - petrochenkov:fixtyrec, r=arielb1
Do not require semantic types for all syntactic types when there are errors

Fixes https://github.com/rust-lang/rust/issues/44814
Fixes https://github.com/rust-lang/rust/issues/44858
Fixes https://github.com/rust-lang/rust/issues/44946
r? @nikomatsakis
2017-10-01 13:26:15 +00:00
Vitaly _Vi Shukela
67c9af590d
rustdoc: Style of [src] link for trait implementors
A change suggested by @GuillaumeGomez and @QuietMisdreavus.

Also slight reindenting of the appropriate CSS section.
2017-10-01 16:20:56 +03:00
bors
0defa208dc Auto merge of #44906 - dkl:main-signature, r=nagisa
Fix native main() signature on 64bit

Hello,

in LLVM-IR produced by rustc on x86_64-linux-gnu, the native main() function had incorrect types for the function result and argc parameter: i64, while it should be i32 (really c_int). See also #20064, #29633.

So I've attempted a fix here. I tested it by checking the LLVM IR produced with --target x86_64-unknown-linux-gnu and i686-unknown-linux-gnu. Also I tried running the tests (`./x.py test`), however I'm getting two failures with and without the patch, which I'm guessing is unrelated.
2017-10-01 09:14:53 +00:00
bors
1c09315f6d Auto merge of #44921 - est31:master, r=alexcrichton
Update the libcompiler_builtins submodule

Pulls in the latest changes from libcompiler_builtins.

It should work, but it would be best if this wouldn't get put into a rollup so that bisecting is possible if there is a regression.

r? @alexcrichton
2017-10-01 01:41:42 +00:00
Daniel Klauer
a4e83731e9 test: Update target specs test for new target-c-int-width field 2017-09-30 23:45:36 +02:00
bors
afe9320785 Auto merge of #44944 - dbrgn:trace-macros-docs, r=QuietMisdreavus
Docs: Add trace_macros! to unstable book

As TIL'd at Rustfest :)

Note: This is unfortunately untested, since I'm on my laptop battery, and compiling LLVM would probably eat at least 50% of it on my dual core CPU. (Is there a way to build docs without compiling LLVM?)
2017-09-30 20:46:57 +00:00
Zack M. Davis
e3b498971d code suggestions for unused-mut, while-true lints; UI test 2017-09-30 11:31:12 -07:00
Zack M. Davis
5c9f806d78 code suggestion for unused-parentheses lint
Resolves #42892.
2017-09-30 11:31:12 -07:00
Zack M. Davis
f2c5acd611 code suggestion for deprecated-attribute lint
Also, fix the deprecation message for the late no-debug feature.
2017-09-30 11:31:12 -07:00
QuietMisdreavus
5b59c4db67 let htmldocck.py check for directories 2017-09-30 13:28:09 -05:00
Douglas Campos
b24a672613 weird formatting 2017-09-30 11:08:08 -04:00
bors
c6884b12d9 Auto merge of #44783 - alexcrichton:lto-codegen-units, r=michaelwoerister
rustc: Enable LTO and multiple codegen units

This commit is a refactoring of the LTO backend in Rust to support compilations
with multiple codegen units. The immediate result of this PR is to remove the
artificial error emitted by rustc about `-C lto -C codegen-units-8`, but longer
term this is intended to lay the groundwork for LTO with incremental compilation
and ultimately be the underpinning of ThinLTO support.

The problem here that needed solving is that when rustc is producing multiple
codegen units in one compilation LTO needs to merge them all together.
Previously only upstream dependencies were merged and it was inherently relied
on that there was only one local codegen unit. Supporting this involved
refactoring the optimization backend architecture for rustc, namely splitting
the `optimize_and_codegen` function into `optimize` and `codegen`. After an LLVM
module has been optimized it may be blocked and queued up for LTO, and only
after LTO are modules code generated.

Non-LTO compilations should look the same as they do today backend-wise, we'll
spin up a thread for each codegen unit and optimize/codegen in that thread. LTO
compilations will, however, send the LLVM module back to the coordinator thread
once optimizations have finished. When all LLVM modules have finished optimizing
the coordinator will invoke the LTO backend, producing a further list of LLVM
modules. Currently this is always a list of one LLVM module. The coordinator
then spawns further work to run LTO and code generation passes over each module.

In the course of this refactoring a number of other pieces were refactored:

* Management of the bytecode encoding in rlibs was centralized into one module
  instead of being scattered across LTO and linking.
* Some internal refactorings on the link stage of the compiler was done to work
  directly from `CompiledModule` structures instead of lists of paths.
* The trans time-graph output was tweaked a little to include a name on each
  bar and inflate the size of the bars a little
2017-09-30 15:01:35 +00:00
petrochenkov
8037c28a4a Do not require semantic types for all syntactic types when there are type errors 2017-09-30 17:41:00 +03:00
Daniel Klauer
12a8bc6eb9 rustc: Use 16bit c_int for msp430
Fix regression from c2fe69b9, where main() signature was changed from
using 16bit isize to 32bit c_int for argc parameter/result.
2017-09-30 16:30:12 +02:00
Nikolai Vazquez
f1798d3c9a Cast inner type in OsStr::bytes
The innermost type is not [u8] on all platforms but is assumed to have
the same memory layout as [u8] since this conversion was done via
mem::transmute before.
2017-09-30 10:01:41 -04:00
Daniel Klauer
a204c193ca rustc: Specify c_int width for each target
(all i32 for now, as in liblibc)
2017-09-30 15:54:08 +02:00
Danilo Bargen
eb59952fbd Docs: Add trace_macros! to unstable book 2017-09-30 15:27:42 +02:00
Niv Kaminer
5eebab28dd remove "refinement on pat" FIXME 2017-09-30 13:46:57 +03:00
Aaron Power
7ed23f1349 Update RELEASES.md 2017-09-30 11:36:49 +01:00
bors
c4cca3a72d Auto merge of #44936 - Mark-Simulacrum:rollup, r=Mark-Simulacrum
Rollup of 15 pull requests

- Successful merges: #44124, #44287, #44320, #44694, #44708, #44794, #44797, #44824, #44836, #44840, #44845, #44854, #44889, #44900, #44903
- Failed merges:
2017-09-30 10:03:00 +00:00
Niv Kaminer
ff99111f48 address some FIXMEs whose associated issues were marked as closed
remove FIXME(#13101) since `assert_receiver_is_total_eq` stays.
remove FIXME(#19649) now that stability markers render.
remove FIXME(#13642) now the benchmarks were moved.
remove FIXME(#6220) now that floating points can be formatted.
remove FIXME(#18248) and write tests for `Rc<str>` and `Rc<[u8]>`
remove reference to irelevent issues in FIXME(#1697, #2178...)
update FIXME(#5516) to point to getopts issue 7
update FIXME(#7771) to point to RFC 628
update FIXME(#19839) to point to issue 26925
2017-09-30 11:33:47 +03:00