aboutsummaryrefslogtreecommitdiff
path: root/gcc/ChangeLog.rewrite
blob: 85d15d9496ef5cec8073fbaf016aeab40b59ec1a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
2003-02-12  Richard Sandiford  <rsandifo@redhat.com>

	* config/mips/mips.c (mips_legitimize_const_move): New, extracted
	from mips_legitimize_move.  Legitimize constant pool references.
	(mips_legitimize_move): Call mips_legitimize_const_move.  Attach
	a REG_EQUAL note to the last instruction.

2003-02-11  Richard Sandiford  <rsandifo@redhat.com>

	* config/mips/mips-protos.h (mips_simplify_dwarf_addr): Declare.
	* config/mips/mips.h (TARGET_EXPLICIT_RELOCS, TARGET_NEWABI): New.
	(ASM_SIMPLIFY_DWARF_ADDR): Define to mips_simplify_dwarf_addr.
	(EXTRA_CONSTRAINT): Allow symbolic call addresses for TARGET_ABICALLS.
	* config/mips/mips.md (UNSPEC_HIGH): New constant.
	(UNSPEC_RELOC_GPREL16): Rename to...
	(RELOC_GPREL16): ...this.
	(RELOC_GOT_HI, RELOC_GOT_LO, RELOC_GOT_PAGE, RELOC_GOT_DISP): New.
	(RELOC_CALL16, RELOC_CALL_HI, RELOC_CALL_LO): New.
	(macro_calls): New attribute.
	(length): Use it to set the default length of calls.  Don't allow
	calls to have delay slots if macro_calls is "yes".
	(luisi, luidi): New patterns.
	(lowsi, lowdi): Use '%R' to print the relocation.
	(lowdi_extend): Remove.
	(loadgp): Remove mode from operand 0.  Use '%0' instead of '%a0'.
	(call_internal): Merge alternatives.  Always use "jal".
	(call_value_internal, call_value_multiple_internal): Likewise.
	(reloc_gprel16): Remove.
	* config/mips/mips.c (mips_got_alias_set): New variable.
	(mips_classify_constant): Handle the new relocation constants.
	(mips_classify_symbol): Reverse the sense of SYMBOL_REF_FLAG for PIC.
	(mips_symbolic_address_p): Return false if generating explicit relocs.
	Otherwise allow local PIC symbols to have an offset.
	(mips_splittable_symbol_p): New function.
	(mips_classify_address): Use it to check whether a LO_SUM is valid.
	(mips_const_insns): Always accept HIGH.
	(call_insn_operand): Don't accept global symbols if using explicit
	relocs.
	(move_operand): Don't accept HIGH when generating PIC.
	(mips_reloc, mips_lui_reloc): New functions.
	(mips_force_temporary): Remove MODE argument.  Expect VALUE to
	be a valid right-hand-side for a SET pattern.
	(mips_load_got, mips_load_got16, mips_load_got32): New functions.
	(mips_emit_high): New function.
	(mips_legitimize_symbol): Use mips_reloc for the mips16 gp-relative
	case.  Use mips_splittable_symbol_p to check whether a LO_SUM
	address should be used.  Use mips_emit_high to generate the
	high part of such an address.  Adjust the global symbol + offset
	case to match the change to mips_force_temprorary.
	(mips_legitimize_move): Shuffle call to mips_legitimize_symbol.
	If generating explicit-reloc PIC, load the address of global
	symbols from the GOT.  Use mips_emit_high to emit the high part
	of an address.
	(mips_simplify_dwarf_addr): New function.
	(mips_move_1word): Use lwc1 instead of l.s and swc1 instead of s.s.
	(mips_move_2words): Likewise ldc1/l.d and sdc1/s.d if TARGET_64BIT.
	(mips_expand_call): Load the addresses of global functions using
	%call* relocs if generating explicit-reloc PIC.  Don't generate
	an exception_receiver pattern.
	(override_options): Initialize mips_got_alias_set.
	(print_relocation): Remove in favour of...
	(mips_reloc_string): ...this new function.
	(print_operand): Handle '%R'.  Use mips_reloc_string.
	(print_operand_address): Use print_operand to print the symbolic
	part of a LO_SUM address.
	(mips_output_function_prologue): Use .cprestore, reverting last patch.
	(mips_encode_section_info): Factor out DECL_RTL accesses.  Reverse
	sense of SYMBOL_REF_FLAG for PIC, using binds_local_p to check
	for local symbols.

2003-02-02  Eric Christopher  <echristo@redhat.com>

	* config/mips/mips.c (mips_sign_extend): Remove.
	* config/mips/mips-protos.h: Ditto.
	* config/mips/mips.md (movdi_internal2_extend): Remove.
	(extendsidi2): Fix mode of convert_memory_address.

2003-01-24  Eric Christopher  <echristo@redhat.com>

	* config/mips/mips.md: Rewrite zero_extend* and extend*
	patterns. Use explicit instructions and split after reload
	for register extensions.
	(ashlsi3_internal1_extend): New combiner pattern for
	shift and extend combinations.
	* config/mips/mips.h: Change Pmode back to ptr_mode
	for performance enhancement.
	* combine.c (expand_compound_operation): Make sure
	that zero_extend operation is profitable.

2003-01-14  Richard Sandiford  <rsandifo@redhat.com>

	* config/mips/mips.h (TRAMPOLINE_TEMPLATE): Make size of stored
	addresses depend on ptr_mode rather than Pmode.
	(TRAMPOLINE_SIZE, TRAMPOLINE_ALIGNMENT): Update acoordingly.
	(INITIALIZE_TRAMPOLINE): Rework to handle Pmode != ptr_mode.
	(CASE_VECTOR_MODE): Use ptr_mode for !TARGET_MIPS16.
	(ASM_OUTPUT_ADDR_VEC_ELT): Update accordingly.
	* config/mips/mips.md (tablejump): Likewise.  Remove Pmode
	condition for selecting cpaddsi or cpadddi: use cpadd instead.
	(tablejump_internal1): Remove condition.
	(tablejump_internal2): Change condition to TARGET_64BIT.
	(cpaddsi): Rename to...
	(cpadd): ...this.
	(cpadddi): Remove.

2003-01-09  Richard Sandiford  <rsandifo@redhat.com>

	* config/mips/mips-protos.h (mips16_constant_after_function_p,
	mips_address_cost, mips_check_split, double_memory_operand,
	mips16_gp_offset, mips16_gp_offset_p, mips16_constant,
	pic_address_needs_scratch, symbolic_operand): Remove declarations.
	(mips_legitimate_address_p): Return bool.
	(mips_address_insns, mips_fetch_insns, mips_const_insns,
	mips_legitimize_address, mips_legitimize_move,
	mips_expand_call): Declare.
	(mips_return_addr): Move outside #ifdef RTX_CODE.

	* config/mips/mips.h (ABI_HAS_64BIT_SYMBOLS): New macro.
	(PIC_FN_ADDR_REG): New reg_class.
	(REG_CLASS_NAMES, REG_CLASS_CONTENTS): Add corresponding entries.
	(GR_REG_CLASS_P): True for PIC_FN_ADDR_REG.
	(SMALL_OPERAND, SMALL_OPERAND_UNSIGNED, LUI_OPERAND,
	CONST_HIGH_PART, CONST_LOW_PART, LUI_INT): New macros.
	(SMALL_INT, SMALL_INT_UNSIGNED, CONST_OK_FOR_LETTER_P): Use new macros.
	(EXTRA_CONSTRAINTS): Give new meanings to Q, R and S.
	(CONSTANT_ADDRESS_P): Use mips_legitimate_address_p.
	(LEGITIMATE_PIC_OPERAND): Undefine.
	(LEGITIMATE_CONSTANT_P): Use mips_const_insns.
	(LEGITIMIZE_ADDRESS): Use mips_legitimize_address.
	(CONSTANT_AFTER_FUNCTION_P): Remove definition in #if 0 block.
	(FUNCTION_MODE): Change to SImode.
	(CONST_COSTS): Use mips_const_insns to calculate the cost of
	most constants.  Treat const_artih_operands specially if they
	occur in a PLUS or MINUS.
	(CONSTANT_POOL_COST): New macro.
	(RTX_COSTS): Use mips_address_insns for MEMs, with a base cost of 2.
	Add LO_SUM handling.
	(ADDRESS_COST): Undefine.
	(PREDICATE_CODES): Add symbolic_operand and const_arith_operand.
	Add CONST to the list of codes for arith_operand.  Add LABEL_REF
	to call_insn_operand and remove CONST_INT.

	* config/mips/mips.c: Include integrate.h.
	(SINGLE_WORD_MODE_P): New macro.
	(mips_constant_type, mips_symbol_type, mips_address_type): New enums.
	(mips_constant_info, mips_address_info): New structs.
	(mips_regno_to_class): Map $25 to PIC_FN_ADDR_REG.
	(mips_classify_constant, mips_classify_symbol,
	mips_valid_base_register_p, mips_symbolic_address_p,
	mips_classify_address, mips_symbol_insns,
	mips16_unextended_reference_p, mips_address_insns, mips_const_insns,
	mips_fetch_insns, mips_force_temporary, mips_add_offset,
	mips_legitimize_symbol, mips_legitimize_address, mips_legitimize_move,
	mips_print_relocation): New functions.
	(const_arith_operand): New operand predicate.
	(arith_operand): Use it.
	(mips_const_double_ok, mips16_simple_memory_operand,
	simple_memory_operand, double_memory_operand, mips_check_split,
	mips_address_cost, pic_address_needs_scratch, mips16_gp_offset,
	mips16_gp_offset_p, mips16_output_gp_offset,
	mips16_constant_after_function_p, mips16_constant): Remove.
	(call_insn_operand): Be more fussy about symbolic constants.
	Use register_operand.
	(move_operand): Use mips_symbolic_address_p to check symbolic
	operands and general_operand to check the rest.
	(symbolic_operand): Use mips_classify_constant.
	(mips_legitimate_address_p): Use mips_classify_address.
	(mips_move_1word): Combine handling of symbolic addresses.
	Remove special treatment of gp-relative loads for TARGET_MIPS16.
	(move_move_2words): Likewise.  Assume addresses are offsettable
	if they need to refer to more than one word.  Add HIGH handling.
	(mips_restore_gp): Use ptr_mode for the GP save slot.
	(mips_expand_call): New function, combining the old mips.md
	call and call_internal define_expands.  If the address isn't
	a call_insn_operand, force it into a register.  For SVR4 PIC,
	emit an exception_receiver instruction after the call.
	(override_options): Only override flag_pic for TARGET_ABICALLS
	if it is currently zero.  Allow mips_split_addresses when
	Pmode == DImode too, except when ABI_HAS_64BIT_SYMBOLS.
	Add new register class letter, 'c'.
	(print_operand): Use mips_classify_constant for constant operands.
	(print_operand_address): Use mips_classify_address.
	(mips_output_function_prologue): Don't use .cprestore.
	(mips_expand_epilogue): For TARGET_MIPS16, only adjust the stack
	via the frame pointer if current_function_calls_eh_return.
	(mips_encode_section_info): For TARGET_ABICALLS, use SYMBOL_REF_FLAG
	to mark whether a symbol is local or global.
	(build_mips16_call_stub): Expect the address of the function rather
	than a MEM reference to it.  Update call generation sequences.
	(mips16_optimize_gp): Remove Pmode checks.  Temporarily disable
	small-data adjustments.

	* config/mips/mips.md: Remove 'R'/'m' memory distinction.  Use default
	length for loads and stores.
	(UNSPEC_CPADD, UNSPEC_RELOC_GPREL16): New constants.
	(define_attr type): Add const and prefetch.
	(define_attr length): Use mips_const_insns for const instructions.
	Use mips_fetch_insns for load and store instructions.
	(define_attr single_insn): New.
	(define_attr can_delay): Use it.
	(define_attr abicalls): Remove.
	(define_delay): Use can_delay.  Always allow calls to have delay slots.
	(addsi3_internal_2): Add 'Q' constraint.
	(movsi_ulw, movsi_usw, movdi_uld, movdi_usd): Set length to 8.
	(high): Remove.
	(lowsi): Renamed from low.
	(lowdi): New pattern.
	(movdi, movsi): Use mips_legitimize_move.  Remove define_split.
	(lwxc1, ldxc1, swxc1, sdxc1): Set length to 4.
	(loadgp): Change operand 0 to an immediate_operand.
	(tablejump): Use the same patterns for SVR4 PIC but emit a cpadd
	beforehand.
	(cpaddsi, cpadddi): New patterns.
	(tablejump_internal3, tablejump_internal4): Remove define_expands
	and associated define_splits.
	(call, call_value): Use mips_expand_call.
	(call_internal): New, replacing all existing call_internal* insns.
	(call_value_internal): Likewise call_value_internal*.
	(call_value_multiple_internal): Likewise call_value_multiple_internal*.
	(untyped_call): Remove if (operands[0]) magic.
	(prefetch_si_address, prefetch_si): Change type to "prefetch".
	(prefetch_di_address, prefetch_di): Likewise.
	(leasi, leadi): Remove.
	(reloc_gprel16): New.

	* config/mips/5400.md (ir_vr54_hilo): Include const type.
	* config/mips/5500.md (ir_vr55_hilo): Likewise.
	* config/mips/sr71k.md (ir_sr70_hilo): Likewise.

2003-01-08  Eric Christopher  <echristo@redhat.com>

	* config.gcc (mipsisa32*): Change ABI_MEABI to ABI_EABI.
	* config/mips/elf.h (STARTFILE_SPEC): Remove ABI_MEABI references and
	configure check for libgloss.
	* config/mips/elf64.h: Ditto.
	* config/mips/mips.c: Remove ABI_MEABI.
	* config/mips/mips.h: Ditto.

2002-11-05  Richard Sandiford  <rsandifo@redhat.com>

	Fix merge fallout.
	* config/mips/mips.md (mul_acc_si): Reapply 2002-10-16 change.
	(muldi3_internal): Remove outdated comment.
	(*muls_di, *umuls_di): Fix comment and 64-bitness.
	(*smsac_di, *umsac_di): Likewise.  Reformat.
	(umulsi3_highpart): Minor formatting tweaks.
	(umulsi3_highpart_internal): Use only if !ISA_HAS_MULHI.  Remove
	redundant scratch operand.  Minor formatting tweak.
	(umulsi3_highpart_mulhi_internal): Use for !TARGET_64BIT as well.
	(umulsi3_highpart_neg_mulhi_internal): Likewise.  Fix asm template.
	(smulsi3_highpart): As for the unsigned version.
	(smulsi3_highpart_internal): Likewise.
	(smulsi3_highpart_mulhi_internal): Likewise.
	(smulsi3_highpart_neg_mulhi_internal): Likewise.
	(smuldi3_highpart, umuldi3_highpart): Minor formatting tweaks.
	(*smul_acc_di): Remove duplicated pattern.
	(*umul_acc_di, *smul_acc_di): Reapply 2002-10-16 change.
	(anddi3) [unnamed mips16 pattern]: Remove reintroduced length.
	(zero_extendsidi2_internal2): Remove new, but commented-out pattern.

2002-10-22  Eric Christopher  <echristo@redhat.com>

        * config/mips/mips-protos.h (mips_return_addr): New.
        * config/mips/mips.c (mips_return_addr): New.
        (movdi_operand): Remove.
        (se_register_operand): Ditto.
        (se_reg_or_0_operand): Ditto.
        (se_uns_arith_operand): Ditto.
        (se_arith_operand): Ditto.
        (se_nonmemory_operand): Ditto.
        (extend_operator): Ditto.
        (highpart_shift_operator): Ditto.
        (mips_initial_elimination_offset): Remove return address pointer
        elimination.
        (mips_reg_names): Remove $ra.
        (mips_regno_to_class): Ditto.
        * config/mips/mips.h (POINTER_SIZE): Define based on TARGET_LONG64
        and TARGET_64BIT.
        (POINTER_BOUNDARY): Remove.
        (POINTERS_EXTEND_UNSIGNED): Define to 0.
        (PROMOTE_MODE): Promote to Pmode.
        (SHORT_IMMEDIATES_SIGN_EXTEND): Define.
        (Pmode): Define to TARGET_64BIT.
        (FUNCTION_MODE): Define as Pmode.
        (mips_args): Remove deleted functions.
        (SIZE_TYPE): Depend on POINTER_SIZE.
        (PTRDIFF_TYPE): Ditto.
        (FIXED_REGISTERS): Fix extra registers.
        (CALL_USED_REGISTERS): Ditto.
        (CALL_REALLY_USED_REGISTERS): Ditto.
        (RAP_REG_NUM): Remove.
        (RETURN_ADDRESS_POINTER_REGNUM): Ditto.
        (RETURN_ADDR_RTX): Define to mips_return_addr.
        (ELIMINABLE_REGS): Remove RETURN_ADDRESS_POINTER_REGNUM.
        (CAN_ELIMINATE): Ditto.
        * config/mips/mips.md: For DImode patterns, take into account
        deletions above. Split mulsidi patterns into sign_extend and
	zero_extend.

2002-10-16  Richard Sandiford  <rsandifo@redhat.com>
	    Michael Meissner  <meissner@redhat.com>

	* config/mips/mips.h (ISA_HAS_MACC): True for normal-mode vr4120 code.
	* config/mips/mips.md (mulsi3_mult3): Add a define_peephole2 to
	mop up unnecessarly moves through LO.
	(*mul_acc_si): Remove vr5400 and vr5500 handling from here.
	(*macc): New pattern for ISA_HAS_MACC.  Add define_peephole2s to
	change mtlo/macc sequences into mul/add sequences when a three-
	address mul is available.
	(*macc2): New pattern.  Add a define_peephole2 to generate it.
	(*mul_sub_si): Fix contraint for operand 5.
	(*muls): Use in 32-bit code as well.
	(*msac): Likewise.  Use msub instead of msac in vr5500 code
	if the destination is LO.  Remove duplicate define_split.
	(*muls_di): Use only in 32-bit code.  Adjust rtl accordingly.
	(*msac_di): Likewise.  Fix formatting.
	(smulsi3_highpart, umulsi3_highpart): Use mulhi in 32-bit code too.
	(*xmulsi3_highpart_internal): Use only if !ISA_HAS_MULHI.
	(*xmulsi3_highpart_mulhi): Use even if !TARGET_64BIT.
	(*xmulsi3_neg_highpart_mulhi): Likewise.
	(*mul_acc_64bit_di): Remove.
	(*mul_acc_di): Use only in 32-bit code.  Handle ISA_HAS_MACC as well.

2002-10-14  Richard Sandiford  <rsandifo@redhat.com>

	* config/mips/vr.h (DRIVER_SELF_SPECS): Define.
	* config/mips/t-vr (MULTILIB_OPTIONS): Remove mlong32.
	(MULTILIB_DIRNAMES): Remove long32.
	(MULTILIB_EXCEPTIONS): Don't build -mabi=32 -mgp32 multilibs.
	(MULTILIB_REDUNDANT_DIRS): Remove.

2002-10-14  Richard Sandiford  <rsandifo@redhat.com>

	* doc/tm.texi (DRIVER_SELF_SPECS): Document.
	* gcc.c (driver_self_specs): New variable.
	(do_self_spec): New function.
	(main): Use it to process driver_self_specs.

2002-10-09  Richard Sandiford  <rsandifo@redhat.com>

	* config/mips/mips.md (one_cmpldi2): Use only if TARGET_64BIT.
	Remove DImode define_split for !TARGET_64BIT.
	(anddi3): Remove !TARGET_64BIT support from here as well.
	Change operand 2's predicate to se_uns_arith_operand.
	Add constant alternatives to define_insn.
	(iordi3, xordi3, *nordi3): Likewise.
	(anddi3_internal1, xordi3_immed): Remove.

2002-10-01  Richard Sandiford  <rsandifo@redhat.com>

	* config/mips/mips.h (PROCESSOR_R4121): Rename to PROCESSOR_R4120.
	(TARGET_MIPS4121): Rename to TARGET_MIPS4120.
	* config/mips/mips.c (mips_cpu_info): Rename vr4121 to vr4120.
	* config/mips/mips.md: Apply same renaming here.

2002-10-01  Richard Sandiford  <rsandifo@redhat.com>

	* config/mips/mips.c (PROCESSOR_R4320, TARGET_MIPS4320): Remove.
	(GENERATE_MULT3_SI): Remove use of TARGET_MIPS4320.
	* config/mips/mips.c (mips_cpu_info): Remove vr4320 entry.
	* config/mips/mips.md (define_attr cpu): Remove r4320.
	Remove vr4320 scheduler and uses of TARGET_MIPS4320.

2002-10-01  Richard Sandiford  <rsandifo@redhat.com>

	* config/mips/mips.c (mips16_strings): New variable.
	(mips_output_function_epilogue): Clear the SYMBOL_REF_FLAG of every
	symbol in mips16_strings.  Free the list.
	(mips_encode_section_info): Keep track of local strings.

2002-10-01  Richard Sandiford  <rsandifo@redhat.com>

	* config/mips/mips.md (bunge, bltgt, bungt): New define_expands.
	(sordered_df, sordered_sf): Remove.
	* config/mips/mips.c (get_float_compare_codes): New fn.
	(gen_int_relational, gen_conditional_move): Use it.

2002-10-01  Richard Sandiford  <rsandifo@redhat.com>

	* config/mips/mips-protos.h (mips_emit_fcc_reload): Declare.
	* config/mips/mips.h (PREDICATE_CODES): Add fcc_register_operand.
	* config/mips/mips.c (fcc_register_operand): New function.
	(mips_emit_fcc_reload): New function, extracted from reload_incc.
	(override_options): Allow TFmode values in float registers
	if ISA_HAS_8CC.
	* cnfig/mips/mips.md (reload_incc): Change destination prediate
	to fcc_register_operand.  Remove misleading source constraint.
	Use mips_emit_fcc_reload.
	(reload_outcc): Duplicate reload_incc.