On Tue, 2024-10-29 at 07:49 -0600, Jeff Law wrote: > > > On 10/29/24 7:10 AM, Xi Ruoyao wrote: > > On Fri, 2024-10-11 at 02:54 +0800, Xi Ruoyao wrote: > > > At least two ports (hppa and loongarch) need to set SECTION_RELRO for > > > .data.rel.ro{,.local} in section_type_flags (PR52999 and PR116887), and > > > I cannot see a reason not to just set it in the generic code. > > > > > > With this applied we can also remove the hppa-specific > > > pa_section_type_flags in a future patch. > > > > > > gcc/ChangeLog: > > > > > > PR target/116887 > > > * varasm.cc (default_section_type_flags): Always set > > > SECTION_RELRO if name is .data.rel.ro{,.local}. > > > > > > gcc/testsuite/ChangeLog: > > > > > > PR target/116887 > > > * gcc.dg/pr116887.c: New test. > > > > Ping. > Sorry, I missed this the first time around. Thanks for pinging. > > OK for the trunk. Though we do need to keep an eye out for regressions. > We've had some surprises in the past with this kind of change.
Pushed. I'll wait for one week and if there's nothing wrong I'll make a patch to remove the hppa-specific code which is unneeded now with the target-independent handling. -- Xi Ruoyao <xry...@xry111.site> School of Aerospace Science and Technology, Xidian University