'-Wstrict-flex-arrays'
Warn about inproper usages of flexible array members according to
the LEVEL of the 'strict_flex_array (LEVEL)' attribute attached to
the trailing array field of a structure if it's available,
otherwise according to the LEVEL of the option
A. add the following to clarify the relationship between -Warray-bounds
and the LEVEL of -fstrict-flex-array:
By default, the trailing array of a structure will be treated as a
flexible array member by '-Warray-bounds' or '-Warray-bounds=N' if
it is declared as either
Hi, this is the 3rd version of the patch.
Per Richard's request, I split the patch into two seperate patches:
1. Update -Warray-bounds with -fstrict-flex-arrays.
2. Add a new warning option -Wstrict-flex-arrays.
I have bootstrapped and regression tested on both X86 and aarch64
without any
> On Dec 5, 2022, at 10:16 AM, Richard Biener wrote:
>
> On Fri, 2 Dec 2022, Qing Zhao wrote:
>
>>
>>
>>> On Dec 2, 2022, at 2:20 AM, Richard Biener wrote:
>>>
>>> On Fri, 2 Dec 2022, Richard Biener wrote:
>>>
>>>>
> On Dec 2, 2022, at 2:20 AM, Richard Biener wrote:
>
> On Fri, 2 Dec 2022, Richard Biener wrote:
>
>> On Thu, 1 Dec 2022, Siddhesh Poyarekar wrote:
>>
>>> On 2022-12-01 11:42, Kees Cook wrote:
>>>> On Wed, Nov 30, 2022 at 02:25:56PM +,
> On Dec 2, 2022, at 2:16 AM, Richard Biener wrote:
>
> On Thu, 1 Dec 2022, Siddhesh Poyarekar wrote:
>
>> On 2022-12-01 11:42, Kees Cook wrote:
>>> On Wed, Nov 30, 2022 at 02:25:56PM +, Qing Zhao wrote:
>>>> '-Wstrict-flex-arrays'
>>>>
esh Poyarekar wrote:
>
> On 2022-12-01 11:42, Kees Cook wrote:
>> On Wed, Nov 30, 2022 at 02:25:56PM +, Qing Zhao wrote:
>>> '-Wstrict-flex-arrays'
>>> Warn about inproper usages of flexible array members according to
>>> the LEVEL o
ote:
>
> On Thu, Dec 01, 2022 at 05:04:02PM +0000, Qing Zhao wrote:
>>
>>
>>> On Dec 1, 2022, at 11:42 AM, Kees Cook wrote:
>>>
>>> On Wed, Nov 30, 2022 at 02:25:56PM +, Qing Zhao wrote:
>>>> '-Wstrict-flex-arrays'
>>&g
> On Dec 1, 2022, at 11:42 AM, Kees Cook wrote:
>
> On Wed, Nov 30, 2022 at 02:25:56PM +0000, Qing Zhao wrote:
>> '-Wstrict-flex-arrays'
>> Warn about inproper usages of flexible array members according to
>> the LEVEL of the 'strict_flex_array
'-Wstrict-flex-arrays'
Warn about inproper usages of flexible array members according to
the LEVEL of the 'strict_flex_array (LEVEL)' attribute attached to
the trailing array field of a structure if it's available,
otherwise according to the LEVEL of the option
Hi, this is the 2nd version for this patch.
Per our discussion, I made the following change compared to the first
version:
1. The level of -Warray-bounds will NOT control how a trailing array
is considered as a flex array member anymore. Only the level of
-fstrict-flex-arrays will
> On Nov 22, 2022, at 9:10 AM, Qing Zhao via Gcc-patches
> wrote:
>
>
>
>> On Nov 22, 2022, at 3:16 AM, Richard Biener wrote:
>>
>> On Mon, 21 Nov 2022, Qing Zhao wrote:
>>
>>>
>>>
>>>> On Nov 18, 2022, at 11:31 AM,
> On Nov 22, 2022, at 3:16 AM, Richard Biener wrote:
>
> On Mon, 21 Nov 2022, Qing Zhao wrote:
>
>>
>>
>>> On Nov 18, 2022, at 11:31 AM, Kees Cook wrote:
>>>
>>> On Fri, Nov 18, 2022 at 03:19:07PM +, Qing Zhao wrote:
>>&
> On Nov 18, 2022, at 11:31 AM, Kees Cook wrote:
>
> On Fri, Nov 18, 2022 at 03:19:07PM +0000, Qing Zhao wrote:
>> Hi, Richard,
>>
>> Honestly, it’s very hard for me to decide what’s the best way to handle the
>> interaction
>> between -fs
AM, Richard Biener wrote:
>
> On Tue, 8 Nov 2022, Qing Zhao wrote:
>
>> '-Wstrict-flex-arrays'
>> Warn about inproper usages of flexible array members according to
>> the LEVEL of the 'strict_flex_array (LEVEL)' attribute attached to
>> the trailin
Ping on this patch.
thanks.
Qing
> On Nov 8, 2022, at 9:51 AM, Qing Zhao wrote:
>
> '-Wstrict-flex-arrays'
> Warn about inproper usages of flexible array members according to
> the LEVEL of the 'strict_flex_array (LEVEL)' attribute attached to
> the tr
Thanks.
Committed as: https://gcc.gnu.org/pipermail/gcc-cvs/2022-November/373830.html
Qing
> On Nov 9, 2022, at 2:57 AM, Richard Biener wrote:
>
> On Tue, 8 Nov 2022, Qing Zhao wrote:
>
>> The name of the utility routine "array_at_struct_end_p" is misleading
>&
The name of the utility routine "array_at_struct_end_p" is misleading
and should be changed to a new name that more accurately reflects its
real meaning.
The routine "array_at_struct_end_p" is used to check whether an array
reference is to an array whose actual size might be larger than its
upper
This patch serie include two changes:
1. Change the name of array_at_struct_end_p to array_ref_flexible_size_p.
2. Add a new warning option -Wstrict-flex-arrays and at the same time
keep -Warray-bounds unchanged from -fstrict-flex-arrays.
The new warning -Wstrict-flex-arrays is implemented
'-Wstrict-flex-arrays'
Warn about inproper usages of flexible array members according to
the LEVEL of the 'strict_flex_array (LEVEL)' attribute attached to
the trailing array field of a structure if it's available,
otherwise according to the LEVEL of the option
> On Oct 26, 2022, at 5:29 PM, Alexandre Oliva wrote:
>
> On Oct 25, 2022, Qing Zhao wrote:
>
>>> 'all' for leaf functions is likely wasteful. If no other functions are
>>> called, one can determine exactly which registers might carry
>>> informati
Hi, Alexandre,
> On Oct 24, 2022, at 10:48 PM, Alexandre Oliva wrote:
>
> Hello, Qing,
>
> It was a pleasure to meet you at the Cauldron.
Me too!
>
>
> On Oct 21, 2022, Qing Zhao wrote:
>
>> Hi, Alexandre,
>> Could you please explain a little bi
> On Oct 24, 2022, at 3:30 AM, Richard Biener wrote:
>
> On Sat, 22 Oct 2022, Martin Sebor wrote:
>
>> On 10/21/22 09:29, Qing Zhao wrote:
>>> Hi,
>>>
>>> (FAM below refers to Flexible Array Members):
>>>
>>> I need i
> On Oct 22, 2022, at 12:54 PM, Martin Sebor wrote:
>
> On 10/21/22 09:29, Qing Zhao wrote:
>> Hi,
>> (FAM below refers to Flexible Array Members):
>> I need inputs on how to handle the combination of -fstrict-flex-arrays +
>> -Warray-bounds.
>> Our i
Hi,
(FAM below refers to Flexible Array Members):
I need inputs on how to handle the combination of -fstrict-flex-arrays +
-Warray-bounds.
Our initial goal is to update -Warray-bounds with multiple levels of
-fstrict-flex-arrays=N
to issue warnings according to the different levels of “N”.
Hi, Alexandre,
Could you please explain a little bit on the motivation of this patch first?
thanks.
Qing
> On Oct 21, 2022, at 3:31 AM, Alexandre Oliva wrote:
>
> Introduce 'leafy' to auto-select between 'used' and 'all' for leaf and
> nonleaf functions, respectively.
>
> Regstrapped on
FYI.
I just committed the patches to gcc13:
https://gcc.gnu.org/pipermail/gcc-cvs/2022-October/372114.html
https://gcc.gnu.org/pipermail/gcc-cvs/2022-October/372115.html
thanks.
Qing
> On Oct 6, 2022, at 8:49 AM, Qing Zhao via Gcc-patches
> wrote:
>
>
>
>> On Oc
> On Oct 7, 2022, at 10:43 AM, Jan Hubicka wrote:
>
Probably not hard, and the IPA pass adjusting visbility could as well
mark the functions
as not to be inlined with -flive-patching=inline-only-static.
>>
>> OTOH inline-only-static could disable WPA inlining and
> On Oct 7, 2022, at 9:03 AM, Jan Hubicka wrote:
>
>>> WPA is Whole Program Analysis?
>>
>> Yes.
>>
>>> Okay, then It will promote all static function to extern functions. That’s
>>> reasonable.
>>
>> No, all extern functions to static functions.
>>
>>> Is it hard to preserve the
> On Oct 7, 2022, at 2:34 AM, Richard Biener wrote:
>
> On Thu, Oct 6, 2022 at 3:18 PM Qing Zhao wrote:
>>
>>
>>
>>> On Oct 6, 2022, at 4:29 AM, Richard Biener
>>> wrote:
>>>
>>> On Wed, Oct 5, 2022 at 8:18 PM Qing Zhao via
> On Oct 6, 2022, at 4:29 AM, Richard Biener wrote:
>
> On Wed, Oct 5, 2022 at 8:18 PM Qing Zhao via Gcc-patches
> wrote:
>>
>>
>>
>>> On Oct 5, 2022, at 1:36 PM, Martin Liška wrote:
>>>
>>> On 10/5/22 16:50, Qing Zhao
> On Oct 5, 2022, at 4:25 PM, Joseph Myers wrote:
>
> On Wed, 5 Oct 2022, Qing Zhao via Gcc-patches wrote:
>
>> + /* if not the last field, return false. */
>
> Comments should start with an uppercase letter.
>
>> + /* if
Add the following new option -fstrict-flex-arrays[=n] and a corresponding
attribute strict_flex_array to GCC:
'-fstrict-flex-arrays'
Control when to treat the trailing array of a structure as a flexible array
member for the purpose of accessing the elements of such an array.
The
Use array_at_struct_end_p to determine whether the trailing array
of a structure is flexible array member in __builtin_object_size.
gcc/ChangeLog:
PR tree-optimization/101836
* tree-object-size.cc (addr_object_size): Use array_at_struct_end_p
to determine a flexible array
the V3 of the
patch review. So, Joseph, could you please take a look at the FE and
doc changes and let me know whether they are good to commit?
thanks a lot.
Qing
Qing Zhao (2):
Add a new option -fstrict-flex-arrays[=n] and new attribute
strict_flex_array
Use array_at_struct_end_p in __builtin_object_size [PR101836]
> On Oct 5, 2022, at 1:36 PM, Martin Liška wrote:
>
> On 10/5/22 16:50, Qing Zhao wrote:
>> I have two questions on this:
>
> Hello.
>
>>
>> 1. What’s the motivation to enable -flive-patching with -flto? Is there any
>> application that will try
Hi, Martin:
I have two questions on this:
1. What’s the motivation to enable -flive-patching with -flto? Is there any
application that will try -flive-patching with -flto now?
2. Why only enable -flive-patching=inline-clone with -flto?
thanks.
Qing
> On Oct 5, 2022, at 7:41 AM, Martin
> On Oct 4, 2022, at 1:37 PM, Joseph Myers wrote:
>
> On Tue, 4 Oct 2022, Qing Zhao via Gcc-patches wrote:
>
>> + { "strict_flex_array", 1, 1, false, false, false, false,
>> + handle_strict_flex_array_attribute,
Use array_at_struct_end_p to determine whether the trailing array
of a structure is flexible array member in __builtin_object_size.
gcc/ChangeLog:
PR tree-optimization/101836
* tree-object-size.cc (addr_object_size): Use array_at_struct_end_p
to determine a flexible array
nge has been Okayed by Bichard in the V3 of the
patch review. So, Joseph, could you please take a look at the FE and
doc changes and let me know whether they are good to commit?
thanks a lot.
Qing
Qing Zhao (2):
Add a new option -fstrict-flex-arrays[=n] and new attribute
strict_flex_arr
Add the following new option -fstrict-flex-arrays[=n] and a corresponding
attribute strict_flex_array to GCC:
'-fstrict-flex-arrays'
Control when to treat the trailing array of a structure as a flexible array
member for the purpose of accessing the elements of such an array.
The
> On Sep 30, 2022, at 1:39 PM, Martin Sebor wrote:
>
> On 9/28/22 13:17, Qing Zhao wrote:
>> Hi, Martin,
>> Thanks for the comments. And sorry for my late reply till now (I just came
>> back home from LPC, GNU Cauldron and then a one-week vacation after that…)
>&
Hi, Martin,
Thanks for the comments. And sorry for my late reply till now (I just came back
home from LPC, GNU Cauldron and then a one-week vacation after that…)
> On Sep 12, 2022, at 12:42 PM, Martin Sebor wrote:
>
> On 9/6/22 18:28, Qing Zhao wrote:
>> Add the following new
Add the following new option -fstrict-flex-arrays[=n] and a corresponding
attribute strict_flex_arrays to GCC:
'-fstrict-flex-arrays'
Treat the trailing array of a structure as a flexible array member
in a stricter way. The positive form is equivalent to
'-fstrict-flex-arrays=3',
Use array_at_struct_end_p to determine whether the trailing array
of a structure is flexible array member in __builtin_object_size.
gcc/ChangeLog:
PR tree-optimization/101836
* tree-object-size.cc (addr_object_size): Use array_at_struct_end_p
to determine a flexible array
changes, and documentation format changes
recommanded by Joseph.
I have bootstrapped and regression tested on both aarch64 and x86, no issues.
Let me know if you have any comments on the patches.
thanks.
Qing Zhao (2):
Add a new option -fstrict-flex-arrays[=n] and new attribute
Okay, then I will delete those new warnings I added in the version 3 of the
patch.
Thanks.
Qing
> On Sep 1, 2022, at 2:11 AM, Richard Biener wrote:
>
> On Wed, 31 Aug 2022, Kees Cook wrote:
>
>> On Wed, Aug 31, 2022 at 08:35:12PM +, Qing Zhao wrote:
>>>
> On Aug 31, 2022, at 4:16 PM, Qing Zhao via Gcc-patches
> wrote:
>
> Okay, I am fine with this.
Another thought on this is:
One of the major purposes of the new option -fstrict-flex-array is to encourage
standard conforming programming style.
So, it might be reasonable to tr
Okay, I am fine with this.
Richard and Kees, what’s your opinion on this?
thanks.
Qing
> On Aug 31, 2022, at 4:09 PM, Joseph Myers wrote:
>
> On Wed, 31 Aug 2022, Qing Zhao wrote:
>
>>>> When -std=gnu89 + -fstrict-flex-array=3 (ONLY C99 flexible array member
>&
> On Aug 31, 2022, at 3:52 PM, Joseph Myers wrote:
>
> On Wed, 31 Aug 2022, Qing Zhao wrote:
>
>> Does the above mean that -std=gnu89 does not support C99 flexible array
>> member, then
>
> No.
>
> Flexible array members are supported by GCC in all C s
> On Aug 31, 2022, at 3:29 PM, Joseph Myers wrote:
>
> On Wed, 31 Aug 2022, Qing Zhao via Gcc-patches wrote:
>
>>> How is level 3 (thus -fstrict-flex-array) interpreted when you specify
>>> -std=c89? How for -std=gnu89?
>>
>> 1. what’s the major
> On Aug 31, 2022, at 2:55 PM, Qing Zhao via Gcc-patches
> wrote:
>
>
>
>> On Aug 31, 2022, at 1:21 PM, Joseph Myers wrote:
>>
>> On Wed, 31 Aug 2022, Qing Zhao via Gcc-patches wrote:
>>
>>>> "a GNU extension" suggests a p
> On Aug 31, 2022, at 1:21 PM, Joseph Myers wrote:
>
> On Wed, 31 Aug 2022, Qing Zhao via Gcc-patches wrote:
>
>>> "a GNU extension" suggests a particular language feature, but I think
>>> you're actually referring here to a whole language versio
Hi, Joseph,
Thanks a lot for your comment.
> On Aug 30, 2022, at 6:53 PM, Joseph Myers wrote:
>
> On Tue, 30 Aug 2022, Qing Zhao via Gcc-patches wrote:
>
>> Hi, Joseph and Nathan,
>>
>> Could you please review the C and C++ FE parts of the patch?
>>
.
Begin forwarded message:
From: Qing Zhao mailto:qing.z...@oracle.com>>
Subject: [[GCC13][Patch][V3] 1/2] Add a new option -fstrict-flex-array[=n] and
new attribute strict_flex_array
Date: August 17, 2022 at 10:40:41 AM EDT
To: gcc-patches@gcc.gnu.org<mailto:gcc-patches@gcc.gnu.org>
> On Aug 26, 2022, at 4:48 AM, Richard Biener wrote:
>
> On Wed, 17 Aug 2022, Qing Zhao wrote:
>
>> Add the following new option -fstrict-flex-array[=n] and a corresponding
>> attribute strict_flex_array to GCC:
>>
>> '-fstrict-flex-array'
>>
> On Aug 26, 2022, at 4:49 AM, Richard Biener wrote:
>
> On Wed, 17 Aug 2022, Qing Zhao wrote:
>
>> Use array_at_struct_end_p to determine whether the trailing array
>> of a structure is flexible array member in __builtin_object_size.
>
> With the discussion ab
Add the following new option -fstrict-flex-array[=n] and a corresponding
attribute strict_flex_array to GCC:
'-fstrict-flex-array'
Treat the trailing array of a structure as a flexible array member
in a stricter way. The positive form is equivalent to
'-fstrict-flex-array=3',
Use array_at_struct_end_p to determine whether the trailing array
of a structure is flexible array member in __builtin_object_size.
gcc/ChangeLog:
PR tree-optimization/101836
* tree-object-size.cc (addr_object_size): Use array_at_struct_end_p
to determine a flexible array
Hi,
This is the 3rd version of the patch set.
Compare to the 2nd version, the following are the major change:
1. change the name of the option from -fstrict-flex-array to
-fstrict-flex-arrays (per Kees' suggestion, this will be consistent with LLVM's
option);
2. -std=c89 and ISO C++ will
> On Aug 16, 2022, at 8:37 AM, Richard Biener
> wrote:
>
> On Tue, Aug 16, 2022 at 2:16 PM Nathan Sidwell wrote:
>>
>> On 8/15/22 10:03, Richard Biener wrote:
>>> On Mon, Aug 15, 2022 at 3:29 PM Nathan Sidwell via Gcc-patches
>>> wrote:
>>>
> On Aug 15, 2022, at 9:28 AM, Nathan Sidwell wrote:
>
> On 8/2/22 10:44, Qing Zhao wrote:
>> Hi, Nathan,
>> I am adding a new bitfield “decl_not_flexarray” in “tree_decl_common”
>> (gcc/tree-core.h) for the new gcc feature -fstrict-flex-arrays.
>>
>
> On Aug 11, 2022, at 3:40 AM, Richard Biener wrote:
>
> On Wed, 10 Aug 2022, Qing Zhao wrote:
>
>> Hi,
>>
>> As mentioned in the bug report, I reopened this bug since the previous patch:
>>
>> commit r13-1875-gff26f0ba68fe6e870f315d0601b596f88
Hi,
As mentioned in the bug report, I reopened this bug since the previous patch:
commit r13-1875-gff26f0ba68fe6e870f315d0601b596f889b89680
Author: Richard Biener
Date: Thu Jul 28 10:07:32 2022 +0200
middle-end/106457 - improve array_at_struct_end_p for array objects
Array references
Never mind, just found how to do this:
/* { dg-warning "'-fstrict-flex-arrays' is not supported with a ISO C before
C99, ignored" "" { target *-*-* } 0 } */
And worked.
thanks.
Qing
> On Aug 3, 2022, at 2:52 PM, Qing Zhao via Gcc-patches
> wrote:
>
>
Hi,
My private cc1 issued the following warning:
[opc@qinzhao-ol8u3-x86 gcc]$ sh t
cc1: warning: ‘-fstrict-flex-arrays’ is not supported with a ISO C before C99,
ignored
I’d like to add a testing case for this warning into gcc.dg directory, however,
I cannot find a proper
testing directive
> On Aug 2, 2022, at 12:34 PM, Marek Polacek wrote:
>
> On Tue, Aug 02, 2022 at 04:19:56PM +0000, Qing Zhao via Gcc-patches wrote:
>> Hi, Joseph,
>>
>> When -std=c89 or -std=gnu89 present in the command line, in C FE, which
>> flags should be
>> checke
Hi, Joseph,
When -std=c89 or -std=gnu89 present in the command line, in C FE, which flags
should be
checked to decide it’s -std=c89 or -std=gnu89?
Thanks a lot for your help.
Qing
Thanks a lot for your testing on Linux Kernel.
Will work on the version 3 of this patch soon.
Qing
> On Aug 2, 2022, at 11:30 AM, Kees Cook wrote:
>
> On Tue, Jul 19, 2022 at 02:11:19PM +0000, Qing Zhao wrote:
>> From a09f39ded462611286a44d9e8273de8342673ba2 Mon Sep 17 00:00:
Hi, Nathan,
I am adding a new bitfield “decl_not_flexarray” in “tree_decl_common”
(gcc/tree-core.h) for the new gcc feature -fstrict-flex-arrays.
diff --git a/gcc/tree-core.h b/gcc/tree-core.h
index ea9f281f1cc..458c6e6ceea 100644
--- a/gcc/tree-core.h
+++ b/gcc/tree-core.h
@@ -1813,7
> On Aug 2, 2022, at 3:03 AM, Richard Biener wrote:
>
> On Mon, 1 Aug 2022, Qing Zhao wrote:
>
>>
>>
>>> On Aug 1, 2022, at 3:38 AM, Richard Biener wrote:
>>>
>>> On Fri, 29 Jul 2022, Qing Zhao wrote:
>>>
>>>>
> On Aug 1, 2022, at 3:38 AM, Richard Biener wrote:
>
> On Fri, 29 Jul 2022, Qing Zhao wrote:
>
>> Hi, Richard,
>>
>> Thanks a lot for your comments and suggestions. (And sorry for my late
>> reply).
>>
>>> On Jul 28, 2022, at 3:26 AM,
> On Aug 1, 2022, at 3:13 AM, Richard Biener wrote:
>
> On Fri, 29 Jul 2022, Qing Zhao wrote:
>
>>
>>
>>> On Jul 28, 2022, at 3:28 AM, Richard Biener wrote:
>>>
>>> On Tue, 19 Jul 2022, Qing Zhao wrote:
>>>
>>>>
Hi, Richard,
Thanks a lot for your comments and suggestions. (And sorry for my late reply).
> On Jul 28, 2022, at 3:26 AM, Richard Biener wrote:
>
> On Tue, 19 Jul 2022, Qing Zhao wrote:
>
>> From 3854004802b8e2f132ebf218fc35a632f5e80c6a Mon Sep 17 00:00:00 2001
>>
> On Jul 28, 2022, at 3:28 AM, Richard Biener wrote:
>
> On Tue, 19 Jul 2022, Qing Zhao wrote:
>
>> From a09f39ded462611286a44d9e8273de8342673ba2 Mon Sep 17 00:00:00 2001
>> From: Qing Zhao
>> Date: Mon, 18 Jul 2022 18:12:26 +
>> Subject: [PATCH
>From a09f39ded462611286a44d9e8273de8342673ba2 Mon Sep 17 00:00:00 2001
From: Qing Zhao
Date: Mon, 18 Jul 2022 18:12:26 +
Subject: [PATCH 2/2] Use new flag DECL_NOT_FLEXARRAY in __builtin_object_size
[PR101836]
Use new flag DECL_NOT_FLEXARRAY to determine whether the trailing ar
>From 3854004802b8e2f132ebf218fc35a632f5e80c6a Mon Sep 17 00:00:00 2001
From: Qing Zhao
Date: Mon, 18 Jul 2022 17:04:12 +
Subject: [PATCH 1/2] Add a new option -fstrict-flex-array[=n] and new
attribute strict_flex_array
Add the following new option -fstrict-flex-array[=n] and a correspond
Hi,
Based on the previous discussion on the Version 1 of the patch:
https://gcc.gnu.org/pipermail/gcc-patches/2022-June/597350.html
https://gcc.gnu.org/pipermail/gcc-patches/2022-July/598010.html
We decided:
*User interface:
. command line option in C/C++:
-fstrict-flex-array[=N]
> On Jul 7, 2022, at 4:02 AM, Richard Biener wrote:
>
> On Wed, Jul 6, 2022 at 4:20 PM Qing Zhao wrote:
>>
>> (Sorry for the late reply, just came back from a short vacation.)
>>
>>> On Jul 4, 2022, at 2:49 AM, Richard Biener
>>> wrote:
>>
(Sorry for the late reply, just came back from a short vacation.)
> On Jul 4, 2022, at 2:49 AM, Richard Biener wrote:
>
> On Fri, Jul 1, 2022 at 5:32 PM Martin Sebor wrote:
>>
>> On 7/1/22 08:01, Qing Zhao wrote:
>>>
>>>
>>>&g
> On Jul 1, 2022, at 8:59 AM, Jakub Jelinek wrote:
>
> On Fri, Jul 01, 2022 at 12:55:08PM +0000, Qing Zhao wrote:
>> If so, comparing to the current implemenation to have all the checking in
>> middle-end, what’s the
>> major benefit of moving part of the ch
> On Jul 1, 2022, at 8:58 AM, Richard Biener wrote:
>
> On Fri, Jul 1, 2022 at 2:55 PM Qing Zhao wrote:
>>
>>
>>
>>> On Jul 1, 2022, at 2:49 AM, Richard Biener
>>> wrote:
>>>
>>> On Thu, Jun 30, 2022 at 9:30 PM Qing Zhao wr
> On Jul 1, 2022, at 2:49 AM, Richard Biener wrote:
>
> On Thu, Jun 30, 2022 at 9:30 PM Qing Zhao wrote:
>>
>>
>>
>>> On Jun 30, 2022, at 1:03 PM, Jakub Jelinek wrote:
>>>
>>> On Thu, Jun 30, 2022 at 03:31:00PM +, Qing Zhao w
> On Jun 30, 2022, at 1:03 PM, Jakub Jelinek wrote:
>
> On Thu, Jun 30, 2022 at 03:31:00PM +0000, Qing Zhao wrote:
>>> No, that’s not true. A FIELD_DELC is only shared for cv variants of a
>>> structure.
>>
>> Sorry for my dump questions:
>
> On Jun 30, 2022, at 10:24 AM, Richard Biener
> wrote:
>
>
>
>> Am 30.06.2022 um 16:08 schrieb Qing Zhao via Gcc-patches
>> :
>>
>>
>>
>>> On Jun 29, 2022, at 5:14 PM, Martin Sebor wrote:
>>>
>>> On 6/28/22
> On Jun 29, 2022, at 5:14 PM, Martin Sebor wrote:
>
> On 6/28/22 13:01, Qing Zhao wrote:
>>> On Jun 28, 2022, at 2:49 PM, Jakub Jelinek wrote:
>>>
>>> On Tue, Jun 28, 2022 at 06:29:01PM +, Qing Zhao wrote:
>>>>
>>>&
Hi, Jakub and Joseph:
> On Jun 28, 2022, at 12:43 PM, Jakub Jelinek wrote:
>
> On Tue, Jun 28, 2022 at 03:59:22PM +0000, Qing Zhao via Gcc-patches wrote:
>>> On Jun 28, 2022, at 11:08 AM, Jakub Jelinek wrote:
>>>
>>> On Tue, Jun 28, 2022 at 03:03
> On Jun 28, 2022, at 2:49 PM, Jakub Jelinek wrote:
>
> On Tue, Jun 28, 2022 at 06:29:01PM +0000, Qing Zhao wrote:
>>
>>
>>> On Jun 28, 2022, at 2:22 PM, Jakub Jelinek wrote:
>>>
>>> On Tue, Jun 28, 2022 at 06:15:58PM +, Qing Zhao wrote
> On Jun 28, 2022, at 2:22 PM, Jakub Jelinek wrote:
>
> On Tue, Jun 28, 2022 at 06:15:58PM +0000, Qing Zhao wrote:
>>> Because the flag just tells whether some array shouldn't be treated as
>>> (poor man's)
>>> flexible array member. We still
> On Jun 28, 2022, at 12:43 PM, Jakub Jelinek wrote:
>
> On Tue, Jun 28, 2022 at 03:59:22PM +0000, Qing Zhao via Gcc-patches wrote:
>>> On Jun 28, 2022, at 11:08 AM, Jakub Jelinek wrote:
>>>
>>> On Tue, Jun 28, 2022 at 03:03:12PM +, Qing
> On Jun 28, 2022, at 11:08 AM, Jakub Jelinek wrote:
>
> On Tue, Jun 28, 2022 at 03:03:12PM +0000, Qing Zhao wrote:
>> 2. Then replace all “array_at_struct_end_p” with using DECL_NOT_FLEXARRAY in
>> GCC, adding new testing cases
>
> No, IMHO array_at_struct_end_p s
Hi, Richard,
> On Jun 28, 2022, at 3:16 AM, Richard Biener
> wrote:
>
> On Mon, Jun 27, 2022 at 4:20 PM Qing Zhao via Gcc-patches
> wrote:
>>
>> Hi,
>>
>> Per our discussion in the bug report, I came up with the following patch:
>>
>>
Hi,
Per our discussion in the bug report, I came up with the following patch:
===
PR101836: Add a new option -fstrict-flex-array[=n]
Add the new option and use it in __builtin_object_size.
Treat the trailing array of a structure as a flexible array member in a
stricter way. The value of
Pushed to both gcc11 and gcc12.
thanks.
Qing
> On May 24, 2022, at 1:19 AM, Richard Biener wrote:
>
> On Mon, 23 May 2022, Qing Zhao wrote:
>
>> Hi,
>>
>> I have added the patch to GCC11 and GCC12 in my local area and bootstrapped
>> and regress te
Hi,
I have added the patch to GCC11 and GCC12 in my local area and bootstrapped and
regress tested on both x86 and aarch64, no any issues.
Can I committed them to both GCC11 and GCC12 branches?
Thanks.
> On May 10, 2022, at 8:38 AM, Qing Zhao via Gcc-patches
> wrote:
>
>
&g
> On May 10, 2022, at 1:12 AM, Richard Biener wrote:
>
> On Mon, 9 May 2022, Uros Bizjak wrote:
>
>> On Mon, May 9, 2022 at 5:44 PM Qing Zhao wrote:
>>>
>>> Another question:
>>>
>>> I think that this patch might need to be back p
Another question:
I think that this patch might need to be back ported to Gcc12 and GCC11.
What’s your opinion on this?
If so, when can I backport it?
thanks.
Qing
> On May 7, 2022, at 4:06 AM, Uros Bizjak wrote:
>
> On Fri, May 6, 2022 at 6:42 PM Qing Zhao wrote:
>>
>&
> On May 7, 2022, at 4:06 AM, Uros Bizjak wrote:
>
> On Fri, May 6, 2022 at 6:42 PM Qing Zhao wrote:
>>
>>
>>
>>> On May 6, 2022, at 10:58 AM, Uros Bizjak wrote:
>>>
>>> On Fri, May 6, 2022 at 4:29 PM Qing Zhao wrote:
>>>&g
> On May 6, 2022, at 10:58 AM, Uros Bizjak wrote:
>
> On Fri, May 6, 2022 at 4:29 PM Qing Zhao wrote:
>>
>> Hi,
>>
>> As Kee’s requested in this PR:
>> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101891
>>
>> =
>>
>> Cu
Hi,
As Kee’s requested in this PR:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101891
=
Currently -fzero-call-used-regs will use a pattern of:
XOR regA,regA
MOV regA,regB
MOV regA,regC
...
RET
However, this introduces both a register ordering dependency (e.g. the CPU
cannot clear regB
501 - 600 of 1199 matches
Mail list logo