Regression: SIGILL crashing JVM when loading spatial module in DuckDB 2.0.1.0

Aberta
#1,007 3 comentários 0 reações 0 responsáveis Ver no GitHub

Mantenedores costumam responder em até 1 dia

Ninguém assumiu esta issue ainda.

Avaliação

Dificuldade
3/5
Tempo estimado
1-2 dias
Facilidade para iniciantes
55/100
Tipo de issue
Bug
Clareza
Razoavelmente clara
Status de atividade
Ativa
Stack de tecnologia
java, linux
Domínio
backend, database

Direção de pesquisa

Start by reproducing the crash with the provided Java program and DuckDB JDBC 2.0.1.0 on Ubuntu 26.04, then inspect the attached hs_err log for the native crash details. Compare the same spatial extension load with a 1.x driver to narrow down the regression; done means loading spatial no longer triggers SIGILL in the reported setup.

Escrita pelo modelo de indexação a partir do texto da issue.

Descrição

Create this simple Java program:

import java.sql.*;

void main() throws Exception {
        try (
                Connection c = DriverManager.getConnection("jdbc:duckdb:~/duckdb.db");
                Statement s = c.createStatement();
        ) {
                s.executeUpdate("install spatial");
                s.executeUpdate("load spatial");
        }
}

Now run it like so:

java -cp duckdb_jdbc-2.0.1.0.jar Test.java

This produces the following crash output:

#
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGILL (0x4) at pc=0x00007c79efe15026, pid=136403, tid=136404
#
# JRE version: OpenJDK Runtime Environment (25.0.5.1+2) (build 25.0.5.1+2-1-26.04.1-Ubuntu)
# Java VM: OpenJDK 64-Bit Server VM (25.0.5.1+2-1-26.04.1-Ubuntu, mixed mode, sharing, tiered, compressed oops, compressed class ptrs, g1 gc, linux-amd64)
# Problematic frame:
# C  [spatial.duckdb_extension+0x1215026]  _GLOBAL__sub_I_spatial_join_optimizer.cpp+0x66
#
# Core dump will be written. Default location: Determined by the following: "/usr/share/apport/apport -p%p -s%s -c%c -d%d -P%P -u%u -g%g -F%F -- %E" (alternatively, falling back to /home/lukaseder/core.136403)
#
# An error report file with more information is saved as:
# /home/lukaseder/hs_err_pid136403.log
#
# If you would like to submit a bug report, please visit:
#   https://bugs.launchpad.net/ubuntu/+source/openjdk-25
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#
Aborted                    (core dumped) java -cp duckdb_jdbc-2.0.1.0.jar Test.java

Attached the core dump: hs_err_pid136403.log

I'm running on this Linux distribution:

lukaseder@dg-test-26:~$ lsb_release -irc
Distributor ID: Ubuntu
Release:        26.04
Codename:       resolute

This is a 2.x regression as the issue didn't appear with 1.x

Linguagem predominante
C++
Estrelas
129
Forks
90
Merge médio
5h 34min
PRs com merge (30d)
56

Preparar o ambiente

Este projeto não oferece contêiner de desenvolvimento, Dockerfile nem guia de contribuição, então a configuração fica por sua conta: comece pelo README e veja nosso guia da primeira contribuição para os passos gerais.

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de duckdb/duckdb-java

Todas as issues de duckdb/duckdb-java

Issues semelhantes

Mais issues de C++

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.