[PATCH v6 9/9] drm/amd/display: Mark dc_fixpt_from_fraction() noinline
Alex Deucher
alexdeucher at gmail.com
Wed Dec 18 19:22:10 UTC 2024
On Wed, Dec 18, 2024 at 2:18 PM Josh Poimboeuf <jpoimboe at kernel.org> wrote:
>
> On Wed, Dec 18, 2024 at 10:36:00PM +0800, Huacai Chen wrote:
> > Hi, Tiezhu,
> >
> > On Tue, Dec 17, 2024 at 9:50 AM Tiezhu Yang <yangtiezhu at loongson.cn> wrote:
> > >
> > > When compiling with Clang on LoongArch, there exists the following objtool
> > > warning in drivers/gpu/drm/amd/display/dc/basics/fixpt31_32.o:
> > >
> > > dc_fixpt_recip() falls through to next function dc_fixpt_sinc()
> > >
> > > This is because dc_fixpt_from_fraction() is inlined in dc_fixpt_recip()
> > > by Clang, given dc_fixpt_from_fraction() is not a simple function, just
> > > mark it noinline to avoid the above issue.
> > I don't know whether drm maintainers can accept this, because it looks
> > like a workaround. Yes, uninline this function "solve" a problem and
> > seems reasonable in this case because the function is "not simple",
> > but from another point of view, you may hide a type of bug.
>
> Agreed, it sounds like there's definitely a bug which this patch is
> papering over.
Yes, agreed.
Alex
>
> --
> Josh
More information about the amd-gfx
mailing list