Skip to content

Commit 8dc69ae

Browse files
committed
---
yaml --- r: 4216 b: refs/heads/master c: acac6ab h: refs/heads/master v: v3
1 parent b479448 commit 8dc69ae

File tree

723 files changed

+30217
-32047
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

723 files changed

+30217
-32047
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
---
2-
refs/heads/master: f45ac8db07d81ade3725ecd9b2cb7783051ad7df
2+
refs/heads/master: acac6abc8512971f56be7c12940c8016ae6e94ff

trunk/mk/pp.mk

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,20 @@
1+
# Create a way to reformat just some files
2+
ifdef PPFILES
3+
PP_INPUTS_FILTERED := $(wildcard $(PPFILES))
4+
else
5+
PP_INPUTS = $(wildcard $(addprefix $(S)src/lib/,*.rs */*.rs)) \
6+
$(wildcard $(addprefix $(S)src/comp/,*.rs */*.rs */*/*.rs)) \
7+
$(wildcard $(S)src/test/*/*.rs \
8+
$(S)src/test/*/*/*.rs) \
9+
$(wildcard $(S)src/fuzzer/*.rs)
110

2-
PP_INPUTS = $(wildcard $(addprefix $(S)src/lib/,*.rs */*.rs)) \
3-
$(wildcard $(addprefix $(S)src/comp/,*.rs */*.rs */*/*.rs)) \
4-
$(wildcard $(S)src/test/*/*.rs \
5-
$(S)src/test/*/*/*.rs)
6-
7-
PP_INPUTS_FILTERED = $(shell echo $(PP_INPUTS) | xargs grep -L no-reformat)
11+
PP_INPUTS_FILTERED = $(shell echo $(PP_INPUTS) | xargs grep -L no-reformat)
12+
endif
813

914
reformat: $(SREQ1)
1015
@$(call E, reformat [stage1]: $@)
1116
for i in $(PP_INPUTS_FILTERED); \
12-
do $(call CFG_RUN_TARG,stage0,stage1/rustc$(X)) \
17+
do $(call CFG_RUN_TARG,stage1,stage1/rustc$(X)) \
1318
--pretty normal $$i >$$i.tmp; \
1419
if cmp --silent $$i.tmp $$i; \
1520
then echo no changes to $$i; rm $$i.tmp; \

trunk/mk/rustllvm.mk

Lines changed: 3 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -2,39 +2,22 @@
22
# rustc LLVM-extensions (C++) library variables and rules
33
######################################################################
44

5-
RUSTLLVM_LIB_CS := $(addprefix rustllvm/, Passes.cpp)
6-
7-
RUSTLLVM_OBJS_CS := $(addprefix rustllvm/, RustWrapper.cpp)
5+
RUSTLLVM_OBJS_CS := $(addprefix rustllvm/, Passes.cpp RustWrapper.cpp)
86

97
RUSTLLVM_DEF := rustllvm/rustllvm$(CFG_DEF_SUFFIX)
108

119
RUSTLLVM_INCS := -iquote $(CFG_LLVM_INCDIR) \
1210
-iquote $(S)src/rustllvm/include
13-
RUSTLLVM_LIB_OBJS := $(RUSTLLVM_LIB_CS:.cpp=.o)
1411
RUSTLLVM_OBJS_OBJS := $(RUSTLLVM_OBJS_CS:.cpp=.o)
1512

16-
17-
# FIXME: Building a .a is a hack so that we build with both older and newer
18-
# versions of LLVM. In newer versions some of the bits of this library are
19-
# already in LLVM itself, so they are skipped.
20-
rustllvm/rustllvmbits.a: $(RUSTLLVM_LIB_OBJS)
21-
@$(call E, archive: $@)
22-
$(Q)rm -f $@
23-
$(Q)$(CFG_GCCISH_CROSS)ar crs $@ $^
24-
$(Q)$(CFG_GCCISH_CROSS)ranlib $@
25-
26-
# Note: We pass $(CFG_LLVM_LIBS) twice to fix the windows link since
27-
# it has no -whole-archive.
28-
rustllvm/$(CFG_RUSTLLVM): rustllvm/rustllvmbits.a $(RUSTLLVM_OBJS_OBJS) \
13+
rustllvm/$(CFG_RUSTLLVM): $(RUSTLLVM_OBJS_OBJS) \
2914
$(MKFILES) $(RUSTLLVM_DEF)
3015
@$(call E, link: $@)
3116
$(Q)$(call CFG_LINK_C,$@,$(RUSTLLVM_OBJS_OBJS) \
3217
$(CFG_GCCISH_PRE_LIB_FLAGS) $(CFG_LLVM_LIBS) \
33-
$(CFG_GCCISH_POST_LIB_FLAGS) rustllvm/rustllvmbits.a \
34-
$(CFG_LLVM_LIBS) \
18+
$(CFG_GCCISH_POST_LIB_FLAGS) \
3519
$(CFG_LLVM_LDFLAGS),$(RUSTLLVM_DEF))
3620

37-
3821
rustllvm/%.o: rustllvm/%.cpp $(MKFILES)
3922
@$(call E, compile: $@)
4023
$(Q)$(call CFG_COMPILE_C, $@, $(CFG_LLVM_CXXFLAGS) $(RUSTLLVM_INCS)) $<

trunk/mk/snap.mk

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11

2-
snap-stage1: stage1/rustc$(X) stage1/lib/glue.o stage1/lib/$(CFG_STDLIB) \
3-
stage1/lib/libstd.rlib stage1/lib/$(CFG_RUNTIME) \
2+
snap-stage1: stage1/rustc$(X) stage1/lib/glue.o stage1/lib/$(CFG_RUNTIME) \
43
stage1/$(CFG_RUSTLLVM)
54
$(S)src/etc/make-snapshot.py stage1
65

trunk/src/comp/back/abi.rs

Lines changed: 57 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -2,126 +2,124 @@
22

33

44
// FIXME: Most of these should be uints.
5-
const int rc_base_field_refcnt = 0;
5+
const rc_base_field_refcnt: int = 0;
66

77

88
// FIXME: import from std::dbg when imported consts work.
9-
const uint const_refcount = 0x7bad_face_u;
9+
const const_refcount: uint = 0x7bad_face_u;
1010

11-
const int task_field_refcnt = 0;
11+
const task_field_refcnt: int = 0;
1212

13-
const int task_field_stk = 2;
13+
const task_field_stk: int = 2;
1414

15-
const int task_field_runtime_sp = 3;
15+
const task_field_runtime_sp: int = 3;
1616

17-
const int task_field_rust_sp = 4;
17+
const task_field_rust_sp: int = 4;
1818

19-
const int task_field_gc_alloc_chain = 5;
19+
const task_field_gc_alloc_chain: int = 5;
2020

21-
const int task_field_dom = 6;
21+
const task_field_dom: int = 6;
2222

23-
const int n_visible_task_fields = 7;
23+
const n_visible_task_fields: int = 7;
2424

25-
const int dom_field_interrupt_flag = 1;
25+
const dom_field_interrupt_flag: int = 1;
2626

27-
const int frame_glue_fns_field_mark = 0;
27+
const frame_glue_fns_field_mark: int = 0;
2828

29-
const int frame_glue_fns_field_drop = 1;
29+
const frame_glue_fns_field_drop: int = 1;
3030

31-
const int frame_glue_fns_field_reloc = 2;
31+
const frame_glue_fns_field_reloc: int = 2;
3232

33-
const int box_rc_field_refcnt = 0;
33+
const box_rc_field_refcnt: int = 0;
3434

35-
const int box_rc_field_body = 1;
35+
const box_rc_field_body: int = 1;
3636

37-
const int general_code_alignment = 16;
37+
const general_code_alignment: int = 16;
3838

39-
const int vec_elt_rc = 0;
39+
const vec_elt_rc: int = 0;
4040

41-
const int vec_elt_alloc = 1;
41+
const vec_elt_alloc: int = 1;
4242

43-
const int vec_elt_fill = 2;
43+
const vec_elt_fill: int = 2;
4444

45-
const int vec_elt_pad = 3;
45+
const vec_elt_pad: int = 3;
4646

47-
const int vec_elt_data = 4;
47+
const vec_elt_data: int = 4;
4848

49-
const int tydesc_field_first_param = 0;
49+
const tydesc_field_first_param: int = 0;
5050

51-
const int tydesc_field_size = 1;
51+
const tydesc_field_size: int = 1;
5252

53-
const int tydesc_field_align = 2;
53+
const tydesc_field_align: int = 2;
5454

55-
const int tydesc_field_copy_glue = 3;
55+
const tydesc_field_copy_glue: int = 3;
5656

57-
const int tydesc_field_drop_glue = 4;
57+
const tydesc_field_drop_glue: int = 4;
5858

59-
const int tydesc_field_free_glue = 5;
59+
const tydesc_field_free_glue: int = 5;
6060

61-
const int tydesc_field_sever_glue = 6;
61+
const tydesc_field_sever_glue: int = 6;
6262

63-
const int tydesc_field_mark_glue = 7;
63+
const tydesc_field_mark_glue: int = 7;
6464

6565

6666
// FIXME no longer used in rustc, drop when rustboot is gone
67-
const int tydesc_field_obj_drop_glue = 8;
67+
const tydesc_field_obj_drop_glue: int = 8;
6868

69-
const int tydesc_field_is_stateful = 9;
69+
const tydesc_field_is_stateful: int = 9;
7070

71-
const int tydesc_field_cmp_glue = 10;
71+
const tydesc_field_cmp_glue: int = 10;
7272

73-
const int n_tydesc_fields = 11;
73+
const n_tydesc_fields: int = 11;
7474

75-
const uint cmp_glue_op_eq = 0u;
75+
const cmp_glue_op_eq: uint = 0u;
7676

77-
const uint cmp_glue_op_lt = 1u;
77+
const cmp_glue_op_lt: uint = 1u;
7878

79-
const uint cmp_glue_op_le = 2u;
79+
const cmp_glue_op_le: uint = 2u;
8080

81-
const int obj_field_vtbl = 0;
81+
const obj_field_vtbl: int = 0;
8282

83-
const int obj_field_box = 1;
83+
const obj_field_box: int = 1;
8484

85-
const int obj_body_elt_tydesc = 0;
85+
const obj_body_elt_tydesc: int = 0;
8686

87-
const int obj_body_elt_typarams = 1;
87+
const obj_body_elt_typarams: int = 1;
8888

89-
const int obj_body_elt_fields = 2;
89+
const obj_body_elt_fields: int = 2;
9090

9191
// The base object to which an anonymous object is attached.
92-
const int obj_body_elt_with_obj = 3;
92+
const obj_body_elt_with_obj: int = 3;
9393

9494
// The two halves of a closure: code and environment.
95-
const int fn_field_code = 0;
96-
const int fn_field_box = 1;
95+
const fn_field_code: int = 0;
96+
const fn_field_box: int = 1;
9797

98-
const int closure_elt_tydesc = 0;
98+
const closure_elt_tydesc: int = 0;
9999

100-
const int closure_elt_target = 1;
100+
const closure_elt_bindings: int = 1;
101101

102-
const int closure_elt_bindings = 2;
102+
const closure_elt_ty_params: int = 2;
103103

104-
const int closure_elt_ty_params = 3;
104+
const ivec_default_length: uint = 4u;
105105

106-
const uint ivec_default_length = 4u;
106+
const ivec_elt_len: uint = 0u;
107107

108-
const uint ivec_elt_len = 0u;
108+
const ivec_elt_alen: uint = 1u;
109109

110-
const uint ivec_elt_alen = 1u;
110+
const ivec_elt_elems: uint = 2u;
111111

112-
const uint ivec_elt_elems = 2u;
112+
const ivec_heap_stub_elt_zero: uint = 0u;
113113

114-
const uint ivec_heap_stub_elt_zero = 0u;
114+
const ivec_heap_stub_elt_alen: uint = 1u;
115115

116-
const uint ivec_heap_stub_elt_alen = 1u;
116+
const ivec_heap_stub_elt_ptr: uint = 2u;
117117

118-
const uint ivec_heap_stub_elt_ptr = 2u;
118+
const ivec_heap_elt_len: uint = 0u;
119119

120-
const uint ivec_heap_elt_len = 0u;
120+
const ivec_heap_elt_elems: uint = 1u;
121121

122-
const uint ivec_heap_elt_elems = 1u;
123-
124-
const int worst_case_glue_call_args = 7;
122+
const worst_case_glue_call_args: int = 7;
125123

126124
fn memcpy_glue_name() -> str { ret "rust_memcpy_glue"; }
127125

0 commit comments

Comments
 (0)