summary refs log tree commit diff
AgeCommit message (Collapse)AuthorLines
2014-02-14mk: Move most of Makefile.in to .mk filesBrian Anderson-471/+518
Because the build system treats Makefile.in and the .mk files slightly differently (.in is copied, .mk are included), this makes the system more uniform. Fewer build system changes will require a complete reconfigure.
2014-02-14mk: Remove the concept of 'snapshot transitions'Brian Anderson-20/+0
This way of doing snapshots hasn't been used since 2011.
2014-02-14mk: Add some serious documentation and 'make help'Brian Anderson-1/+54
'make help' is implemented in a fairly ridiculous way, using awk to parse comments out of Makefile.in and displaying them.
2014-02-14auto merge of #12271 : kballard/rust/vim-extern-crate, r=huonwbors-3/+13
2014-02-14Add crate keyword to gedit language specKevin Ballard-0/+1
2014-02-14Add crate to emacs and kate modefilesKevin Ballard-0/+2
2014-02-14auto merge of #12195 : kballard/rust/rustdoc-strip-impls-of-stripped, r=cmrbors-21/+61
Strip trait impls for types that are stripped either due to the strip-hidden or strip-private passes. This fixes the search index including trait methods on stripped structs (which breaks searching), and it also removes private types from the implementors list of a trait. Fixes #9981 and #11439.
2014-02-14Update restrictions on rustdoc source renderingAlex Crichton-2/+4
The std macros used to be injected with a filename of "<std-macros>", but macros are now injected with a filename of "<{} macros>" where `{}` is filled in with the crate name. This updates rustdoc to understand this new system so it'll render source more frequently.
2014-02-14auto merge of #12267 : alexcrichton/rust/rollup, r=alexcrichtonbors-289/+415
The last commit has the closed PRs
2014-02-14Add CheckedDiv to vim syntaxKevin Ballard-1/+1
2014-02-14Update vim syntax for extern crateKevin Ballard-2/+9
2014-02-14Test fixes and rebase conflicts from rollupsAlex Crichton-2/+11
PRs closed as part of this: Closes #12212 r=alexcrichton Closes #12215 r=brson Closes #12246 r=pcwalton Closes #12247 r=cmr Closes #12251 r=brson Closes #12255 r=alexcrichton Closes #12257 r=alexcrichton Closes #12258 r=huonw Closes #12259 r=huonw Closes #12263 r=kballard Closes #12269 r=alexcrichton
2014-02-14tutorial: stronger wording in build instructionsCorey Richardson-2/+2
2014-02-14rustdoc: Strip impls of traits on #[doc(hidden)] typesKevin Ballard-19/+51
In the strip-hidden pass, record all types that were stripped, and make a second pass stripping all impls of traits for these types.
2014-02-14rustdoc: Strip impls of stripped private typesKevin Ballard-2/+10
In strip-private, also strip impls of traits for private types. This fixes the search index so searching for "drop", "eq", etc doesn't throw an exception.
2014-02-14Add MKFILE_DEPS to compiler-rt targetAlex Crichton-1/+1
Currently when you run `make -jN` it's likely that you'll remove compiler-rt and then it won't get cp'd back into the right place. I believe the reason for this is that the compiler-rt library target never got updated so make decided it never needed to copy the files back into place. The files were all there at the beginning of `make`, but then we may clean out the stage0 versions if we unzip the snapshot again.
2014-02-14auto merge of #12205 : alexcrichton/rust/nodefaultlibs, r=brsonbors-1/+24
This will hopefully bring us closer to #11937. We're still using gcc's idea of "startup files", but this should prevent us from leaking in dependencies that we don't quite want (libgcc for example once compiler-rt is what we use).
2014-02-14Invoke gcc with -nodefaultlibsAlex Crichton-1/+24
This will hopefully bring us closer to #11937. We're still using gcc's idea of "startup files", but this should prevent us from leaking in dependencies that we don't quite want (libgcc for example once compiler-rt is what we use).
2014-02-14Removed the obsolete ast::CallSugar (previously used by `do`).Eduard Burtescu-146/+79
2014-02-14Expand ItemDecorator extensions in all contextsSteven Fackler-53/+59
Now that fold_item can return multiple items, this is pretty trivial. It also recursively expands generated items so ItemDecorators can generate items that are tagged with ItemDecorators! Closes #4913
2014-02-14Add test for #8860Edward Wang-0/+60
2014-02-14Removed libextra dependency from libsyntax.HeroesGrave-6/+6
2014-02-14Add function doc comments for extra::url::*Dave Hodder-15/+46
2014-02-14Ensure an error is raised on infinite recursionFlavio Percoco-0/+24
2014-02-14Don't copy &Trait and &mut Trait to temporaries for every call.Eduard Burtescu-9/+16
2014-02-14extra: Capture stdout/stderr of tests by defaultAlex Crichton-34/+78
When tests fail, their stdout and stderr is printed as part of the summary, but this helps suppress failure messages from #[should_fail] tests and generally clean up the output of the test runner.
2014-02-14return value/use extra::test::black_box in benchmarkslpy-22/+34
2014-02-14auto merge of #12207 : alexcrichton/rust/up-llvm, r=sfacklerbors-6/+4
Includes an upstream commit by pcwalton to improve codegen of our enums getting moved around. This also introduces a new commit on top of our stack of patches to fix a mingw32 build issue. I have submitted the patch upstream: http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20140210/204653.html I verified that this builds on the try bots, which amazes me because I think that c++11 is turned on now, but I guess we're still lucky! Closes #10613 (pcwalton's patch landed) Closes #11992 (llvm has removed these options)
2014-02-14Upgrade LLVMAlex Crichton-6/+4
Includes an upstream commit by pcwalton to improve codegen of our enums getting moved around.
2014-02-14auto merge of #12234 : sfackler/rust/restructure-item-decorator, r=huonwbors-74/+76
The old method of building up a list of items and threading it through all of the decorators was unwieldy and not really scalable as non-deriving ItemDecorators become possible. The API is now that the decorator gets an immutable reference to the item it's attached to, and a callback that it can pass new items to. If we want to add syntax extensions that can modify the item they're attached to, we can add that later, but I think it'll have to be separate from ItemDecorator to avoid strange ordering issues. @huonw
2014-02-14auto merge of #12192 : luqmana/rust/fix-cross, r=alexcrichtonbors-19/+31
Fix some fall out from the big command line option changes.
2014-02-14auto merge of #12186 : alexcrichton/rust/no-sleep-2, r=brsonbors-85/+157
Any single-threaded task benchmark will spend a good chunk of time in `kqueue()` on osx and `epoll()` on linux, and the reason for this is that each time a task is terminated it will hit the syscall. When a task terminates, it context switches back to the scheduler thread, and the scheduler thread falls out of `run_sched_once` whenever it figures out that it did some work. If we know that `epoll()` will return nothing, then we can continue to do work locally (only while there's work to be done). We must fall back to `epoll()` whenever there's active I/O in order to check whether it's ready or not, but without that (which is largely the case in benchmarks), we can prevent the costly syscall and can get a nice speedup. I've separated the commits into preparation for this change and then the change itself, the last commit message has more details.
2014-02-13auto merge of #12162 : eddyb/rust/ast-map-cheap-path, r=nikomatsakisbors-2571/+1985
2014-02-14Refactored ast_map and friends, mainly to have Paths without storing them.Eduard Burtescu-2571/+1985
2014-02-13Tweak ItemDecorator APISteven Fackler-74/+76
The old method of building up a list of items and threading it through all of the decorators was unwieldy and not really scalable as non-deriving ItemDecorators become possible. The API is now that the decorator gets an immutable reference to the item it's attached to, and a callback that it can pass new items to. If we want to add syntax extensions that can modify the item they're attached to, we can add that later, but I think it'll have to be separate from ItemDecorator to avoid strange ordering issues.
2014-02-13auto merge of #12256 : brson/rust/android, r=alexcrichtonbors-19/+7
Android bot has been having some problems. A few details in the commits.
2014-02-13Stop looping on error waiting for android test resultsBrian Anderson-16/+2
These seem to be causing iloops on the bots. Let's rather see the errors.
2014-02-13compiletest: Run all android tests seriallyBrian Anderson-3/+5
This is an attempt to isolate test failures on the bots. It may also eliminate problems with the emulators breaking by reducing the chance of OOM.
2014-02-13auto merge of #12172 : alexcrichton/rust/green-improvements, r=brsonbors-141/+231
These commits pick off some low-hanging fruit which were slowing down spawning green threads. The major speedup comes from fixing a bug in stack caching where we never used any cached stacks! The program I used to benchmark is at the end. It was compiled with `rustc --opt-level=3 bench.rs --test` and run as `RUST_THREADS=1 ./bench --bench`. I chose to use `RUST_THREADS=1` due to #11730 as the profiles I was getting interfered too much when all the schedulers were in play (and shouldn't be after #11730 is fixed). All of the units below are in ns/iter as reported by `--bench` (lower is better). | | green | native | raw | | ------------- | ----- | ------ | ------ | | osx before | 12699 | 24030 | 19734 | | linux before | 10223 | 125983 | 122647 | | osx after | 3847 | 25771 | 20835 | | linux after | 2631 | 135398 | 122765 | Note that this is *not* a benchmark of spawning green tasks vs native tasks. I put in the native numbers just to get a ballpark of where green tasks are. This is benchmark is *clearly* benefiting from stack caching. Also, OSX is clearly not 5x faster than linux, I think my VM is just much slower. All in all, this ended up being a nice 4x speedup for spawning a green task when you're using a cached stack. ```rust extern mod extra; extern mod native; use std::rt::thread::Thread; #[bench] fn green(bh: &mut extra::test::BenchHarness) { let (p, c) = SharedChan::new(); bh.iter(|| { let c = c.clone(); spawn(proc() { c.send(()); }); p.recv(); }); } #[bench] fn native(bh: &mut extra::test::BenchHarness) { let (p, c) = SharedChan::new(); bh.iter(|| { let c = c.clone(); native::task::spawn(proc() { c.send(()); }); p.recv(); }); } #[bench] fn raw(bh: &mut extra::test::BenchHarness) { bh.iter(|| { Thread::start(proc() {}).join() }); } ```
2014-02-13Remove two allocations from spawning a green taskAlex Crichton-120/+175
Two unfortunate allocations were wrapping a proc() in a proc() with GreenTask::build_start_wrapper, and then boxing this proc in a ~proc() inside of Context::new(). Both of these allocations were a direct result from two conditions: 1. The Context::new() function has a nice api of taking a procedure argument to start up a new context with. This inherently required an allocation by build_start_wrapper because extra code needed to be run around the edges of a user-provided proc() for a new task. 2. The initial bootstrap code only understood how to pass one argument to the next function. By modifying the assembly and entry points to understand more than one argument, more information is passed through in registers instead of allocating a pointer-sized context. This is sadly where I end up throwing mips under a bus because I have no idea what's going on in the mips context switching code and don't know how to modify it. Closes #7767 cc #11389
2014-02-13Don't require an allocation for on_exit messagesAlex Crichton-12/+16
Instead, use an enum to allow running both a procedure and sending the task result over a channel. I expect the common case to be sending on a channel (e.g. task::try), so don't require an extra allocation in the common case. cc #11389
2014-02-13Don't allocate in LocalHeap::new()Alex Crichton-7/+8
One of these is allocated for every task, trying to cut down on allocations cc #11389
2014-02-13Fix a bug where cached stacks weren't re-usedAlex Crichton-2/+32
The condition was the wrong direction and it also didn't take equality into account. Tests were added for both cases. For the small benchmark of `task::try(proc() {}).unwrap()`, this takes the iteration time on OSX from 15119 ns/iter to 6179 ns/iter (timed with RUST_THREADS=1) cc #11389
2014-02-13auto merge of #12061 : pongad/rust/delorderable, r=cmrbors-313/+55
#12057
2014-02-13Removed num::OrderableMichael Darakananda-313/+55
2014-02-13auto merge of #12017 : FlaPer87/rust/replace-mod-crate, r=alexcrichtonbors-583/+611
The first setp for #9880 is to add a new `crate` keyword. This PR does exactly that. I took a chance to refactor `parse_item_foreign_mod` and I broke it down into 2 separate methods to isolate each feature. The next step will be to push a new stage0 snapshot and then get rid of all `extern mod` around the code.
2014-02-13auto merge of #12248 : alexcrichton/rust/rollup, r=alexcrichtonbors-398/+651
This passed `make check` locally, so hopefully it passes on bors!
2014-02-13mk: Fix non-android cross builds.Luqman Aden-19/+31
2014-02-13Rebase conflicts from this giant stack of patchesAlex Crichton-3/+3
List of PRs contained in this rollup: Closes #12167 r=alexcrichton Closes #12200 r=alexcrichton Closes #12206 r=pcwalton Closes #12209 r=huonw Closes #12211 r=pcwalton Closes #12217 r=brson Closes #12218 r=alexcrichton Closes #12220 r=alexcrichton Closes #12222 r=kballard Closes #12225 r=alexcrichton Closes #12227 r=kballard Closes #12237 r=alexcrichton Closes #12240 r=kballard
2014-02-13Lift $dst outside the closure in write!Alex Crichton-6/+36
If you were writing to something along the lines of `self.foo` then with the new closure rules it meant that you were borrowing `self` for the entirety of the closure, meaning that you couldn't format other fields of `self` at the same time as writing to a buffer contained in `self`. By lifting the borrow outside of the closure the borrow checker can better understand that you're only borrowing one of the fields at a time. This had to use type ascription as well in order to preserve trait object coercions.