Task #67555 - added.err

back to task #67555
download
Error: GCC_ANALYZER_WARNING (CWE-476):
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_coefficients.c: scope_hint: In function ‘grid_transform_coef_xzy_to_ikj’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_coefficients.c:243:32: warning[-Wanalyzer-possible-null-dereference]: dereference of possibly-NULL ‘malloc((long unsigned int)(hmatgridp.size[1] * 3 * hmatgridp.size[0]) * 8)’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_private_header.h:12: included_from: Included from here.
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_utils.h:25: included_from: Included from here.
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_coefficients.h:14: included_from: Included from here.
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_coefficients.c:16: included_from: Included from here.
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_private_header.h:11: included_from: Included from here.
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_coefficients.c: scope_hint: In function ‘grid_transform_coef_xzy_to_ikj’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_coefficients.c: scope_hint: In function ‘grid_transform_coef_xzy_to_ikj’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_coefficients.c: scope_hint: In function ‘grid_transform_coef_xzy_to_ikj’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_coefficients.c:243:7: note: in expansion of macro ‘idx3’
#  241|     for (int i = 0; i < 3; i++) {
#  242|       for (int j = 0; j < 3; j++) {
#  243|->       idx3(hmatgridp, 0, j, i) = 1.0;
#  244|         for (int k = 1; k <= lp; k++) {
#  245|           idx3(hmatgridp, k, j, i) = idx3(hmatgridp, k - 1, j, i) * dh[j][i];

Error: GCC_ANALYZER_WARNING (CWE-476):
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_coefficients.c: scope_hint: In function ‘grid_transform_coef_jik_to_yxz’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_coefficients.c:334:32: warning[-Wanalyzer-possible-null-dereference]: dereference of possibly-NULL ‘malloc((long unsigned int)(hmatgridp.size[1] * 3 * hmatgridp.size[0]) * 8)’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_coefficients.c: scope_hint: In function ‘grid_transform_coef_jik_to_yxz’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_coefficients.c: scope_hint: In function ‘grid_transform_coef_jik_to_yxz’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_coefficients.c: scope_hint: In function ‘grid_transform_coef_jik_to_yxz’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_coefficients.c:334:7: note: in expansion of macro ‘idx3’
#  332|     for (int i = 0; i < 3; i++) {
#  333|       for (int j = 0; j < 3; j++) {
#  334|->       idx3(hmatgridp, 0, j, i) = 1.0;
#  335|         for (int k = 1; k <= lp; k++) {
#  336|           idx3(hmatgridp, k, j, i) = idx3(hmatgridp, k - 1, j, i) * dh[j][i];

Error: GCC_ANALYZER_WARNING (CWE-476):
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c: scope_hint: In function ‘exp_i’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c:49:10: warning[-Wanalyzer-possible-null-dereference]: dereference of possibly-NULL ‘res’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c: scope_hint: In function ‘exp_i’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.h:13: included_from: Included from here.
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c:8: included_from: Included from here.
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_tensor_local.h: scope_hint: In function ‘exp_i’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_tensor_local.h: scope_hint: In function ‘exp_i’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c: scope_hint: In function ‘exp_i’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c: scope_hint: In function ‘exp_i’
#   47|     const double c_exp_co = exp(alpha);
#   48|     /* const double c_exp_minus_1 = 1/ c_exp; */
#   49|->   res[0] = exp(imin * alpha);
#   50|     for (int i = 1; i < (imax - imin); i++) {
#   51|       res[i] = res[i - 1] *

Error: GCC_ANALYZER_WARNING (CWE-476):
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c: scope_hint: In function ‘calculate_non_orthorombic_corrections_tensor_blocked’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c:233:35: warning[-Wanalyzer-possible-null-dereference]: dereference of possibly-NULL ‘malloc((long unsigned int)max((upper_corner[2] - lower_corner[2]) * block_size[2], max((*upper_corner - *lower_corner) * *block_size, (upper_corner[1] - lower_corner[1]) * block_size[1])) * 8)’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_tensor_local.h: scope_hint: In function ‘calculate_non_orthorombic_corrections_tensor_blocked’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_tensor_local.h: scope_hint: In function ‘calculate_non_orthorombic_corrections_tensor_blocked’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c: scope_hint: In function ‘calculate_non_orthorombic_corrections_tensor_blocked’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c: scope_hint: In function ‘calculate_non_orthorombic_corrections_tensor_blocked’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c: scope_hint: In function ‘calculate_non_orthorombic_corrections_tensor_blocked’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c:232:37: note: in expansion of macro ‘idx2’
#  231|             for (int y2 = 0; y2 < block_size[d1]; y2++) {
#  232|               double *restrict dst = &idx2(exp_blocked, y2, 0);
#  233|->             const double scal = x1[y_1 + y2] * c_exp_const;
#  234|               double *restrict src = &x2[x_1];
#  235|               // #pragma omp simd linear(dst, src) simdlen(8)

Error: GCC_ANALYZER_WARNING (CWE-476):
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c:238:35: warning[-Wanalyzer-possible-null-dereference]: dereference of possibly-NULL ‘malloc((long unsigned int)max((upper_corner[2] - lower_corner[2]) * block_size[2], max((*upper_corner - *lower_corner) * *block_size, (upper_corner[1] - lower_corner[1]) * block_size[1])) * 8)’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_tensor_local.h: scope_hint: In function ‘calculate_non_orthorombic_corrections_tensor_blocked’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_tensor_local.h: scope_hint: In function ‘calculate_non_orthorombic_corrections_tensor_blocked’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c: scope_hint: In function ‘calculate_non_orthorombic_corrections_tensor_blocked’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c: scope_hint: In function ‘calculate_non_orthorombic_corrections_tensor_blocked’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c: scope_hint: In function ‘calculate_non_orthorombic_corrections_tensor_blocked’
cp2k-0.0.0/src/grid/dgemm/grid_dgemm_non_orthorombic_corrections.c:232:37: note: in expansion of macro ‘idx2’
#  236|               GRID_PRAGMA_SIMD((dst, src), 8)
#  237|               for (int x3 = 0; x3 < block_size[d2]; x3++) {
#  238|->               dst[x3] = scal * src[x3];
#  239|               }
#  240|             }