lidavidm commented on PR #1808:
URL: https://github.com/apache/arrow-adbc/pull/1808#issuecomment-2092362135

   @zeroshade could you help figure out the ASAN error? Reducing 
SqlPrepareUpdateStream to this first part still seems to trigger it, so to me 
it seems like a GC issue again:
   
   ```
   void StatementTest::TestSqlPrepareUpdateStream() {
     if (!quirks()->supports_bulk_ingest(ADBC_INGEST_OPTION_MODE_CREATE) ||
         !quirks()->supports_dynamic_parameter_binding()) {
       GTEST_SKIP();
     }
   
     ASSERT_THAT(AdbcStatementNew(&connection, &statement, &error), 
IsOkStatus(&error));
     ASSERT_THAT(quirks()->DropTable(&connection, "bulk_ingest", &error),
                 IsOkStatus(&error));
     struct ArrowError na_error;
   
     const std::vector<SchemaField> fields = {{"ints", NANOARROW_TYPE_INT64}};
   
     // Create table
     {
       Handle<struct ArrowSchema> schema;
       Handle<struct ArrowArray> array;
   
       ASSERT_THAT(AdbcStatementSetOption(&statement, 
ADBC_INGEST_OPTION_TARGET_TABLE,
                                          "bulk_ingest", &error),
                   IsOkStatus(&error));
       ASSERT_THAT(MakeSchema(&schema.value, fields), IsOkErrno());
       ASSERT_THAT((MakeBatch<int64_t>(&schema.value, &array.value, &na_error, 
{})),
                   IsOkErrno(&na_error));
       ASSERT_THAT(AdbcStatementBind(&statement, &array.value, &schema.value, 
&error),
                   IsOkStatus(&error));
       ASSERT_THAT(AdbcStatementExecuteQuery(&statement, nullptr, nullptr, 
&error),
                   IsOkStatus(&error));
     }
   ```
   
   ```
   Direct leak of 160 byte(s) in 2 object(s) allocated from:
       #0 0x7f50bac9561c in __interceptor_malloc 
../../../../libsanitizer/asan/asan_malloc_linux.cpp:69
       #1 0x7f50b95c1339 in get_arr 
/home/lidavidm/go/pkg/mod/github.com/apache/arrow/go/[email protected]/arrow/cdata/cdata.go:31
       #2 0x7f50b95c14d3 in _cgo_1f0435ccdf41_Cfunc_get_arr 
/tmp/go-build/cgo-gcc-prolog:144
       #3 0x7f50b7bb64e4 in runtime.asmcgocall 
/usr/lib/go-1.21/src/runtime/asm_amd64.s:872
   
   Indirect leak of 584 byte(s) in 4 object(s) allocated from:
       #0 0x7f50bac9561c in __interceptor_malloc 
../../../../libsanitizer/asan/asan_malloc_linux.cpp:69
       #1 0x55763b631bab in PrivateArrowMalloc 
/home/lidavidm/Code/arrow-adbc/c/vendor/nanoarrow/nanoarrow.c:186
   
   Indirect leak of 33 byte(s) in 2 object(s) allocated from:
       #0 0x7f50bac94df6 in __interceptor_realloc 
../../../../libsanitizer/asan/asan_malloc_linux.cpp:85
       #1 0x55763b631bba in PrivateArrowRealloc 
/home/lidavidm/Code/arrow-adbc/c/vendor/nanoarrow/nanoarrow.c:188
   
   SUMMARY: AddressSanitizer: 777 byte(s) leaked in 8 allocation(s).
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to