Erick Tryzelaar
984caa3d26
put librustrt and librustllvm in stageN dirs. Issue #438
2011-07-07 15:39:42 -07:00
Patrick Walton
deca79f372
Merge pull request #634 from robarnold/upstream-stable
...
Allocate ivecs out of the kernel pool
2011-07-07 15:18:07 -07:00
Rafael Ávila de Espíndola
5547e5dd21
Use new snapshot.
2011-07-07 17:36:23 -04:00
Brian Anderson
6ee1ffe4ac
Rename encoder::ty_str to encoded_str
2011-07-07 13:31:12 -07:00
Brian Anderson
de88739350
Don't expert def_to_str from metadata::encoder
2011-07-07 13:31:12 -07:00
Brian Anderson
7d26d1d67b
Move tyencode::ty_str to metadata::encoder
2011-07-07 13:31:12 -07:00
Brian Anderson
73963eae9a
Refactor tyencode::ty_str to not require a tyencode::ctxt
...
All users were constructing the context the same way.
2011-07-07 13:31:11 -07:00
Brian Anderson
4304f8d4f6
Remove duplicate definition of def_to_str from middle::ty
2011-07-07 13:31:11 -07:00
Brian Anderson
e29ef1bec2
Refactor a few things in the metadata module
...
Rename metadata::tags to metadata::common. Move some utility functions from
metadata::encoder to metadata::common.
2011-07-07 13:31:11 -07:00
Brian Anderson
b723082cdb
Rename hash_def_id to hash_node_id
2011-07-07 13:31:11 -07:00
Brian Anderson
d2362599d6
Remove metadata::encoder's dependence on trans::node_id_type
2011-07-07 13:31:11 -07:00
Rafael Ávila de Espíndola
83991c4c95
Add the static std library in the next snapshot.
2011-07-07 16:25:25 -04:00
Rafael Ávila de Espíndola
e440781164
Makefile support for building std static.
2011-07-07 16:07:16 -04:00
Patrick Walton
0e2fff5337
rustc: Change lots of AST nodes to use interior vectors
2011-07-07 12:53:17 -07:00
Rafael Ávila de Espíndola
bbcbaa6601
Try to fix the bots.
2011-07-07 15:28:01 -04:00
Rafael Ávila de Espíndola
77c708cdbf
Implement --lib --static.
2011-07-07 15:25:09 -04:00
Rafael Ávila de Espíndola
b13527735e
Use an early exit to reduce indentation.
2011-07-07 14:59:18 -04:00
Rafael Ávila de Espíndola
6d6c4c2a76
Command line changes for adding support for static libraries.
2011-07-07 14:42:50 -04:00
Marijn Haverbeke
16f82dce1c
Clean up trans_arg_expr
...
As a preparation for implementing the temporary-move optimization for
argument passing. The optimization itself isn't in yet, since it
mysteriously corrupts memory.
2011-07-07 17:54:58 +02:00
Marijn Haverbeke
3bdbf74d47
Make moving of temporaries do the right thing, use it to optimize
...
This adds support for dropping cleanups for temporary values when they
are moved somewhere else. It then adds wraps most copy operations
(return, put in data structure, box, etc) in a way that will fall back
to a move when it is safe.
This saves a lot of taking/dropping, shaving over a megabyte off the
stage2/rustc binary size.
In some cases, most notably function returns, we could detect that the
returned value is a local variable, and can thus be safely moved even
though it is not a temporary. This will require putting some more
information in lvals.
I did not yet handle function arguments, since the logic for passing
them looked too convoluted to touch. I'll probably try that in the
near future, since it's bound to be a big win.
2011-07-07 15:54:01 +02:00
Marijn Haverbeke
007a736642
Improve handling of move and swap by alias checker
...
Closes issue #541 .
Closes issue #591
2011-07-07 10:37:19 +02:00
Rob Arnold
f6117173c9
Allocate rust_ivec buffers out of the kernel pool
...
The duplication of upcalls is due to the fact that the runtime is
shared between stage0/rustc and stage1/rustc. Once snapshots are
updated, they should be de-duplicated.
2011-07-06 20:41:24 -07:00
Rob Arnold
2e2e1f7cb3
Add realloc method to rust_kernel
2011-07-06 20:37:27 -07:00
Lindsey Kuper
130006cdda
Tie the knot for self-calls inside extended objects. Closes #539 .
2011-07-06 18:39:01 -07:00
Brian Anderson
cf4c2ac0be
Generate a main fn for test running. Issue #428
2011-07-06 18:26:22 -07:00
Lindsey Kuper
6ca81b3407
Fix a pointer bug.
2011-07-06 17:16:54 -07:00
Lindsey Kuper
553beda96d
Add span information to create_vtbl and friends.
2011-07-06 17:16:53 -07:00
Lindsey Kuper
41f6a3d5e1
Comments and cleanup.
2011-07-06 17:16:53 -07:00
Patrick Walton
2f29f9931d
rustc: Make constraint args in the AST interior vectors
2011-07-06 16:19:19 -07:00
Patrick Walton
f164d7779a
rustc: Move AST constraints to interior vectors
2011-07-06 16:12:39 -07:00
Patrick Walton
c83782f500
rustc: Migrate core AST types to interior vectors
2011-07-06 16:01:47 -07:00
Patrick Walton
aad0bcc8d5
rustc: Make AST tuple types use interior vectors
2011-07-06 15:53:47 -07:00
Patrick Walton
401b6362d7
rustc: Make meta items into interior vectors
2011-07-06 15:46:03 -07:00
Patrick Walton
479ce4d783
rustc: Move crate directives over to interior vectors
2011-07-06 15:15:06 -07:00
Patrick Walton
0226f56115
rustc: Convert attribute in the AST to interior vectors
2011-07-06 15:15:00 -07:00
Patrick Walton
7714cb297b
rustc: Make AST paths use interior vectors
2011-07-06 15:14:52 -07:00
Patrick Walton
368f1f4ba8
rustc: Move middle::tstate::collect_locals over to interior vectors
2011-07-06 15:14:45 -07:00
Patrick Walton
b232ad94fd
rustc: Remove unused or seldom-used imports from middle::tstate::{bitvectors, ck}
2011-07-06 15:14:35 -07:00
Patrick Walton
5739e0be01
rustc: Remove some unused references to std::vec from tstate::ann and tstate::auxiliary
2011-07-06 15:14:29 -07:00
Patrick Walton
abab04635a
rustc: Move middle::tstate::auxiliary and middle::tstate::bitvectors over to interior vectors
2011-07-06 15:14:19 -07:00
Patrick Walton
6d1517cf3a
rustc: Move tstate::annotate over to interior vectors
2011-07-06 15:14:09 -07:00
Patrick Walton
35c1dbd492
rustc: Convert bind_params_in_type() to use interior vectors
2011-07-06 15:13:59 -07:00
Patrick Walton
1d57800236
rustc: Migrate tag variants to interior vectors
2011-07-06 15:13:54 -07:00
Patrick Walton
2e1aa04fcd
rustc: Make object methods into interior vectors
2011-07-06 15:13:47 -07:00
Patrick Walton
0391e14fc2
rt: Double stack size
2011-07-06 15:13:00 -07:00
Patrick Walton
91eb63eaee
rt: Add a stack check to upcall_get_type_desc
2011-07-06 15:07:04 -07:00
Brian Anderson
2f7bc90514
Add a stdtest crate to hold the standard library tests
...
This will link to std and compile with the --test flag. Eventually the
run-pass/lib* tests will move here.
We could also put the std tests directly into the library and compile both a
library version and a test version, but I think this way will make for faster
builds.
Issue #428
2011-07-06 14:39:40 -07:00
Brian Anderson
b06ccb45ab
Begin adding unit testing infrastructure to the compiler
...
Add a --test flag and a pass for transforming the AST to generate a test
harness.
Issue #428
2011-07-06 14:39:36 -07:00
Brian Anderson
0eac640fdd
Swap the expected/actual for typechecking fields of updated records
...
In 'rec(a = b with c)', if a exists in c then the expected type for b is the
type of c.
2011-07-06 14:04:52 -07:00
Patrick Walton
05954f37b7
rustc: Use an interior vector for ty::count_ty_params
2011-07-06 12:05:18 -07:00