This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH][C++] Fix PR86763, wrong-code with TYPE_TYPELESS_STORAGE
On Tue, 21 Aug 2018, Szabolcs Nagy wrote:
> On 20/08/18 10:33, Richard Biener wrote:
> > On Mon, 20 Aug 2018, Szabolcs Nagy wrote:
> > > On 02/08/18 09:30, Richard Biener wrote:
> ...
> > > > + clock_gettime(CLOCK_REALTIME, &t);
> > >
> > > this fails on targets without clock_gettime (baremetal)
> > > or targets that need -lrt at link time.
> > >
> > > can we use something else here?
> > > e.g. time(&t) works on baremetal and does not depend on -lrt.
> >
> > You'd have to check that the original bug still reproduces. Since
> > it depends on scheduling chances may be that it is fragile :/
> >
> > I suppose we could restrict the testcase to { *-*-linux }?
> >
>
> i decided to restrict it to linux:
>
> clock_gettime is not available on some baremetal targets
> and may require -lrt on some non-linux targets.
>
> OK for trunk?
OK. OK also for backports.
Richard.
> gcc/testsuite/ChangeLog:
> 2018-08-21 Szabolcs Nagy <szabolcs.nagy@arm.com>
>
> * g++.dg/torture/pr86763.C: Restrict to *-*-linux*.