You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by "Bryan Duxbury (JIRA)" <ji...@apache.org> on 2010/01/14 20:09:54 UTC

[jira] Updated: (THRIFT-674) Generated read() should just switch directly on field.id

     [ https://issues.apache.org/jira/browse/THRIFT-674?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bryan Duxbury updated THRIFT-674:
---------------------------------

    Attachment: thrift-674.patch

This patch does as you suggests. Can you try it out in your benchmarks and let me know if it replicates your performance improvements?

> Generated read() should just switch directly on field.id
> --------------------------------------------------------
>
>                 Key: THRIFT-674
>                 URL: https://issues.apache.org/jira/browse/THRIFT-674
>             Project: Thrift
>          Issue Type: Improvement
>          Components: Compiler (Java)
>    Affects Versions: 0.2
>            Reporter: Chad Walters
>            Assignee: Bryan Duxbury
>         Attachments: thrift-674.patch
>
>
> THRIFT-623 introduced a performance regression in the Java bindings.
> Instead of mapping field.id to an enum, testing if the enum is null, and then switching on the enum, the switch should just work directly on field.id, with a default case to handle unknown values.
> In some benchmarks I ran, this fix saved 13% on deserialization time.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.