File tree 4 files changed +25
-15
lines changed
4 files changed +25
-15
lines changed Original file line number Diff line number Diff line change @@ -23,11 +23,11 @@ def select(condition, *tags):
23
23
24
24
def is_detail (x ):
25
25
if x .text is not None :
26
- if "detail" in x .text :
26
+ if "detail" in x .text . lower () :
27
27
return True
28
28
m = re .match (r"(?:typename)? *([A-Za-z0-9_\:]+)" , x .text )
29
29
if m is not None :
30
- s = m .group (1 )
30
+ s = m .group (1 ). lower ()
31
31
if s .startswith ("detail" ) or s .endswith ("_impl" ):
32
32
x .text = s
33
33
return True
@@ -103,6 +103,12 @@ def item_sorter(elem):
103
103
else :
104
104
log ("removing unnamed template parameter from" , parent .tag , name )
105
105
106
+ # hide macros with detail in the name
107
+ for item in select (lambda x : "DETAIL" in x .get ("name" ).split ("_" ), "macro" ):
108
+ parent = parent_map [item ]
109
+ parent .remove (item )
110
+ log ("removing macro" , item .get ("name" ))
111
+
106
112
# replace any type with "detail" in its name with "unspecified"
107
113
for item in select (is_detail , "type" ):
108
114
log ("replacing" , '"%s"' % item .text , 'with "unspecified"' )
Original file line number Diff line number Diff line change @@ -57,7 +57,11 @@ constexpr auto operator-(bitset<B1>, bitset<B2>) {
57
57
@tparam Pos position of the bit in the set.
58
58
*/
59
59
template <unsigned Pos>
60
+ #ifndef BOOST_HISTOGRAM_DOXYGEN_INVOKED
60
61
using bit = bitset<(1 << Pos)>;
62
+ #else
63
+ struct bit ;
64
+ #endif
61
65
62
66
// / All options off.
63
67
using none_t = bitset<0 >;
Original file line number Diff line number Diff line change @@ -208,16 +208,16 @@ struct get_options;
208
208
an axis type and represents compile-time boolean which is true or false, depending on
209
209
whether the axis is inclusive or not.
210
210
211
+ An inclusive axis has a bin for every possible input value. In other words, all
212
+ possible input values always end up in a valid cell and there is no need to keep track
213
+ of input tuples that need to be discarded. A histogram which consists entirely of
214
+ inclusive axes can be filled more efficiently, which can be a factor 2 faster.
215
+
211
216
An axis with underflow and overflow bins is always inclusive, but an axis may be
212
217
inclusive under other conditions. The meta-function checks for the method `constexpr
213
218
static bool inclusive()`, and uses the result. If this method is not present, it uses
214
219
get_options<Axis> and checks whether the underflow and overflow bits are present.
215
220
216
- An inclusive axis has a bin for every possible input value. A histogram which consists
217
- only of inclusive axes can be filled more efficiently, since input values always
218
- end up in a valid cell and there is no need to keep track of input tuples that need to
219
- be discarded.
220
-
221
221
@tparam Axis axis type
222
222
*/
223
223
template <class Axis >
Original file line number Diff line number Diff line change @@ -150,14 +150,14 @@ class BOOST_ATTRIBUTE_NODISCARD histogram;
150
150
151
151
namespace detail {
152
152
153
- /* Most of the histogram code is generic and works for any number of axes. Buffers with a
154
- * fixed maximum capacity are used in some places, which have a size equal to the rank of
155
- * a histogram. The buffers are statically allocated to improve performance , which means
156
- * that they need a preset maximum capacity. 32 seems like a safe upper limit for the rank
157
- * (you can nevertheless increase it here if necessary): the simplest non-trivial axis has
158
- * 2 bins; even if counters are used which need only a byte of storage per bin, 32 axes
159
- * would generate of 4 GB .
160
- */
153
+ /*
154
+ Most of the histogram code is generic and works for any number of axes. Buffers with a
155
+ fixed maximum capacity are used in some places , which have a size equal to the rank of
156
+ a histogram. The buffers are allocated from the stack to improve performance, which
157
+ means in C++ that they need a preset maximum capacity. 32 seems like a safe upper limit
158
+ for the rank. You can nevertheless increase it with the compile-time flag
159
+ BOOST_HISTOGRAM_DETAIL_AXES_LIMIT, if necessary .
160
+ */
161
161
#ifndef BOOST_HISTOGRAM_DETAIL_AXES_LIMIT
162
162
#define BOOST_HISTOGRAM_DETAIL_AXES_LIMIT 32
163
163
#endif
You can’t perform that action at this time.
0 commit comments