|
|
|||
File indexing completed on 2025-12-17 09:37:10
0001 // Copyright 2017 The Abseil Authors. 0002 // 0003 // Licensed under the Apache License, Version 2.0 (the "License"); 0004 // you may not use this file except in compliance with the License. 0005 // You may obtain a copy of the License at 0006 // 0007 // https://www.apache.org/licenses/LICENSE-2.0 0008 // 0009 // Unless required by applicable law or agreed to in writing, software 0010 // distributed under the License is distributed on an "AS IS" BASIS, 0011 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 0012 // See the License for the specific language governing permissions and 0013 // limitations under the License. 0014 0015 #ifndef ABSL_RANDOM_INTERNAL_RANDEN_HWAES_H_ 0016 #define ABSL_RANDOM_INTERNAL_RANDEN_HWAES_H_ 0017 0018 #include "absl/base/config.h" 0019 0020 // HERMETIC NOTE: The randen_hwaes target must not introduce duplicate 0021 // symbols from arbitrary system and other headers, since it may be built 0022 // with different flags from other targets, using different levels of 0023 // optimization, potentially introducing ODR violations. 0024 0025 namespace absl { 0026 ABSL_NAMESPACE_BEGIN 0027 namespace random_internal { 0028 0029 // RANDen = RANDom generator or beetroots in Swiss High German. 0030 // 'Strong' (well-distributed, unpredictable, backtracking-resistant) random 0031 // generator, faster in some benchmarks than std::mt19937_64 and pcg64_c32. 0032 // 0033 // RandenHwAes implements the basic state manipulation methods. 0034 class RandenHwAes { 0035 public: 0036 static void Generate(const void* keys, void* state_void); 0037 static void Absorb(const void* seed_void, void* state_void); 0038 static const void* GetKeys(); 0039 }; 0040 0041 // HasRandenHwAesImplementation returns true when there is an accelerated 0042 // implementation, and false otherwise. If there is no implementation, 0043 // then attempting to use it will abort the program. 0044 bool HasRandenHwAesImplementation(); 0045 0046 } // namespace random_internal 0047 ABSL_NAMESPACE_END 0048 } // namespace absl 0049 0050 #endif // ABSL_RANDOM_INTERNAL_RANDEN_HWAES_H_
| [ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
|
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
|