Re: [PATCH] Fix ICU miscompilation due to tree-ssa-strlen.c bug (PR tree-optimization/88693)

2019-01-11 Thread Jeff Law
On 1/4/19 3:54 PM, Jakub Jelinek wrote: > Hi! > > The following patch fixes ICU miscompilation, where an initial part of a > buffer is initializer from non-zero terminated string literal (in ICU > actually from an array of non-zero chars that the FE newly turns into > non-zero terminated string

Patch ping (was Re: [PATCH] Fix ICU miscompilation due to tree-ssa-strlen.c bug (PR tree-optimization/88693))

2019-01-11 Thread Jakub Jelinek
On Fri, Jan 04, 2019 at 11:54:46PM +0100, Jakub Jelinek wrote: > The following patch fixes ICU miscompilation, where an initial part of a > buffer is initializer from non-zero terminated string literal (in ICU > actually from an array of non-zero chars that the FE newly turns into > non-zero

Re: [PATCH] Fix ICU miscompilation due to tree-ssa-strlen.c bug (PR tree-optimization/88693)

2019-01-05 Thread Jakub Jelinek
On Sat, Jan 05, 2019 at 01:17:21PM +, Bernd Edlinger wrote: > Well, yes it works, but this can only optimize invalid code like > strlen((char*)L"wide"). There is nothing invalid on it. Furthermore, the strlen pass doesn't optimize just strlen, it does many optimizations that rely on knowing

Re: [PATCH] Fix ICU miscompilation due to tree-ssa-strlen.c bug (PR tree-optimization/88693)

2019-01-05 Thread Bernd Edlinger
On 1/5/19 1:31 PM, Jakub Jelinek wrote: > On Sat, Jan 05, 2019 at 12:20:24PM +, Bernd Edlinger wrote: >> co-incidentally my "Make strlen range computations more conservative" patch >> contained a fix on the same spot, I just did not have a test case for it: >> >> @@ -3184,7 +3146,10 @@

Re: [PATCH] Fix ICU miscompilation due to tree-ssa-strlen.c bug (PR tree-optimization/88693)

2019-01-05 Thread Jakub Jelinek
On Sat, Jan 05, 2019 at 12:20:24PM +, Bernd Edlinger wrote: > co-incidentally my "Make strlen range computations more conservative" patch > contained a fix on the same spot, I just did not have a test case for it: > > @@ -3184,7 +3146,10 @@ get_min_string_length (tree rhs, bool *f >&&

Re: [PATCH] Fix ICU miscompilation due to tree-ssa-strlen.c bug (PR tree-optimization/88693)

2019-01-05 Thread Bernd Edlinger
Hi, co-incidentally my "Make strlen range computations more conservative" patch contained a fix on the same spot, I just did not have a test case for it: @@ -3184,7 +3146,10 @@ get_min_string_length (tree rhs, bool *f && TREE_READONLY (rhs)) rhs = DECL_INITIAL (rhs); - if (rhs &&

Re: [PATCH] Fix ICU miscompilation due to tree-ssa-strlen.c bug (PR tree-optimization/88693)

2019-01-04 Thread Jeff Law
On 1/4/19 3:54 PM, Jakub Jelinek wrote: > Hi! > > The following patch fixes ICU miscompilation, where an initial part of a > buffer is initializer from non-zero terminated string literal (in ICU > actually from an array of non-zero chars that the FE newly turns into > non-zero terminated string

[PATCH] Fix ICU miscompilation due to tree-ssa-strlen.c bug (PR tree-optimization/88693)

2019-01-04 Thread Jakub Jelinek
Hi! The following patch fixes ICU miscompilation, where an initial part of a buffer is initializer from non-zero terminated string literal (in ICU actually from an array of non-zero chars that the FE newly turns into non-zero terminated string literal), but the code recently added to