From: Qing Zhao <qing.zhao@oracle.com>
To: Richard Sandiford <richard.sandiford@arm.com>
Cc: Richard Biener <rguenther@suse.de>,
Gcc-patches Qing Zhao via <gcc-patches@gcc.gnu.org>,
Kees Cook <keescook@chromium.org>
Subject: Re: [patch for gcc12 stage1][version 2] add -ftrivial-auto-var-init and variable attribute "uninitialized" to gcc
Date: Wed, 5 May 2021 12:29:08 -0500 [thread overview]
Message-ID: <039556DA-C209-41A7-9833-150CA485E982@oracle.com> (raw)
In-Reply-To: <0DDDEAB4-AA58-4F98-9526-8F63AEAC3D3D@oracle.com>
>
>>
>>> @@ -11950,6 +12088,72 @@ lower_bound_in_type (tree outer, tree inner)
>>> }
>>> }
>>>
>>> +/* Returns true when the given TYPE has padding inside it.
>>> + return false otherwise. */
>>> +bool
>>> +type_has_padding (tree type)
>>
>> Would it be possible to reuse __builtin_clear_padding here?
>
> Not sure, where can I get more details on __builtin_clear_padding? I can study a little bit more on this to make sure this.
After some study, my understanding is, the call to __builtin_clear_padding is expanded during gimplification phase.
And there is no __bultin_clear_padding expanding during rtx expanding phase.
Is the above understanding correct?
If so, for -ftrivial-auto-var-init, padding initialization should be done both in gimplification phase and rtx expanding phase.
And since the __builtin_clear_padding might not be good for rtx expanding, reusing __builtin_clear_padding might not work.
Let me know if I misunderstand something.
Qing
>>
next prev parent reply other threads:[~2021-05-05 17:29 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-24 21:21 Qing Zhao
2021-04-07 14:44 ` Qing Zhao
2021-04-07 22:19 ` Kees Cook
2021-04-08 15:22 ` Qing Zhao
2021-04-23 19:05 ` Richard Sandiford
2021-04-23 19:33 ` Kees Cook
2021-04-26 15:09 ` Qing Zhao
2021-04-26 17:47 ` Richard Sandiford
2021-04-26 20:02 ` Qing Zhao
2021-04-27 6:30 ` Richard Biener
2021-04-27 15:10 ` Qing Zhao
2021-05-05 17:29 ` Qing Zhao [this message]
2021-05-05 14:41 ` Qing Zhao
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=039556DA-C209-41A7-9833-150CA485E982@oracle.com \
--to=qing.zhao@oracle.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=keescook@chromium.org \
--cc=rguenther@suse.de \
--cc=richard.sandiford@arm.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).