This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH][RFC] Make expansion of balanced binary trees of switches on tree level.
On 08/18/2017 11:30 AM, Richard Biener wrote:
> On Tue, Aug 15, 2017 at 2:37 PM, Martin Liška <mliska@suse.cz> wrote:
>> On 08/14/2017 10:32 AM, Richard Biener wrote:
>>> Hmm, but the existing "lowering" part is called from the
>>> switch-conversion pass. So
>>> I'm not sure a new file is good.
>>
>> Good, I'm not against having that in a single file. So new version of the patch
>> does that.
>>
>> Patch can bootstrap on ppc64le-redhat-linux and survives regression tests.
>>
>> Ready to be installed?
>
> Hmm, I see you duplicate add_case_node for example. Is that just temporary?
> If not can you please factor out the data structure and common code?
> (case.[Ch]?)
You are right. As we'll generate just jump table in stmt.c the proper fix is to remove
all usages of 'case_node' in the file because simple iteration of labels will work fine.
Let me do it incrementally to minimize fall out :)
Martin
>
> Thanks,
> Richard.
>
>> Martin