rustc compiler config for Vim.

Note that this is not actually *used* by default; it is a matter of
configuration still, because you might want to:

- Compile all .rs files with `rustc %` (where each can be built itself)

- Compile all .rs files with `rustc some-file.rs` (where you are editing
  part of a crate)

- Compile with a different tool, such as `make`. (In this case you might
  put a `~/.vim/after/compiler/rustc.vim` to match such cases, set
  makeprg and extend errorformat as appropriate. That should probably go
  in a different compiler mode, e.g. make-rustc.)

To try using it, `:compiler rustc`. Then, `:make` on a file you would
run `rustc` on will work its magic, invoking rustc. To automate this,
you could have something like `autocmd FileType rust compiler rustc` in
your Vim config.
extra: add tests for test::MetricMap, MetricDiff, ratchet.
extra: Add metrics functions to test.
compiletest: Add support for metrics and ratchet modes.
Add configure and make machinery to activate perf metrics and ratchets.
extra: reduce bench loop max time to 3s.
Provide more useful messages when tests are given -h or --help

Progress on #7824
Issue #7444 - Borrowck permits moved values to be captured
Issue #7444 - Update neg test and pos test for move by capture
Remove duplicated code from trans_intrinsics

Most arms of the huge match contain the same code, differing only in
small details like the name of the llvm intrinsic that is to be called.
Thus the duplicated code can be factored out into a few functions that
take some parameters to handle the differences.
Generate better code for intrinsics

Currently, our intrinsics are generated as functions that have the
usual setup, which means an alloca, and therefore also a jump, for
those intrinsics that return an immediate value. This is especially bad
for unoptimized builds because it means that an intrinsic like
"contains_managed" that should be just "ret 0" or "ret 1" actually ends
up allocating stack space, doing a jump and a store/load sequence
before it finally returns the value.

To fix that, we need a way to stop the generic function declaration
mechanism from allocating stack space for the return value. This
implicitly also kills the jump, because the block for static allocas
isn't required anymore.

Additionally, trans_intrinsic needs to build the return itself instead
of calling finish_fn, because the latter relies on the availability of
the return value pointer.

With these changes, we get the bare minimum code required for our
intrinsics, which makes them small enough that inlining them makes the
resulting code smaller, so we can mark them as "always inline" to get
better performing unoptimized builds.

Optimized builds also benefit slightly from this change as there's less
code for LLVM to translate and the smaller intrinsics help it to make
better inlining decisions for a few code paths.

Building stage2 librustc gets ~1% faster for the optimized version and 5% for
the unoptimized version.
stop initializing ref_count for stack closures

the only part of the header ~fn and &fn should be touching right now is
the tydesc
rm unused visit_str method from TyVisitor
rm unnecessary stage0 `zero_memory` fn
make: turn off --bench when running under valgrind
extra: avoid possible divide-by-zero conditions test.
auto merge of #7829 : graydon/rust/codegen-compiletests, r=cmr

This should get us over the hump of activating basic ratcheting on codegen tests, at least. It also puts in place optional (disabled by default) ratcheting on all #[bench] tests, and records all metrics from them to harvestable .json files in any case.
librustc: Add a lint mode for unnecessary `copy` and remove a bunch of them.
librustc: Remove all uses of "copy".
librustc: Remove `copy` expressions from the language.