mirror of
https://github.com/amd/blis.git
synced 2026-04-19 23:28:52 +00:00
Fixed few Coverity warnings in aocl gemm addon
Fixed few Coverity warnings in aocl gemm addon AMD-Internal: CPUPL-6913
This commit is contained in:
@@ -445,7 +445,6 @@ LPGEMM_5LOOP_AVX512BF16(bfloat16,bfloat16,float,bf16bf16f32of32)
|
||||
{
|
||||
c_use_jc = c + jc;
|
||||
}
|
||||
// Temp accumulaton buffer for C allocation.
|
||||
else if ( c_downscale < F32 )
|
||||
{
|
||||
// Buffer memory is only required if output needs to be
|
||||
@@ -466,6 +465,11 @@ LPGEMM_5LOOP_AVX512BF16(bfloat16,bfloat16,float,bf16bf16f32of32)
|
||||
temp_scal_c_buffer_bf16 = bli_mem_buffer( &mem_scale_c );
|
||||
|
||||
c_use_jc = ( float* )temp_scal_c_buffer_bf16;
|
||||
}else
|
||||
{
|
||||
// When k <= KC, output is written directly as there is no need of
|
||||
// intermediate buffer to store the output
|
||||
c_use_jc = c + jc;
|
||||
}
|
||||
|
||||
// The temp c buffer stride is modified as opposed to original C matrix.
|
||||
@@ -1257,6 +1261,11 @@ LPGEMM_5LOOP_AVX2(bfloat16,bfloat16,float,bf16bf16f32of32)
|
||||
temp_scal_c_buffer_bf16 = bli_mem_buffer( &mem_scale_c );
|
||||
|
||||
c_use_jc = ( float* )temp_scal_c_buffer_bf16;
|
||||
}else
|
||||
{
|
||||
// When k <= KC, output is written directly as there is no need of
|
||||
// intermediate buffer to store the output
|
||||
c_use_jc = c + jc;
|
||||
}
|
||||
|
||||
// The temp c buffer stride is modified as opposed to original C matrix.
|
||||
|
||||
@@ -182,12 +182,12 @@ LPGEMM_TINY(bfloat16,bfloat16,float,bf16bf16f32of32)
|
||||
|
||||
dim_t NR = lcntx->blksz.NR;
|
||||
|
||||
const int16_t* a_use = NULL;
|
||||
const int16_t* a_use = a;
|
||||
dim_t cs_a_use = cs_a;
|
||||
dim_t rs_a_use = rs_a;
|
||||
dim_t a_block_stride = 0;
|
||||
|
||||
const int16_t* b_use = NULL;
|
||||
const int16_t* b_use = b;
|
||||
dim_t rs_b_use = rs_b;
|
||||
dim_t cs_b_use = cs_b;
|
||||
|
||||
|
||||
@@ -510,6 +510,11 @@ LPGEMM_5LOOP(int8_t,int8_t,int32_t,s8s8s32o32)
|
||||
temp_scal_c_buffer_s8s8s32o32 = bli_mem_buffer( &mem_scale_c );
|
||||
|
||||
c_use_jc = ( int32_t* )temp_scal_c_buffer_s8s8s32o32;
|
||||
}else
|
||||
{
|
||||
// When k <= KC, output is written directly as there is no need of
|
||||
// intermediate buffer to store the output
|
||||
c_use_jc = c + jc;
|
||||
}
|
||||
|
||||
// The temp c buffer stride is modified as opposed to original C matrix.
|
||||
|
||||
@@ -469,6 +469,12 @@ LPGEMM_5LOOP(uint8_t,int8_t,int32_t,u8s8s32o32)
|
||||
|
||||
c_use_jc = ( int32_t* )temp_scal_c_buffer_u8s8s32o32;
|
||||
}
|
||||
else
|
||||
{
|
||||
// When k <= KC, output is written directly as there is no need of
|
||||
// intermediate buffer to store the output
|
||||
c_use_jc = c + jc;
|
||||
}
|
||||
|
||||
// The temp c buffer stride is modified as opposed to original C matrix.
|
||||
rs_c_use = nc0;
|
||||
|
||||
Reference in New Issue
Block a user