public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH testcase]Skip test pr61772.c for lto tests
@ 2014-08-07  9:43 Bin Cheng
  2014-08-07 12:04 ` Richard Biener
  2014-08-08  8:05 ` Kyrill Tkachov
  0 siblings, 2 replies; 5+ messages in thread
From: Bin Cheng @ 2014-08-07  9:43 UTC (permalink / raw)
  To: gcc-patches

[-- Attachment #1: Type: text/plain, Size: 630 bytes --]

Hi,
Case pr61772.c scans specific string in assembly file, and it is run for
many different option combinations.  When it's tested against different lto
option combinations on targets like ARM, the generated pr61772.s may only
contain lto object content, rather than assembly codes.  The scanning check
is failed in these cases.
I think disabling lto won't weaken the test since what it tests has nothing
to do with lto.  This patch fixes these failures by disabling lto.

Is it OK?

Thanks,
bin

gcc/testsuite/ChangeLog
2014-08-07  Bin Cheng  <bin.cheng@arm.com>

	* gcc.dg/torture/pr61772.c: Skip lto running.

[-- Attachment #2: j4536-20140807.txt --]
[-- Type: text/plain, Size: 465 bytes --]

Index: gcc/testsuite/gcc.dg/torture/pr61772.c
===================================================================
--- gcc/testsuite/gcc.dg/torture/pr61772.c	(revision 213529)
+++ gcc/testsuite/gcc.dg/torture/pr61772.c	(working copy)
@@ -1,4 +1,5 @@
 /* { dg-do compile } */
+/* { dg-skip-if "" { *-*-* } { "-flto" } { "" } } */
 /* { dg-final { scan-assembler-times "XXX" 2 } } */
 
 static inline __attribute__((always_inline)) int dec_and_test (int *i)

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH testcase]Skip test pr61772.c for lto tests
  2014-08-07  9:43 [PATCH testcase]Skip test pr61772.c for lto tests Bin Cheng
@ 2014-08-07 12:04 ` Richard Biener
  2014-08-08  8:05 ` Kyrill Tkachov
  1 sibling, 0 replies; 5+ messages in thread
From: Richard Biener @ 2014-08-07 12:04 UTC (permalink / raw)
  To: Bin Cheng; +Cc: GCC Patches

On Thu, Aug 7, 2014 at 11:43 AM, Bin Cheng <bin.cheng@arm.com> wrote:
> Hi,
> Case pr61772.c scans specific string in assembly file, and it is run for
> many different option combinations.  When it's tested against different lto
> option combinations on targets like ARM, the generated pr61772.s may only
> contain lto object content, rather than assembly codes.  The scanning check
> is failed in these cases.
> I think disabling lto won't weaken the test since what it tests has nothing
> to do with lto.  This patch fixes these failures by disabling lto.
>
> Is it OK?

Ok.

Thanks,
Richard.

> Thanks,
> bin
>
> gcc/testsuite/ChangeLog
> 2014-08-07  Bin Cheng  <bin.cheng@arm.com>
>
>         * gcc.dg/torture/pr61772.c: Skip lto running.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH testcase]Skip test pr61772.c for lto tests
  2014-08-07  9:43 [PATCH testcase]Skip test pr61772.c for lto tests Bin Cheng
  2014-08-07 12:04 ` Richard Biener
@ 2014-08-08  8:05 ` Kyrill Tkachov
  2014-08-08  8:24   ` Bin.Cheng
  1 sibling, 1 reply; 5+ messages in thread
From: Kyrill Tkachov @ 2014-08-08  8:05 UTC (permalink / raw)
  To: Bin Cheng, gcc-patches

[-- Attachment #1: Type: text/plain, Size: 947 bytes --]


On 07/08/14 10:43, Bin Cheng wrote:
> Hi,
> Case pr61772.c scans specific string in assembly file, and it is run for
> many different option combinations.  When it's tested against different lto
> option combinations on targets like ARM, the generated pr61772.s may only
> contain lto object content, rather than assembly codes.  The scanning check
> is failed in these cases.
> I think disabling lto won't weaken the test since what it tests has nothing
> to do with lto.  This patch fixes these failures by disabling lto.
>
> Is it OK?

Hi Bin,

Do you think it would be better to just add -ffat-lto-objects instead? 
That way the output would contain the assembly as well. Example patch 
attached.

We might want check that LTO doesn't optimise the assembly away?

Kyrill

> Thanks,
> bin
>
> gcc/testsuite/ChangeLog
> 2014-08-07  Bin Cheng  <bin.cheng@arm.com>
>
> 	* gcc.dg/torture/pr61772.c: Skip lto running.

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: fat-lto-objects.patch --]
[-- Type: text/x-patch; name=fat-lto-objects.patch, Size: 431 bytes --]

diff --git a/gcc/testsuite/gcc.dg/torture/pr61772.c b/gcc/testsuite/gcc.dg/torture/pr61772.c
index da4c93e..aa60c14 100644
--- a/gcc/testsuite/gcc.dg/torture/pr61772.c
+++ b/gcc/testsuite/gcc.dg/torture/pr61772.c
@@ -1,4 +1,5 @@
 /* { dg-do compile } */
+/* { dg-options "-ffat-lto-objects" } */
 /* { dg-final { scan-assembler-times "XXX" 2 } } */
 
 static inline __attribute__((always_inline)) int dec_and_test (int *i)

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH testcase]Skip test pr61772.c for lto tests
  2014-08-08  8:05 ` Kyrill Tkachov
@ 2014-08-08  8:24   ` Bin.Cheng
  2014-08-08 10:02     ` Kyrill Tkachov
  0 siblings, 1 reply; 5+ messages in thread
From: Bin.Cheng @ 2014-08-08  8:24 UTC (permalink / raw)
  To: Kyrill Tkachov; +Cc: Bin Cheng, gcc-patches

On Fri, Aug 8, 2014 at 4:05 PM, Kyrill Tkachov <kyrylo.tkachov@arm.com> wrote:
>
> On 07/08/14 10:43, Bin Cheng wrote:
>>
>> Hi,
>> Case pr61772.c scans specific string in assembly file, and it is run for
>> many different option combinations.  When it's tested against different
>> lto
>> option combinations on targets like ARM, the generated pr61772.s may only
>> contain lto object content, rather than assembly codes.  The scanning
>> check
>> is failed in these cases.
>> I think disabling lto won't weaken the test since what it tests has
>> nothing
>> to do with lto.  This patch fixes these failures by disabling lto.
>>
>> Is it OK?
>
>
> Hi Bin,
>
> Do you think it would be better to just add -ffat-lto-objects instead? That
> way the output would contain the assembly as well. Example patch attached.
>
> We might want check that LTO doesn't optimise the assembly away?
Not actually.  It's a compilation time test and IMHO if-conversion
optimization here has nothing to do with lto.  Another reason here is
we can't just add a single lto option without support full lto
testing.  Consider scenario testing on a target without lto?  Please
correct if I was wrong.

Thanks,
bin
>
> Kyrill
>
>
>> Thanks,
>> bin
>>
>> gcc/testsuite/ChangeLog
>> 2014-08-07  Bin Cheng  <bin.cheng@arm.com>
>>
>>         * gcc.dg/torture/pr61772.c: Skip lto running.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH testcase]Skip test pr61772.c for lto tests
  2014-08-08  8:24   ` Bin.Cheng
@ 2014-08-08 10:02     ` Kyrill Tkachov
  0 siblings, 0 replies; 5+ messages in thread
From: Kyrill Tkachov @ 2014-08-08 10:02 UTC (permalink / raw)
  To: Bin.Cheng; +Cc: Bin Cheng, gcc-patches


On 08/08/14 09:24, Bin.Cheng wrote:
> On Fri, Aug 8, 2014 at 4:05 PM, Kyrill Tkachov <kyrylo.tkachov@arm.com> wrote:
>> On 07/08/14 10:43, Bin Cheng wrote:
>>> Hi,
>>> Case pr61772.c scans specific string in assembly file, and it is run for
>>> many different option combinations.  When it's tested against different
>>> lto
>>> option combinations on targets like ARM, the generated pr61772.s may only
>>> contain lto object content, rather than assembly codes.  The scanning
>>> check
>>> is failed in these cases.
>>> I think disabling lto won't weaken the test since what it tests has
>>> nothing
>>> to do with lto.  This patch fixes these failures by disabling lto.
>>>
>>> Is it OK?
>>
>> Hi Bin,
>>
>> Do you think it would be better to just add -ffat-lto-objects instead? That
>> way the output would contain the assembly as well. Example patch attached.
>>
>> We might want check that LTO doesn't optimise the assembly away?
> Not actually.  It's a compilation time test and IMHO if-conversion
> optimization here has nothing to do with lto.  Another reason here is
> we can't just add a single lto option without support full lto
> testing.  Consider scenario testing on a target without lto?  Please
> correct if I was wrong.

Ok, skipping it is fine by me then.

Kyrill

> Thanks,
> bin
>> Kyrill
>>
>>
>>> Thanks,
>>> bin
>>>
>>> gcc/testsuite/ChangeLog
>>> 2014-08-07  Bin Cheng  <bin.cheng@arm.com>
>>>
>>>          * gcc.dg/torture/pr61772.c: Skip lto running.


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2014-08-08 10:02 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-07  9:43 [PATCH testcase]Skip test pr61772.c for lto tests Bin Cheng
2014-08-07 12:04 ` Richard Biener
2014-08-08  8:05 ` Kyrill Tkachov
2014-08-08  8:24   ` Bin.Cheng
2014-08-08 10:02     ` Kyrill Tkachov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).