1 /*
3 BLIS
4 An object-based framework for developing high-performance BLAS-like
5 libraries.
7 Copyright (C) 2014, The University of Texas at Austin
9 Redistribution and use in source and binary forms, with or without
10 modification, are permitted provided that the following conditions are
11 met:
12 - Redistributions of source code must retain the above copyright
13 notice, this list of conditions and the following disclaimer.
14 - Redistributions in binary form must reproduce the above copyright
15 notice, this list of conditions and the following disclaimer in the
16 documentation and/or other materials provided with the distribution.
17 - Neither the name of The University of Texas at Austin nor the names
18 of its contributors may be used to endorse or promote products
19 derived from this software without specific prior written permission.
21 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
23 LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
24 A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
25 HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
26 SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
27 LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
28 DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
29 THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
30 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
31 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
33 */
36 blksz_t* bli_blksz_obj_create( dim_t b_s, dim_t be_s,
37 dim_t b_d, dim_t be_d,
38 dim_t b_c, dim_t be_c,
39 dim_t b_z, dim_t be_z );
41 void bli_blksz_obj_init( blksz_t* b,
42 dim_t b_s, dim_t be_s,
43 dim_t b_d, dim_t be_d,
44 dim_t b_c, dim_t be_c,
45 dim_t b_z, dim_t be_z );
47 void bli_blksz_obj_attach_to( blksz_t* br,
48 blksz_t* bc );
50 void bli_blksz_obj_free( blksz_t* b );
52 dim_t bli_blksz_for_type( num_t dt,
53 blksz_t* b );
55 dim_t bli_blksz_max_for_type( num_t dt,
56 blksz_t* b );
58 dim_t bli_blksz_total_for_type( num_t dt,
59 blksz_t* b );
61 dim_t bli_blksz_for_obj( obj_t* obj,
62 blksz_t* b );
64 dim_t bli_blksz_max_for_obj( obj_t* obj,
65 blksz_t* b );
67 dim_t bli_blksz_total_for_obj( obj_t* obj,
68 blksz_t* b );
70 blksz_t* bli_blksz_sub( blksz_t* b );
72 dim_t bli_determine_blocksize_f( dim_t i,
73 dim_t dim,
74 obj_t* obj,
75 blksz_t* bsize );
76 dim_t bli_determine_blocksize_f_sub( dim_t i,
77 dim_t dim,
78 dim_t b_alg,
79 dim_t b_max );
81 dim_t bli_determine_blocksize_b( dim_t i,
82 dim_t dim,
83 obj_t* obj,
84 blksz_t* bsize );
85 dim_t bli_determine_blocksize_b_sub( dim_t i,
86 dim_t dim,
87 dim_t b_alg,
88 dim_t b_max );
90 dim_t bli_determine_reg_blocksize( obj_t* obj,
91 blksz_t* bsize );