Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id CD278200C16 for ; Thu, 26 Jan 2017 00:09:10 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id CB982160B5A; Wed, 25 Jan 2017 23:09:10 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 20D17160B4E for ; Thu, 26 Jan 2017 00:09:09 +0100 (CET) Received: (qmail 96925 invoked by uid 500); 25 Jan 2017 23:09:09 -0000 Mailing-List: contact reviews-help@impala.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list reviews@impala.incubator.apache.org Received: (qmail 96914 invoked by uid 99); 25 Jan 2017 23:09:09 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 25 Jan 2017 23:09:09 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id B640BC23C0 for ; Wed, 25 Jan 2017 23:09:08 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.362 X-Spam-Level: X-Spam-Status: No, score=0.362 tagged_above=-999 required=6.31 tests=[RDNS_DYNAMIC=0.363, SPF_PASS=-0.001] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id VFcBiPYUDT-x for ; Wed, 25 Jan 2017 23:09:08 +0000 (UTC) Received: from ip-10-146-233-104.ec2.internal (ec2-75-101-130-251.compute-1.amazonaws.com [75.101.130.251]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id C44185FB79 for ; Wed, 25 Jan 2017 23:09:07 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by ip-10-146-233-104.ec2.internal (8.14.4/8.14.4) with ESMTP id v0PN8V9A016948; Wed, 25 Jan 2017 23:08:31 GMT Message-Id: <201701252308.v0PN8V9A016948@ip-10-146-233-104.ec2.internal> Date: Wed, 25 Jan 2017 23:08:31 +0000 From: "Alex Behm (Code Review)" To: impala-cr@cloudera.com, reviews@impala.incubator.apache.org CC: Jim Apple , Michael Ho Reply-To: alex.behm@cloudera.com X-Gerrit-MessageType: comment Subject: =?UTF-8?Q?=5BImpala-ASF-CR=5D_IMPALA-4055=3A_Speed_up_to_date=28=29_with_custom_implementation=2E=0A?= X-Gerrit-Change-Id: I5713b3e0c27b739aae597a6911cf3b2ddd01f822 X-Gerrit-ChangeURL: X-Gerrit-Commit: a69ac4eb1b9c28cbf9dcb7d9930778d4fec2c9b4 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Content-Disposition: inline User-Agent: Gerrit/2.12.2 archived-at: Wed, 25 Jan 2017 23:09:11 -0000 Alex Behm has posted comments on this change. Change subject: IMPALA-4055: Speed up to_date() with custom implementation. ...................................................................... Patch Set 3: (2 comments) I also added an extra safety after discussion this with Tim. We believe that some of our functions may return malformed timestamps, so it's safer to be defensive for now. http://gerrit.cloudera.org:8080/#/c/5791/3/be/src/exprs/timestamp-functions-ir.cc File be/src/exprs/timestamp-functions-ir.cc: Line 326: static inline void IntToChar(uint8_t* dst, int num, int len) { > WFM. Done Line 338: DCHECK(ts_value.IsValidDate()); > This ensures ts_value.date().year() is >= 0 and <= 9999, yes? Yes. Between 1400 and 9999 to be precise. -- To view, visit http://gerrit.cloudera.org:8080/5791 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-MessageType: comment Gerrit-Change-Id: I5713b3e0c27b739aae597a6911cf3b2ddd01f822 Gerrit-PatchSet: 3 Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-Owner: Alex Behm Gerrit-Reviewer: Alex Behm Gerrit-Reviewer: Jim Apple Gerrit-Reviewer: Michael Ho Gerrit-HasComments: Yes