Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rolling up PRs in the queue #22520

Closed
wants to merge 95 commits into from
Closed

Conversation

alexcrichton
Copy link
Member

No description provided.

fhahn and others added 30 commits February 16, 2015 20:52
No need to create a bunch of blocks and a stack allocated temporary just
to build a simple loop.
In trans_slice_vec we currently use arrayalloca, which gives us a
pointer to the element type with enough memory allocated for the
requested number of elements.  This works, but everywhere else we use
the [n x T] type for fixed size arrays and so we have to bitcast the
pointer here. Let's directly use the proper type for the allocation and
remove some code duplication along the way.
Casting the pointer to an integer requires a ptrtoint, while casting 0
to a pointer is directly folded to a `null` value.
The data pointer used in the slice is never null, using assume() to tell
LLVM about it gets rid of various unneeded null checks when iterating
over the slice.

Since the snapshot compiler is still using an older LLVM version, omit
the call in stage0, because compile times explode otherwise.

Benchmarks from rust-lang#18193
````
running 5 tests
test _range    ... bench:     33329 ns/iter (+/- 417)
test assembly  ... bench:     33299 ns/iter (+/- 58)
test enumerate ... bench:     33318 ns/iter (+/- 83)
test iter      ... bench:     33311 ns/iter (+/- 130)
test position  ... bench:     33300 ns/iter (+/- 47)

test result: ok. 0 passed; 0 failed; 0 ignored; 5 measured
````

Fixes rust-lang#18193
* cast 3-valued `core::cmp::Ordering` to `i32`, not `int`.

* use `isize`/`usize` in the impl macros.
* Use `i32` (`u32`) in doc examples, not `int` (`u32`).

* Switch impl macros to use `isize`/`usize` rather than `int`/`uint`.
…usize`.

Likewise, `fn offset` takes an `isize`.
into variance inference; fix various bugs in variance inference
so that it considers the correct set of constraints; modify infer to
consider the results of variance inference for type arguments.
…nd ownership,

and also follows the API of `NonZero` a bit more closely. More to do
here I think (including perhaps a new name).
@alexcrichton
Copy link
Member Author

@bors: r+ 8cd10ce p=100

@bors
Copy link
Contributor

bors commented Feb 19, 2015

⌛ Testing commit 8cd10ce with merge e9128cb...

@bors
Copy link
Contributor

bors commented Feb 19, 2015

💔 Test failed - auto-mac-64-nopt-t

@Manishearth
Copy link
Member

                                                                                                         ^
/Users/rustbuild/src/rust-buildbot/slave/auto-mac-64-nopt-t/build/src/libstd/os.rs:567:9: 567:28 error: use of deprecated item: use CStr::from_ptr(p).to_bytes() instead, #[deny(deprecated)] on by default
/Users/rustbuild/src/rust-buildbot/slave/auto-mac-64-nopt-t/build/src/libstd/os.rs:567         ffi::c_str_to_bytes(&*argv.offset(i as int)).to_vec()
                                                                                               ^~~~~~~~~~~~~~~~~~~

@alexcrichton
Copy link
Member Author

@bors: r+ 58000b2 p=100

@bors
Copy link
Contributor

bors commented Feb 19, 2015

⌛ Testing commit 58000b2 with merge 793f81e...

@bors
Copy link
Contributor

bors commented Feb 19, 2015

💔 Test failed - auto-mac-32-opt

@alexcrichton
Copy link
Member Author

@bors: r+ 9887263 p=100

@bors
Copy link
Contributor

bors commented Feb 19, 2015

⌛ Testing commit 9887263 with merge bd829d3...

@bors
Copy link
Contributor

bors commented Feb 19, 2015

💔 Test failed - auto-mac-32-opt

@Manishearth
Copy link
Member

Seems to be the hash table thing again cc @gankro

I'll be able to have a closer look in a couple of hours, got class.

@Manishearth
Copy link
Member

Poked at it, not really sure what it is. I'll need to dig up a 32bit system to really look at it.

@alexcrichton
Copy link
Member Author

@bors: r+ 0cd54b8 p=100

@bors
Copy link
Contributor

bors commented Feb 19, 2015

🙀 You have the wrong number! Please try again with 163be75.

@alexcrichton
Copy link
Member Author

@bors: r+ 163be75 p=100

@bors
Copy link
Contributor

bors commented Feb 19, 2015

⌛ Testing commit 163be75 with merge 3cf3483...

@bors
Copy link
Contributor

bors commented Feb 19, 2015

💔 Test failed - auto-win-32-opt

@Manishearth
Copy link
Member

I moved this to #22541

(You can push to the rollup branch on my fork to continue it)

@Gankra Gankra closed this Feb 19, 2015
bors added a commit that referenced this pull request Feb 19, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet