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: Fix invalid loader fixups from shared libobjc with hpux10.20


law@redhat.com wrote:
> 
>   > 2001-05-31  John David Anglin  <dave@hiauly1.hia.nrc.ca>
>   >
>   >     * objc/objc-act.c (handle_class_ref): Use rest_of_decl_compilation
>   >     so that CHOOSE_SECTION gets used.
>   >     (handle_impent): Use assemble_variable to put the global objc class
>   >     and category name labels in the readonly data section.
> It's certainly wrong for a front-end to blindly dump something into the
> readonly_data_section.  At the least it should be deferring to the routines
> in varasm.c to select the proper section.

It's kind of cheesy, but hardly noticeable in the mega-cheesiness of
objc-act.c. :-) :-(  A number of the ObjC actions synthesize tables
and data objects, and output them directly.  Many times there's not
even a decl on which to set TREE_READONLY.  So it's not something to
be real proud of, but until someone rewrites the ObjC frontend to
build trees for these things as C++ does for vtables, I think we're
stuck with calling section functions directly.

Stan


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