Hi Jeevitha, On 24/06/25 3:30 pm, jeevitha wrote: > Hi All, > > The following patch has been tested on powerpc64le-linux and verified it's > fixed. > > Changes from V1: > Added the reason for adding the flag(-fno-ipa-icf) inside the test case. > > The test vsx-builtin-7.c failed on powerpc64le-linux due to Identical > Code Folding (ICF) merging the functions insert_di_0_v2 and insert_di_0. > This behavior was introduced by commit r15-7961-gdc47161c1f32c3, which > enhanced alias analysis in ao_compare::compare_ao_refs, enabling the > compiler to identify and optimize structurally identical functions. As a > result, the compiler replaced insert_di_0_v2 with a tail call to > insert_di_0, altering the expected test behavior. > > This patch adds -fno-ipa-icf to the test's dg-options to disable ICF, > avoiding function merging and ensuring the test executes correctly. > > 2025-06-24 Jeevitha Palanisamy <jeevi...@linux.ibm.com> > > gcc/testsuite/ > PR testsuite/119382 > * gcc.target/powerpc/vsx-builtin-7.c: Add '-fno-ipa-icf' to dg-options. > > > diff --git a/gcc/testsuite/gcc.target/powerpc/vsx-builtin-7.c > b/gcc/testsuite/gcc.target/powerpc/vsx-builtin-7.c > index 5095d5030fd..31e12323922 100644 > --- a/gcc/testsuite/gcc.target/powerpc/vsx-builtin-7.c > +++ b/gcc/testsuite/gcc.target/powerpc/vsx-builtin-7.c > @@ -1,8 +1,14 @@ > /* { dg-do compile { target { powerpc*-*-* } } } */ > /* { dg-skip-if "" { powerpc*-*-darwin* } } */ > -/* { dg-options "-O2 -mdejagnu-cpu=power7 -fno-inline-functions" } */ > +/* { dg-options "-O2 -mdejagnu-cpu=power7 -fno-inline-functions > -fno-ipa-icf" } */ > /* { dg-require-effective-target powerpc_vsx } */ > > +/* Note: Added -fno-ipa-icf to disable Interprocedural Identical Code > + Folding (ICF). Without this, insert_di_0_v2 is merged with insert_di_0 due > + to improved alias analysis introduced in commit r15-7961-gdc47161c1f32c3. > + This results in a tail call replacement, altering expected test behavior. > + Disabling ICF ensures correct execution of the test. */
Can you please mention the PR number in the comment above? Also please reword as follows: "This results in the compiler replacing insert_di_0_v2 with a tail call to insert_di_0, altering expected test behavior." With the above changes, the patch is fine. However, I cannot approve the patch. Regards, Surya > + > /* Test simple extract/insert/slat operations. Make sure all types are > supported with various options. */ >