[ 
https://issues.apache.org/jira/browse/QUICKSTEP-53?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15463806#comment-15463806
 ] 

ASF GitHub Bot commented on QUICKSTEP-53:
-----------------------------------------

Github user zuyu commented on the issue:

    https://github.com/apache/incubator-quickstep/pull/98
  
    > For the efficiency part:
    1-) Using new comparison operators obviously are faster than old 
counterparts using if else statements. (Of course the overall effect might not 
be fast as we expected in the TPCH queries.) Thank you.
    
    I agree there would be some improvements in the theory, but do you have the 
number?
    
    > 2-) No matter why TypedValue is used in query processing , the cutting 
the size of struct representation by 50% improves the memory usage:
    a-) A page can contain 50% more values.
    b-) Recent x86 architectures favor using the values 32 bits or 64 bits, not 
48 bits.
    
    I don't think so. The existing represent of one `uint32_t` and two 
`uint8_t`s would take 64 bits in total due to memory alignment requirements, 
instead of 48 bits as what you thought. Furthermore, as we use `TypeValue` 
instead of `DateLit` directly, I don't see much space improvements after 
refactoring using one single `uint32_t`.


> New representation and faster comparison operators for DateLit
> --------------------------------------------------------------
>
>                 Key: QUICKSTEP-53
>                 URL: https://issues.apache.org/jira/browse/QUICKSTEP-53
>             Project: Apache Quickstep
>          Issue Type: Improvement
>          Components: Types
>            Reporter: Hakan Memisoglu
>            Assignee: Hakan Memisoglu
>
> DateLit structure contains 3 member: 
> 32i for year,
> 8u for month,
> 8u for day.
> Instead we can put all year, month, and day information into 32u. It will 
> benefit from having a smaller sized representation.
> The new representation also provide faster comparison operator by directly 
> using 32u comparison operators that have corresponding assembly primitives 
> (instead of using if else branches).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to