public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Hans-Peter Nilsson <hp@bitrange.com>
To: Alexandre Oliva <oliva@adacore.com>
Cc: gcc-patches@gcc.gnu.org,
	Rainer Orth <ro@cebitec.uni-bielefeld.de>,
	 Mike Stump <mikestump@comcast.net>
Subject: Re: enable sqrt insns for cdce3.c
Date: Wed, 10 Mar 2021 12:11:34 -0500 (EST)	[thread overview]
Message-ID: <alpine.BSF.2.20.16.2103101202250.12461@arjuna.pair.com> (raw)
In-Reply-To: <ory2evd19j.fsf@lxoliva.fsfla.org>

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

On Wed, 10 Mar 2021, Alexandre Oliva wrote:

>
> The test expects shrink-wrapping of the fsqrt call, but that will only
> occur when there is a usable sqrt insn.
>
> Arrange for dejagnu to add the options that enable the sqrt insn, if
> one is available, and to skip the test otherwise.
>
>
> H-P, this *should* obviate the mmix-specific dg-skip-if.

Unfortunately it doesn't.

>  Would it be
> easy for you to confirm that this is the case and, if so, drop it?

About as easy as for anyone (this is a compile-test), but no
problem.  Unfortunately I get, with your patch applied and the
dg-skip-if removed:

FAIL: gcc.dg/cdce3.c scan-tree-dump cdce "cdce3.c:12: [^\n\r]*
function call is shrink-wrapped into error conditions."

The dump files and assembly file show no obvious clues to me as
to what is supposed to happen; attached.

brgds, H-P

[-- Attachment #2: Type: text/plain, Size: 209 bytes --]


;; Function foo (foo, funcdef_no=0, decl_uid=1421, cgraph_uid=1, symbol_order=0)

float foo (float x)
{
  float _4;

  <bb 2> [local count: 1073741824]:
  _4 = sqrtf (x_2(D));
  return _4;

}



[-- Attachment #3: Type: text/plain, Size: 221 bytes --]


;; Function foo (foo, funcdef_no=0, decl_uid=1421, cgraph_uid=1, symbol_order=0)

float foo (float x)
{
  float _4;

  <bb 2> [local count: 1073741824]:
  _4 = sqrtf (x_2(D)); [tail call]
  return _4;

}



[-- Attachment #4: Type: text/plain, Size: 373 bytes --]

# 1 "cdce3.c"
! mmixal:= 8H LOC Data_Section
	.text ! mmixal:= 9H LOC 8B
	.p2align 2
	LOC @+(4-@)&3
	.global foo
foo	IS @
	GET $1,rJ
	SET $3,$0
	PUSHJ $2,sqrtf
	PUT rJ,$1
	SET $0,$2
	POP 1,0

	.ident	"GCC: (GNU) 11.0.1 20210309 (experimental) [master revision 0455cd76b687:0ed66571b1d9:63d74fed4566f1de583c368ecb9e2fc423fb1c87]"
	.data ! mmixal:= 8H LOC 9B

  reply	other threads:[~2021-03-10 17:11 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-10  5:30 Alexandre Oliva
2021-03-10 17:11 ` Hans-Peter Nilsson [this message]
2021-03-11 16:04   ` Alexandre Oliva
2024-04-22  9:50   ` Alexandre Oliva
2024-04-23 15:38     ` Hans-Peter Nilsson
2024-04-28  7:40       ` Alexandre Oliva
2021-03-20 15:20 ` Jeff Law
2024-04-22  9:56 ` [PATCH v2] [testsuite] require sqrt_insn effective target where needed Alexandre Oliva
2024-04-23  8:59   ` Kewen.Lin
2024-04-23  9:14     ` Iain Sandoe
2024-04-28  7:37       ` Alexandre Oliva
2024-04-24  2:15   ` Mike Stump

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=alpine.BSF.2.20.16.2103101202250.12461@arjuna.pair.com \
    --to=hp@bitrange.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=mikestump@comcast.net \
    --cc=oliva@adacore.com \
    --cc=ro@cebitec.uni-bielefeld.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).