1 //------------------------------------------------------------------------------
2 // GB_dense_subassign_22_template: C += b where C is dense and b is a scalar
3 //------------------------------------------------------------------------------
4 
5 // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
6 // SPDX-License-Identifier: Apache-2.0
7 
8 //------------------------------------------------------------------------------
9 
10 {
11 
12     //--------------------------------------------------------------------------
13     // get C
14     //--------------------------------------------------------------------------
15 
16     GB_CTYPE *restrict Cx = (GB_CTYPE *) C->x ;
17     const int64_t cnz = GB_NNZ (C) ;
18 
19     //--------------------------------------------------------------------------
20     // C += b where C is dense and b is a scalar
21     //--------------------------------------------------------------------------
22 
23     int64_t pC ;
24     #pragma omp parallel for num_threads(nthreads) schedule(static)
25     for (pC = 0 ; pC < cnz ; pC++)
26     {
27         GB_BINOP (GB_CX (pC), GB_CX (pC), bwork, 0, 0) ;
28     }
29 }
30 
31