* thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGABRT frame #0: 0x00007fff8e52cdd6 libsystem_kernel.dylib`__pthread_kill + 10libsystem_kernel.dylib`__pthread_kill:-> 0x7fff8e52cdd6 <+10>: jae 0x7fff8e52cde0 ; <+20> 0x7fff8e52cdd8 <+12>: movq %rax, %rdi 0x7fff8e52cddb <+15>: jmp 0x7fff8e525cdf ; cerror_nocancel 0x7fff8e52cde0 <+20>: retq(lldb) bt* thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGABRT * frame #0: 0x00007fff8e52cdd6 libsystem_kernel.dylib`__pthread_kill + 10 frame #1: 0x00007fff8e618787 libsystem_pthread.dylib`pthread_kill + 90 frame #2: 0x00007fff8e492420 libsystem_c.dylib`abort + 129 frame #3: 0x00007fff8e58203f libsystem_malloc.dylib`free + 530 frame #4: 0x00000001000545b2 test_thinnet2`gemmlowp::DefaultKernel<(gemmlowp::KernelFamily)1, gemmlowp::BitDepthParams<gemmlowp::OperandRange<0, 255>, gemmlowp::OperandRange<0, 255> > >::~DefaultKernel(this=0x000000000003c27c) at kernel_default.h:49
--
You received this message because you are subscribed to the Google Groups "gemmlowp" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gemmlowp+unsubscribe@googlegroups.com.
To post to this group, send email to gemm...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gemmlowp/86bc4e20-40c3-403b-abaa-e1aee9ad9d8c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
#include <tuple>#include <iostream>#include <string>#include <vector>#include <random>
#include "gemmlowp/public/gemmlowp.h"
template <bool TransposeA, bool TransposeB, bool TransposeC>void GemmlowpMultiply(const uint8_t* a_data, const uint8_t* b_data, int32_t* c_data, int m, int n, int k, int offset_a, int offset_b, int lda, int ldb, int ldc) { static const gemmlowp::MapOrder ResultOrder = !TransposeC ? gemmlowp::MapOrder::RowMajor : gemmlowp::MapOrder::ColMajor; static const gemmlowp::MapOrder LhsOrder = !TransposeA ? gemmlowp::MapOrder::RowMajor : gemmlowp::MapOrder::ColMajor; static const gemmlowp::MapOrder RhsOrder = !TransposeB ? gemmlowp::MapOrder::RowMajor : gemmlowp::MapOrder::ColMajor; gemmlowp::MatrixMap<const std::uint8_t, LhsOrder> lhs(a_data, m, k, lda); gemmlowp::MatrixMap<const std::uint8_t, RhsOrder> rhs(b_data, k, n, ldb); gemmlowp::MatrixMap<std::int32_t, ResultOrder> result(c_data, m, n, ldc); const std::tuple<> empty_pipeline = {};
gemmlowp::GemmContext context; gemmlowp::GemmWithOutputPipeline<std::uint8_t, std::int32_t, gemmlowp::DefaultL8R8BitDepthParams>( &context, lhs, rhs, &result, -offset_a, -offset_b, empty_pipeline);}
std::mt19937& RandomEngine() { static std::mt19937 engine; return engine;}
int Random_u8() { std::uniform_int_distribution<int> dist(0, 255); return dist(RandomEngine());}
int main(int argc, char** argv) { std::vector<uint8_t> A(2217546, 0); std::vector<uint8_t> B(72, 0); std::vector<int32_t> C(1971152, 0);
for(auto& v : A) { v = Random_u8(); }
for(auto& v : B) { v = Random_u8(); }
const int offset_input = 0; const int offset_filter = 131; // const bool transpose_a = false; // const bool transpose_b = true; // const bool transpose_c = false; const int m = 246394; const int n = 8; const int k = 9; const int lda = 9; const int ldb = 9; const int ldc = 8;
GemmlowpMultiply<false, true, false>(A.data(), B.data(), C.data(), m, n, k, offset_input, offset_filter, lda, ldb, ldc);
return 0;}
Apple LLVM version 8.0.0 (clang-800.0.42.1)
Target: x86_64-apple-darwin16.4.0
Thread model: posix
I also tried with assertions enabled, and with -fsanitize=address, no issue.
It also runs fine on Linux, including a no-optimization build in Valgrid, so I am really quite confident that there is no memory error (such as an incorrect or double free, as suggested by your error message).
I tried the current gemmlowp master branch (ef9b6cb575f7574b44235bd2bd0a4f7db1f484e3). Which changeset are you at?To view this discussion on the web visit https://groups.google.com/d/msgid/gemmlowp/ec0fb9ba-785f-4826-88f7-502621c9883f%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gemmlowp/3b74af45-81be-4161-a33c-9d78ddeb35fa%40googlegroups.com.