This is the mail archive of the 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]
Other format: [Raw text]

Re: [Patch, objc] maintenance, make Obj{C,C++} LTO-friendly.

On 9 Jul 2010, at 06:59, Mike Stump wrote:

On Jul 2, 2010, at 12:19 PM, IainS wrote:
This patch is intended to maintain the 'status-quo' in the presence of LTO.

OK for trunk?

[ after more thought and some more offline email... ]

Ok with the:

Well, I found the cause of our section hassles and fixed it as obvious (I hope that doesn't exceed the approval).
In doing so it meant that I was able to make pretty much all the changes you asked for.

I have checked in gdb at O1 that the items hanging off _OBJC_MODULES are marked as used (without needing to force that).

AFAICT, all the necessary top level stuff is marked DECL_PRESERVE_P and that the rest is being correctly marked by the varpool/cgraph mechanisms.


This is what I checked in as r162030:

	PR objc/44140
	* config/darwin.c (output_objc_section_asm_op): Save and restore
	section when outputting ObjC section list.


	PR objc/44140
	* objc.dg/lto/trivial-1_0.m: New.
	* objc.dg/lto/lto.exp: New.
	* obj-c++.dg/lto/ New.
	* obj-c++.dg/lto/lto.exp: New.
	* objc.dg/symtab-1.m: Adjust sizes.
	* objc.dg/image-info.m: Do not run for gnu-runtime.


	PR objc/44140
	* objc-act.c: build_objc_string_decl() remove declaration.
	(finish_var_decl): Remove forcing of var output and marking
	as "Used".
	(init_def_list): Use integer_zero_node.
	(init_objc_symtab): Use integer_zero_node, make the short
	integer type specific on relevant nodes.
	(generate_objc_symtab_decl): Remove call to
	forward_declare_categories().  Use null_pointer_node where
	(build_module_descriptor): Comment and mark this item as
	(generate_static_references): Use gcc_unreachable instead of
	abort ().
	(diagnose_missing_method): New.
	(build_next_selector_translation_table): New.
	(build_gnu_selector_translation_table): New.
	(add_objc_string): Merge code from build_objc_string_decl...
	... and delete build_objc_string_decl().
	(generate_dispatch_table): Make integer types explicit.
	(generate_category): Pass implent and arrange for the data
	to be extracted within the routine.  Do not start new vars,
	but finish the ones collcted during parsing.
	(generate_shared_structures): Likewise.
	(finish_objc):  Reorder code so that we finish variables before
	referencing them.  Save the global data before calling meta-data
	creation routines, and pass the current reference to the two
	main routines.  Only call generate_objc_image_info () for the
	NeXT runtime.
	(generate_classref_translation_entry): Comment on and make this
	(handle_class_ref): Use varpool interfaces, comment on and make
	this item DECL_PRESERVE_P.
	(handle_impent): Likewise.
	(generate_objc_image_info): Only generate when the content is
	non-zero.  Make integer types explict.

Attachment: 162022-objc-lto.txt
Description: Text document

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