This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: [PATCH] Don't output unused string constants (take 2)


On Tue, Nov 14, 2000 at 10:17:18AM -0500, Jakub Jelinek wrote:
> 	* varasm.c (struct deferred_string): New structure.
> 	(const_str_htab): New variable.
> 	(STRHASH): New macro.
> 	(mark_const_str_htab_1, mark_const_str_htab, const_str_htab_hash,
> 	constr_str_htab_eq, const_str_htab_del): New functions.
> 	(output_constant_def): Add DEFER argument, defer string
> 	constants until mark_constant_pool time if requested.
> 	(mark_constant_pool): Walk the insn chain even if const_str_htab is
> 	not empty.
> 	(mark_constants): If a SYMBOL_REF for deferred string is found,
> 	output it and remove from hash table.
> 	(output_addressed_constants): Set DEFER to 0 in call to
> 	output_constant_def.
> 	* rtl.h (STRING_POOL_ADDRESS_P): Define.
> 	(output_constant_def): Adjust prototype.
> 	* expr.c (expand_expr): Set DEFER to 1 in call to output_constant_def.
> 
> 	* gcc.c-torture/execute/20000801-4.c: Make sure the second string is
> 	output.

Ok.


r~

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]