rust/src/librustc_trans/trans
Björn Steinbrink eeeb2cc0df Allow for better optimizations of iterators for zero-sized types
Using regular pointer arithmetic to iterate collections of zero-sized types
doesn't work, because we'd get the same pointer all the time. Our
current solution is to convert the pointer to an integer, add an offset
and then convert back, but this inhibits certain optimizations.

What we should do instead is to convert the pointer to one that points
to an i8*, and then use a LLVM GEP instructions without the inbounds
flag to perform the pointer arithmetic. This allows to generate pointers
that point outside allocated objects without causing UB (as long as you
don't dereference them), and it wraps around using two's complement,
i.e. it behaves exactly like the wrapping_* operations we're currently
using, with the added benefit of LLVM being able to better optimize the
resulting IR.
2015-05-15 15:30:22 +02:00
..
debuginfo Rebasing 2015-05-13 14:35:53 +12:00
_match.rs librustc_trans: Handle DST structs in trans::_match. 2015-05-03 05:36:04 -04:00
adt.rs Fix a bunch of bugs 2015-05-13 14:19:51 +12:00
asm.rs
attributes.rs Auto merge of #25085 - carols10cents:remove-old-tilde, r=steveklabnik 2015-05-11 04:46:41 +00:00
base.rs debuginfo: extract gdb.rs 2015-04-29 17:23:36 +12:00
basic_block.rs
build.rs Add singlethreaded fence intrinsics. 2015-04-25 19:41:21 -06:00
builder.rs Add singlethreaded fence intrinsics. 2015-04-25 19:41:21 -06:00
cabi_aarch64.rs Don't repeat Attribute in the const names 2015-05-05 22:03:45 -04:00
cabi_arm.rs Don't repeat Attribute in the const names 2015-05-05 22:03:45 -04:00
cabi_mips.rs Don't repeat Attribute in the const names 2015-05-05 22:03:45 -04:00
cabi_powerpc.rs Don't repeat Attribute in the const names 2015-05-05 22:03:45 -04:00
cabi_x86_64.rs Don't repeat Attribute in the const names 2015-05-05 22:03:45 -04:00
cabi_x86_win64.rs Don't repeat Attribute in the const names 2015-05-05 22:03:45 -04:00
cabi_x86.rs Don't repeat Attribute in the const names 2015-05-05 22:03:45 -04:00
cabi.rs
callee.rs Stop using Rc in TraitRef and TraitDef 2015-04-30 15:09:11 +03:00
cleanup.rs Remove schedule_free_slice 2015-05-06 17:09:55 -04:00
closure.rs
common.rs Squeeze the last bits of tasks in documentation in favor of thread 2015-05-09 02:24:18 +09:00
consts.rs Use empty() instead of a special const 2015-05-05 22:03:45 -04:00
context.rs Add intrinsics for unchecked division and modulo 2015-04-28 18:20:30 -07:00
controlflow.rs
datum.rs
declare.rs Don't repeat Attribute in the const names 2015-05-05 22:03:45 -04:00
expr.rs Rebasing 2015-05-13 14:35:53 +12:00
foreign.rs Don't repeat Attribute in the const names 2015-05-05 22:03:45 -04:00
glue.rs Fix a bunch of bugs 2015-05-13 14:19:51 +12:00
inline.rs Fix a number of bugs that interfered with cross-crate usage of associated consts. 2015-04-23 21:02:27 -06:00
intrinsic.rs Allow for better optimizations of iterators for zero-sized types 2015-05-15 15:30:22 +02:00
llrepr.rs
machine.rs Fix a bunch of bugs 2015-05-13 14:19:51 +12:00
macros.rs
meth.rs Stop using Rc in TraitRef and TraitDef 2015-04-30 15:09:11 +03:00
mod.rs
monomorphize.rs Structural changes for associated constants 2015-04-23 21:02:25 -06:00
tvec.rs
type_.rs
type_of.rs
value.rs