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

ASF subversion and git services commented on IMPALA-7032:
---------------------------------------------------------

Commit a64cfc523ecd5ee7f13c3c7ca63cafe510c4610a in impala's branch 
refs/heads/master from [~lv]
[ https://git-wip-us.apache.org/repos/asf?p=impala.git;h=a64cfc5 ]

IMPALA-7032: Disable codegen for CHAR type null literals

Analogous to IMPALA-6435, we have to disable codegen for CHAR type null
literals. Otherwise we will crash in
impala::NullLiteral::GetCodegendComputeFn().

This change adds a test to make sure that the crash is fixed.

Change-Id: I34033362263cf1292418f69c5ca1a3b84aed39a9
Reviewed-on: http://gerrit.cloudera.org:8080/10409
Reviewed-by: Lars Volker <l...@cloudera.com>
Tested-by: Lars Volker <l...@cloudera.com>


> Codegen crash when UNIONing NULL and CHAR(N)
> --------------------------------------------
>
>                 Key: IMPALA-7032
>                 URL: https://issues.apache.org/jira/browse/IMPALA-7032
>             Project: IMPALA
>          Issue Type: Bug
>          Components: Backend
>    Affects Versions: Impala 2.8.0, Impala 2.9.0, Impala 2.10.0, Impala 
> 2.11.0, Impala 3.0, Impala 2.12.0, Impala 2.13.0, Impala 3.1.0
>            Reporter: Balazs Jeszenszky
>            Assignee: Lars Volker
>            Priority: Blocker
>              Labels: crash
>
> A simple repro:
> {code:java}
> create table test (c1 int);
> select null from test union select cast('a' as char(1)) from test;
> {code}
> {code}
> #0  0x00007f050c4a61d7 in raise () from sysroot/lib64/libc.so.6
> #1  0x00007f050c4a78c8 in abort () from sysroot/lib64/libc.so.6
> #2  0x00007f050e7816b5 in os::abort(bool) ()
>    from sysroot/usr/java/jdk1.8.0_60/jre/lib/amd64/server/libjvm.so
> #3  0x00007f050e91fbf3 in VMError::report_and_die() ()
>    from sysroot/usr/java/jdk1.8.0_60/jre/lib/amd64/server/libjvm.so
> #4  0x00007f050e786edf in JVM_handle_linux_signal ()
>    from sysroot/usr/java/jdk1.8.0_60/jre/lib/amd64/server/libjvm.so
> #5  0x00007f050e77d673 in signalHandler(int, siginfo*, void*) ()
>    from sysroot/usr/java/jdk1.8.0_60/jre/lib/amd64/server/libjvm.so
> #6  <signal handler called>
> #7  0x0000000001a9123d in llvm::FunctionType::get(llvm::Type*, 
> llvm::ArrayRef<llvm::Type*>, bool) ()
> #8  0x0000000000c2c04f in impala::LlvmCodeGen::FnPrototype::GeneratePrototype 
> (this=0x7f03e7fdad90,
>     builder=0x0, params=0x7f03e7fdae30, print_ir=<optimized out>)
>     at 
> /usr/src/debug/impala-2.9.0-cdh5.12.2/be/src/codegen/llvm-codegen.cc:710
> #9  0x0000000000846187 in impala::Expr::CreateIrFunctionPrototype 
> (this=this@entry=0x9fded80,
>     codegen=codegen@entry=0xa5a2880, name=..., args=args@entry=0x7f03e7fdae30)
>     at /usr/src/debug/impala-2.9.0-cdh5.12.2/be/src/exprs/expr.cc:505
> #10 0x0000000000861e5c in impala::NullLiteral::GetCodegendComputeFn 
> (this=0x9fded80,
>     codegen=0xa5a2880, fn=0x7f03e7fdaf18)
>     at /usr/src/debug/impala-2.9.0-cdh5.12.2/be/src/exprs/null-literal.cc:106
> #11 0x0000000000a79bc7 in impala::Tuple::CodegenMaterializeExprs 
> (codegen=codegen@entry=0xa5a2880,
>     collect_string_vals=collect_string_vals@entry=false, desc=..., 
> materialize_expr_ctxs=...,
>     use_mem_pool=use_mem_pool@entry=true, fn=0x7f03e7fdb410)
>     at /usr/src/debug/impala-2.9.0-cdh5.12.2/be/src/runtime/tuple.cc:307
> #12 0x0000000000d12828 in impala::UnionNode::Codegen (this=<optimized out>, 
> state=<optimized out>)
>     at /usr/src/debug/impala-2.9.0-cdh5.12.2/be/src/exec/union-node.cc:105
> #13 0x0000000000c4aaa1 in impala::ExecNode::Codegen 
> (this=this@entry=0xa0c5480,
> {code}
> NullLiteral::GetCodegendComputeFn is missing a check for type.CHAR which 
> isn't implemented.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscr...@impala.apache.org
For additional commands, e-mail: issues-all-h...@impala.apache.org

Reply via email to