google / gemmlowp

Low-precision matrix multiplication
Apache License 2.0
1.77k stars 450 forks source link

eight_bit_int_gemm get all zero output and segment fault #160

Closed lcxywfe closed 5 years ago

lcxywfe commented 5 years ago

I a rookie at gemmlowp, and I used the EightBitIntGemm as:

EightBitIntGemm(
            false, false, false,
            m, n, k,
            aptr, 0, Atrd,
            bptr, 0, Btrd,
            cptr, 0.f, Ctrd,
            BitDepthSetting::A8B8);

but i got all zero output and segment fault, is EightBitIntGemm a async function? But I did not find any sync function.

lcxywfe commented 5 years ago

I see. the transpose means if RowMajor or ColMajor, and the offsetA/B is the real offset, but the offsetC is the scale

lcxywfe commented 5 years ago

I think there should be some doc in eight_bit_int_gemm.h

bjacob commented 5 years ago

eight_bit_int_gemm.h is deprecated, a remnant from gemmlowp's earliest days. Use gemmlowp/public.h instead. Inside it, use GemmWithOutputPipeline(). See https://github.com/google/gemmlowp/blob/master/doc/quantization_example.cc

lcxywfe commented 5 years ago

Got it, thx!