public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug d/96869] New: __vectors unsupported in hardware should be rejected at compile-time
@ 2020-08-31 15:16 ibuclaw at gdcproject dot org
  2020-08-31 15:20 ` [Bug d/96869] " pinskia at gcc dot gnu.org
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: ibuclaw at gdcproject dot org @ 2020-08-31 15:16 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96869

            Bug ID: 96869
           Summary: __vectors unsupported in hardware should be rejected
                    at compile-time
           Product: gcc
           Version: 11.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: d
          Assignee: ibuclaw at gdcproject dot org
          Reporter: ibuclaw at gdcproject dot org
  Target Milestone: ---

It should also be possible to use __traits(compiles) in order to determine
whether a vector is supported or not.

Currently, pretty much any __vector is permissible.  The desired result would
be to only use targetm.vector_mode_supported_p as gate for whether to accept
the use of a vector type or not.

Splitting up the simd.d test file into more granular tests should be done with
this as well.

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

* [Bug d/96869] __vectors unsupported in hardware should be rejected at compile-time
  2020-08-31 15:16 [Bug d/96869] New: __vectors unsupported in hardware should be rejected at compile-time ibuclaw at gdcproject dot org
@ 2020-08-31 15:20 ` pinskia at gcc dot gnu.org
  2020-08-31 20:23 ` ibuclaw at gdcproject dot org
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu.org @ 2020-08-31 15:20 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96869

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Hmmm, so you dont want to allow generic vector types? This is unlike GNU c/C++.

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

* [Bug d/96869] __vectors unsupported in hardware should be rejected at compile-time
  2020-08-31 15:16 [Bug d/96869] New: __vectors unsupported in hardware should be rejected at compile-time ibuclaw at gdcproject dot org
  2020-08-31 15:20 ` [Bug d/96869] " pinskia at gcc dot gnu.org
@ 2020-08-31 20:23 ` ibuclaw at gdcproject dot org
  2020-09-02 21:01 ` cvs-commit at gcc dot gnu.org
  2020-09-02 21:02 ` ibuclaw at gdcproject dot org
  3 siblings, 0 replies; 5+ messages in thread
From: ibuclaw at gdcproject dot org @ 2020-08-31 20:23 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96869

--- Comment #2 from Iain Buclaw <ibuclaw at gdcproject dot org> ---
(In reply to Andrew Pinski from comment #1)
> Hmmm, so you dont want to allow generic vector types? This is unlike GNU
> c/C++.

Correct, the D spec has had the following entry added.

> Implementation Defined: Which vector types are supported depends
> on the target. The implementation is expected to only support the
> vector types that are implemented in the target's hardware.

I could go one further and reject vector expressions not supported in hardware,
but I don't think that kind of information is readily available in a target
hook.

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

* [Bug d/96869] __vectors unsupported in hardware should be rejected at compile-time
  2020-08-31 15:16 [Bug d/96869] New: __vectors unsupported in hardware should be rejected at compile-time ibuclaw at gdcproject dot org
  2020-08-31 15:20 ` [Bug d/96869] " pinskia at gcc dot gnu.org
  2020-08-31 20:23 ` ibuclaw at gdcproject dot org
@ 2020-09-02 21:01 ` cvs-commit at gcc dot gnu.org
  2020-09-02 21:02 ` ibuclaw at gdcproject dot org
  3 siblings, 0 replies; 5+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2020-09-02 21:01 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96869

--- Comment #3 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Iain Buclaw <ibuclaw@gcc.gnu.org>:

https://gcc.gnu.org/g:f0a3bab43fda3084eaf1bdaac58936757f30ea35

commit r11-2988-gf0a3bab43fda3084eaf1bdaac58936757f30ea35
Author: Iain Buclaw <ibuclaw@gdcproject.org>
Date:   Mon Aug 31 22:42:10 2020 +0200

    d: __vectors unsupported in hardware should be rejected at compile-time.

    gcc/d/ChangeLog:

            PR d/96869
            * d-builtins.cc (build_frontend_type): Don't expose intrinsics that
            use unsupported vector types.
            * d-target.cc (Target::isVectorTypeSupported): Restrict to
supporting
            only if TARGET_VECTOR_MODE_SUPPORTED_P is true.  Don't allow
complex
            or boolean vector types.

    gcc/testsuite/ChangeLog:

            PR d/96869
            * gdc.dg/simd.d: Removed.
            * gdc.dg/cast1.d: New test.
            * gdc.dg/gdc213.d: Compile with target vect_sizes_16B_8B.
            * gdc.dg/gdc284.d: Likewise.
            * gdc.dg/gdc67.d: Likewise.
            * gdc.dg/pr96869.d: New test.
            * gdc.dg/simd1.d: New test.
            * gdc.dg/simd10447.d: New test.
            * gdc.dg/simd12776.d: New test.
            * gdc.dg/simd13841.d: New test.
            * gdc.dg/simd13927.d: New test.
            * gdc.dg/simd15123.d: New test.
            * gdc.dg/simd15144.d: New test.
            * gdc.dg/simd16087.d: New test.
            * gdc.dg/simd16697.d: New test.
            * gdc.dg/simd17237.d: New test.
            * gdc.dg/simd17695.d: New test.
            * gdc.dg/simd17720a.d: New test.
            * gdc.dg/simd17720b.d: New test.
            * gdc.dg/simd19224.d: New test.
            * gdc.dg/simd19627.d: New test.
            * gdc.dg/simd19628.d: New test.
            * gdc.dg/simd19629.d: New test.
            * gdc.dg/simd19630.d: New test.
            * gdc.dg/simd2a.d: New test.
            * gdc.dg/simd2b.d: New test.
            * gdc.dg/simd2c.d: New test.
            * gdc.dg/simd2d.d: New test.
            * gdc.dg/simd2e.d: New test.
            * gdc.dg/simd2f.d: New test.
            * gdc.dg/simd2g.d: New test.
            * gdc.dg/simd2h.d: New test.
            * gdc.dg/simd2i.d: New test.
            * gdc.dg/simd2j.d: New test.
            * gdc.dg/simd7951.d: New test.
            * gdc.dg/torture/array2.d: New test.
            * gdc.dg/torture/array3.d: New test.
            * gdc.dg/torture/simd16488a.d: New test.
            * gdc.dg/torture/simd16488b.d: New test.
            * gdc.dg/torture/simd16703.d: New test.
            * gdc.dg/torture/simd19223.d: New test.
            * gdc.dg/torture/simd19607.d: New test.
            * gdc.dg/torture/simd3.d: New test.
            * gdc.dg/torture/simd4.d: New test.
            * gdc.dg/torture/simd7411.d: New test.
            * gdc.dg/torture/simd7413a.d: New test.
            * gdc.dg/torture/simd7413b.d: New test.
            * gdc.dg/torture/simd7414.d: New test.
            * gdc.dg/torture/simd9200.d: New test.
            * gdc.dg/torture/simd9304.d: New test.
            * gdc.dg/torture/simd9449.d: New test.
            * gdc.dg/torture/simd9910.d: New test.

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

* [Bug d/96869] __vectors unsupported in hardware should be rejected at compile-time
  2020-08-31 15:16 [Bug d/96869] New: __vectors unsupported in hardware should be rejected at compile-time ibuclaw at gdcproject dot org
                   ` (2 preceding siblings ...)
  2020-09-02 21:01 ` cvs-commit at gcc dot gnu.org
@ 2020-09-02 21:02 ` ibuclaw at gdcproject dot org
  3 siblings, 0 replies; 5+ messages in thread
From: ibuclaw at gdcproject dot org @ 2020-09-02 21:02 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96869

Iain Buclaw <ibuclaw at gdcproject dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |FIXED

--- Comment #4 from Iain Buclaw <ibuclaw at gdcproject dot org> ---
Done.

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

end of thread, other threads:[~2020-09-02 21:02 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-31 15:16 [Bug d/96869] New: __vectors unsupported in hardware should be rejected at compile-time ibuclaw at gdcproject dot org
2020-08-31 15:20 ` [Bug d/96869] " pinskia at gcc dot gnu.org
2020-08-31 20:23 ` ibuclaw at gdcproject dot org
2020-09-02 21:01 ` cvs-commit at gcc dot gnu.org
2020-09-02 21:02 ` ibuclaw at gdcproject dot org

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).