public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: "Joseph S. Myers" <joseph@codesourcery.com>
To: DJ Delorie <dj@redhat.com>
Cc: <richard.guenther@gmail.com>, <gcc@gcc.gnu.org>
Subject: Re: proposal to make SIZE_TYPE more flexible
Date: Tue, 10 Dec 2013 18:38:00 -0000	[thread overview]
Message-ID: <Pine.LNX.4.64.1312101831290.15324@digraph.polyomino.org.uk> (raw)
In-Reply-To: <201312101810.rBAIAPeZ008667@greed.delorie.com>

On Tue, 10 Dec 2013, DJ Delorie wrote:

> > This seems mostly plausible, though I don't see anything to ensure that 
> > __intN does not exist at all if the size matches one of the standard C 
> > types,
> 
> My thought here was that, since each __intN is specified by the
> target, they'd know to only do so if it doesn't match an existing (for
> that target) type.  But what if it does?  What if the standard types
> changed based on command line options, and the target wanted to offer
> an __intN as a "this will always work" alternative to standard types?

If you have such alternative types, you have extra complications: either 
they are the same as a standard type (and you need to define what the 
order of preference is and keep it constant, to avoid __intN changing from 
int to long at random), or they are distinct (and you need to define 
integer promotion ranks and ensure the front end code handles promotions 
for types the same size as int correctly).  Not having such alternatives 
avoids such complications.  Thus, I'd rather any possibility of such types 
came later after the basic support for types not matching the standard 
types.

(For the types you do have, there's a need to define C++ name mangling.  
There are various other issues for such extended types - see PR 50441 
comment 3, and PR 43622 - but you can safely ignore such issues for now as 
pre-existing problems with __int128.  Whereas __int128 does have mangling 
defined in cp/mangle.c, and targets can already define their own mangling 
for target-specific types through a hook.)

-- 
Joseph S. Myers
joseph@codesourcery.com

  reply	other threads:[~2013-12-10 18:38 UTC|newest]

Thread overview: 47+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-30  4:28 DJ Delorie
2013-10-30 15:53 ` Joseph S. Myers
2013-10-30 19:18   ` DJ Delorie
2013-10-30 20:49     ` Joseph S. Myers
2013-10-30 22:19       ` DJ Delorie
2013-10-30 22:51         ` Joseph S. Myers
2013-11-14  1:58           ` DJ Delorie
2013-11-14 13:26             ` Joseph S. Myers
2013-11-14 18:12               ` DJ Delorie
2013-11-14 18:37                 ` Joseph S. Myers
2013-11-14 18:48                   ` DJ Delorie
2013-11-14 21:40                     ` Joseph S. Myers
2013-11-15  1:47                       ` DJ Delorie
2013-11-15  1:56                         ` Joseph S. Myers
2013-11-15 23:38               ` DJ Delorie
2013-11-16 11:23                 ` Richard Biener
2013-11-16 12:26                   ` Joseph S. Myers
2013-11-21 22:41                     ` DJ Delorie
2013-11-21 22:59                       ` Joseph S. Myers
2013-11-22  8:29                         ` DJ Delorie
2013-11-22 12:43                           ` Joseph S. Myers
2013-11-22 19:33                             ` DJ Delorie
2013-11-22 21:00                               ` Joseph S. Myers
2013-11-22 21:19                                 ` DJ Delorie
2013-11-23  0:41                                   ` Joseph S. Myers
2013-12-10  3:35                                     ` DJ Delorie
2013-12-10 17:17                                       ` Joseph S. Myers
2013-12-10 18:10                                         ` DJ Delorie
2013-12-10 18:38                                           ` Joseph S. Myers [this message]
2013-12-10 18:42                                             ` DJ Delorie
2013-12-11  9:27                                               ` Richard Biener
2013-12-20  4:58                                         ` DJ Delorie
2013-12-20 12:42                                           ` Joseph S. Myers
2013-12-20 19:47                                         ` DJ Delorie
2013-12-20 21:53                                           ` Joseph S. Myers
2013-12-20 21:59                                             ` DJ Delorie
2013-12-20 22:15                                               ` Joseph S. Myers
2013-12-20 22:40                                                 ` DJ Delorie
2013-12-21  1:01                                                   ` Joseph S. Myers
2014-01-09  2:31                                                     ` DJ Delorie
2014-01-09  3:23                                                       ` Joseph S. Myers
2014-01-09  7:02                                                         ` DJ Delorie
2014-01-09 16:22                                                           ` Joseph S. Myers
2014-01-15 12:48                                                             ` DJ Delorie
2014-01-28 21:52                                                               ` DJ Delorie
2014-01-28 21:58                                                                 ` Joseph S. Myers
2014-01-28 22:24                                                                   ` DJ Delorie

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=Pine.LNX.4.64.1312101831290.15324@digraph.polyomino.org.uk \
    --to=joseph@codesourcery.com \
    --cc=dj@redhat.com \
    --cc=gcc@gcc.gnu.org \
    --cc=richard.guenther@gmail.com \
    /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).