rusqlite benchmark crashes on m1 mac
jussisaurio opened this issue · comments
Related issue in pprof-rs: tikv/pprof-rs#237
jussisaurio@Jussis-MacBook-Air limbo % cargo bench --bench benchmark -- --profile-time=5
Gnuplot not found, using plotters backend
Benchmarking limbo/Prepare statement: 'SELECT 1': Complete (Analysis Disabled)
Benchmarking limbo/Prepare statement: 'SELECT * FROM users LIMIT 1': Complete (Analysis Disabled)
Benchmarking limbo/Execute prepared statement: 'SELECT 1': Complete (Analysis Disabled)
Benchmarking limbo/Execute prepared statement: 'SELECT * FROM users LIMIT 1': Complete (Analysis Disabled)
Benchmarking limbo/Execute prepared statement: 'SELECT * FROM users LIMIT 100': Complete (Analysis Disabled)
Benchmarking rusqlite/Prepare statement: 'SELECT 1': Profiling for 5.0000 serror: bench failed, to rerun pass `-p limbo_core --bench benchmark`
Caused by:
process didn't exit successfully: `/Users/jussisaurio/projects/extra-worktrees/limbo/target/release/deps/benchmark-7cd163bb09d96570 --profile-time=5 --bench` (signal: 5, SIGTRAP: trace/breakpoint trap)
with lldb (i don't know how to interpret this tbh):
jussisaurio@Jussis-MacBook-Air target % lldb /Users/jussisaurio/projects/extra-worktrees/limbo/target/release/deps/benchmark-7cd163bb09d96570
(lldb) target create "/Users/jussisaurio/projects/extra-worktrees/limbo/target/release/deps/benchmark-7cd163bb09d96570"
Current executable set to '/Users/jussisaurio/projects/extra-worktrees/limbo/target/release/deps/benchmark-7cd163bb09d96570' (arm64).
(lldb) run --profile-time=5 --bench
Process 49484 launched: '/Users/jussisaurio/projects/extra-worktrees/limbo/target/release/deps/benchmark-7cd163bb09d96570' (arm64)
Gnuplot not found, using plotters backend
Benchmarking limbo/Prepare statement: 'SELECT 1': Complete (Analysis Disabled)
Benchmarking limbo/Prepare statement: 'SELECT * FROM users LIMIT 1': Complete (Analysis Disabled)
Benchmarking limbo/Execute prepared statement: 'SELECT 1': Complete (Analysis Disabled)
Benchmarking limbo/Execute prepared statement: 'SELECT * FROM users LIMIT 1': Complete (Analysis Disabled)
Benchmarking limbo/Execute prepared statement: 'SELECT * FROM users LIMIT 100': Complete (Analysis Disabled)
Benchmarking rusqlite/Prepare statement: 'SELECT 1': Profiling for 5.0000 sProcess 49484 stopped
* thread #1, name = 'main', queue = 'com.apple.main-thread', stop reason = EXC_BREAKPOINT (code=1, subcode=0x1918abd50)
frame #0: 0x00000001918abd50 libunwind.dylib`libunwind::UnwindCursor<libunwind::LocalAddressSpace, libunwind::Registers_arm64>::step(bool) + 812
libunwind.dylib`libunwind::UnwindCursor<libunwind::LocalAddressSpace, libunwind::Registers_arm64>::step:
-> 0x1918abd50 <+812>: brk #0xc471
0x1918abd54 <+816>: pacib x16, x9
0x1918abd58 <+820>: str x16, [x19, #0x110]
0x1918abd5c <+824>: ldr x16, [x19]
Target 0: (benchmark-7cd163bb09d96570) stopped.
(lldb) bt
* thread #1, name = 'main', queue = 'com.apple.main-thread', stop reason = EXC_BREAKPOINT (code=1, subcode=0x1918abd50)
* frame #0: 0x00000001918abd50 libunwind.dylib`libunwind::UnwindCursor<libunwind::LocalAddressSpace, libunwind::Registers_arm64>::step(bool) + 812
frame #1: 0x00000001918aeeac libunwind.dylib`_Unwind_Backtrace + 352
frame #2: 0x0000000100051a94 benchmark-7cd163bb09d96570`perf_signal_handler + 344
frame #3: 0x0000000185081a24 libsystem_platform.dylib`_sigtramp + 56
frame #4: 0x000000018bd05dbc libsqlite3.dylib`sqlite3RunParser + 1032
frame #5: 0x000000018bd05dbc libsqlite3.dylib`sqlite3RunParser + 1032
frame #6: 0x000000018bd053ac libsqlite3.dylib`sqlite3Prepare + 804
frame #7: 0x000000018bd04ef8 libsqlite3.dylib`sqlite3LockAndPrepare + 224
frame #8: 0x0000000100048da8 benchmark-7cd163bb09d96570`rusqlite::inner_connection::InnerConnection::prepare::h5779a83445386e09 + 120
frame #9: 0x000000010003b440 benchmark-7cd163bb09d96570`criterion::bencher::Bencher$LT$M$GT$::iter::h0362b640109d7dcd + 132
frame #10: 0x00000001000018cc benchmark-7cd163bb09d96570`_$LT$criterion..routine..Function$LT$M$C$F$C$T$GT$$u20$as$u20$criterion..routine..Routine$LT$M$C$T$GT$$GT$::warm_up::h2467c2d15b3dee23 + 268
frame #11: 0x0000000100009a68 benchmark-7cd163bb09d96570`criterion::routine::Routine::profile::h7270ae8519cd4890 + 408
frame #12: 0x0000000100033a0c benchmark-7cd163bb09d96570`criterion::benchmark_group::BenchmarkGroup$LT$M$GT$::bench_function::h3b4bfa662d432650 + 1116
frame #13: 0x0000000100047804 benchmark-7cd163bb09d96570`benchmark::main::h1f6a9c3593920630 + 1064
frame #14: 0x0000000100036970 benchmark-7cd163bb09d96570`std::sys_common::backtrace::__rust_begin_short_backtrace::hcfc9249e4d9327b5 + 12
frame #15: 0x0000000100038d64 benchmark-7cd163bb09d96570`std::rt::lang_start::_$u7b$$u7b$closure$u7d$$u7d$::h57504c6d8848a36c + 16
frame #16: 0x00000001002eb2b8 benchmark-7cd163bb09d96570`std::rt::lang_start_internal::hecc68fef83c8f44d + 640
frame #17: 0x0000000100048070 benchmark-7cd163bb09d96570`main + 52
frame #18: 0x0000000184cd10e0 dyld`start + 236