Galois
|
The Galois namespace containing all Galois structures and functions. More...
Namespaces | |
DEPRECATED | |
Deprecated Galois functions. | |
graphs | |
Parallel data graph structures in Galois. | |
gstl | |
Standard library structures that use Galois allocators. | |
ParallelSTL | |
Parallel versions of STL library algorithms. | |
runtime | |
Internal Galois functionality - Use at your own risk. | |
substrate | |
Contains threading and machine OS support. | |
worklists | |
Scheduling policies for Galois. | |
Classes | |
class | DistMemSys |
Explicit class to initialize the Galois Runtime. More... | |
class | DGAccumulator |
Distributed sum-reducer for getting the sum of some value across multiple hosts. More... | |
class | DGReduceMax |
Distributed max-reducer for getting the max of some value across multiple hosts. More... | |
class | DGReduceMin |
Distributed min-reducer for getting the min of some value across multiple hosts. More... | |
class | DGTerminator |
Distributed sum-reducer for getting the sum of some value across multiple hosts. More... | |
class | CopyableArray |
A subclass of std::array that is marked trivially copyable if the type is also memory copyable. More... | |
class | GAtomic |
An atomic wrapper that provides sensible atomic behavior for most primative data types. More... | |
class | GAtomicPadded |
Cache-line padded version of GAtomic. More... | |
class | CopyableAtomic |
Class that inherits from std::atomic to make it copyable by defining a copy constructor. More... | |
class | InsertBag |
Unordered collection of elements. More... | |
class | GChecked |
Conflict-checking wrapper for any type. More... | |
class | GChecked< void > |
struct | Pair |
Struct that contains 2 elements. More... | |
struct | TupleOfThree |
Struct that contains 3 elements. More... | |
class | DynamicBitSet |
Concurrent dynamically allocated bitset. More... | |
struct | InvalidBitsetFnTy |
A structure representing an empty bitset. More... | |
class | FixedSizeBagBase |
Unordered collection of bounded size. More... | |
class | FixedSizeRing |
Ordered collection of bounded size. More... | |
class | flat_map |
Simple map data structure, based off a single array. More... | |
class | gdeque |
Like std::deque but use Galois memory management functionality. More... | |
struct | debug |
struct | debug< 0 > |
class | gslist_base |
class | IterRange |
class | SerFIFO |
class | SerStack |
class | LargeArray |
Large array of objects with proper specialization for void type and supporting various allocation and construction policies. More... | |
class | LargeArray< void > |
Void specialization. More... | |
class | LazyArray |
This is a container that encapsulates space for a constant size array. More... | |
class | StrictObject |
Single object with specialization for void type. More... | |
struct | StrictObject< void > |
class | LazyObject |
Single (uninitialized) object with specialization for void type. More... | |
struct | LazyObject< void > |
struct | DoAll |
Helper functor class to invoke galois::do_all on provided args Can be used to choose between galois::do_all and other equivalents such as std::for_each. More... | |
struct | StdForEach |
Helper functor to invoke std::for_each with the same interface as galois::do_all. More... | |
struct | ForEach |
struct | WhileQ |
struct | NoDerefIterator |
Modify an iterator so that *it == it. More... | |
class | optional |
Galois version of boost::optional . More... | |
class | PerThreadContainer |
class | PerThreadVector |
class | PerThreadDeque |
class | PerThreadGdeque |
class | PerThreadList |
class | PerThreadMap |
class | PerThreadSet |
class | PerThreadMinHeap |
class | PODResizeableArray |
This is a container that encapsulates a resizeable array of plain-old-datatype (POD) elements. More... | |
class | ThreadSafeOrderedSet |
Thread-safe ordered set. More... | |
class | MinHeap |
class | ThreadSafeMinHeap |
Thread-safe min heap. More... | |
class | Reducible |
A Reducible stores per-thread values of a variable of type T and merges multiple values into one. More... | |
struct | gmax |
gmax is the functional form of std::max More... | |
struct | gmin |
gmax is the functional form of std::max More... | |
struct | identity_value |
struct | identity_value_zero |
struct | identity_value_min |
struct | identity_value_max |
class | GAccumulator |
Accumulator for T where accumulation is plus. More... | |
class | GReduceMax |
Accumulator for T where accumulation is max. More... | |
class | GReduceMin |
Accumulator for T where accumulation is min. More... | |
class | GReduceLogicalAnd |
logical AND reduction More... | |
class | GReduceLogicalOr |
logical OR reduction More... | |
class | SharedMemSys |
SharedMemSys is an explicit class to initialize the Galois runtime. More... | |
class | Timer |
A simple timer. More... | |
class | TimeAccumulator |
A multi-start time accumulator. More... | |
class | StatTimer |
Galois Timer that automatically reports stats upon destruction Provides statistic interface around timer. More... | |
class | CondStatTimer |
class | CondStatTimer< false > |
struct | trait_has_type |
struct | trait_has_value |
struct | trait_has_svalue |
struct | get_trait_type |
Returns the type associated with the given trait in a tuple. More... | |
struct | function_traits |
struct | function_traits< T, typename std::enable_if< has_function_traits< T >(0)>::type > |
struct | loopname_tag |
Indicate name to appear in statistics. More... | |
struct | loopname |
struct | steal_tag |
Indicate whetherlink do_all()} loops should perform work-stealing. More... | |
struct | steal |
struct | wl_tag |
Indicates worklist to use. More... | |
struct | s_wl |
struct | parallel_break_tag |
Indicates the operator may request the parallel loop to be suspended and a given function run in serial. More... | |
struct | parallel_break |
struct | no_pushes_tag |
Indicates the operator does not generate new work and push it on the worklist. More... | |
struct | no_pushes |
struct | per_iter_alloc_tag |
Indicates the operator may request the access to a per-iteration allocator. More... | |
struct | per_iter_alloc |
struct | no_stats_tag |
Indicates the operator doesn't need its execution stats recorded. More... | |
struct | no_stats |
struct | more_stats_tag |
Indicates the operator needs detailed stats Must provide loopname to enable this flag. More... | |
struct | more_stats |
struct | no_conflicts_tag |
Indicates the operator doesn't need abort support. More... | |
struct | no_conflicts |
struct | fixed_neighborhood_tag |
Indicates that the neighborhood set does not change through out i.e. More... | |
struct | fixed_neighborhood |
struct | intent_to_read_tag |
Indicates that the operator uses the intent to read flag. More... | |
struct | intent_to_read |
struct | neighborhood_visitor_tag |
Indicates the operator has a function that visits the neighborhood of the operator without modifying it. More... | |
struct | neighborhood_visitor |
struct | det_parallel_break_tag |
Indicates the operator has a function that allows a galois::for_each loop to be exited deterministically. More... | |
struct | det_parallel_break |
struct | det_id_tag |
Indicates the operator has a function that optimizes the generation of unique ids for active elements. More... | |
struct | det_id |
struct | local_state_tag |
Indicates the operator has a type that encapsulates state that is passed between the suspension and resumpsion of an operator during deterministic scheduling. More... | |
struct | local_state |
struct | op_tag |
For distributed Galois. More... | |
struct | chunk_size_tag |
struct | chunk_size |
Specify chunk size for do_all_coupled & do_all_choice at compile time or at runtime. More... | |
class | TwoLevelIterBase |
Common functionality of TwoLevelIterators. More... | |
class | TwoLevelFwdIter |
Two-Level forward iterator. More... | |
class | TwoLevelBiDirIter |
Two-Level bidirectional iterator. More... | |
class | TwoLevelRandIter |
Two-Level random access iterator. More... | |
struct | ChooseTwoLevelIterator |
Type function to select appropriate two-level iterator. More... | |
struct | ChooseStlTwoLevelIterator |
Type function to select appropriate two-level iterator. More... | |
class | TwoLevelIteratorA |
Alternate implementation of ChooseTwoLevelIterator. More... | |
struct | GetBegin |
Helper functor, returns t.end() More... | |
struct | GetEnd |
Helper functor, returns t.end() More... | |
class | UnionFindNode |
Intrusive union-find implementation. More... | |
class | UserContext |
This is the object passed to the user's parallel loop. More... | |
Typedefs | |
template<typename T , unsigned ChunkSize = 64> | |
using | FixedSizeBag = FixedSizeBagBase< T, ChunkSize, false > |
Unordered collection of bounded size. More... | |
template<typename T , unsigned ChunkSize = 64> | |
using | ConcurrentFixedSizeBag = FixedSizeBagBase< T, ChunkSize, true > |
Unordered collection of bounded size with concurrent insertion or deletion but not both simultaneously. More... | |
template<typename T , unsigned chunksize = 16> | |
using | gslist = gslist_base< T, chunksize, false > |
Singly linked list. More... | |
template<typename T , unsigned chunksize = 16> | |
using | concurrent_gslist = gslist_base< T, chunksize, true > |
Concurrent linked list. More... | |
typedef galois::runtime::BumpWithMallocHeap < galois::runtime::FreeListHeap < galois::runtime::SystemHeap > > | IterAllocBaseTy |
[PerIterAllocTy example] Base allocator for per-iteration allocator More... | |
typedef galois::runtime::ExternalHeapAllocator < char, IterAllocBaseTy > | PerIterAllocTy |
Per-iteration allocator that conforms to STL allocator interface. More... | |
template<typename Ty > | |
using | FixedSizeAllocator = galois::runtime::FixedSizeAllocator< Ty > |
[PerIterAllocTy example] More... | |
template<typename T > | |
using | Pow_2_VarSizeAlloc = typename runtime::Pow_2_BlockAllocator< T > |
Scalable variable-sized allocator for T that allocates blocks of sizes in powers of 2 Useful for small and medium sized allocations, e.g. More... | |
Enumerations | |
enum | CUSP_GRAPH_TYPE { CUSP_CSR, CUSP_CSC } |
Enum for the input/output format of the partitioner. More... | |
enum | MethodFlag : char { MethodFlag::UNPROTECTED = 0, MethodFlag::WRITE = 1, MethodFlag::READ = 2, MethodFlag::INTERNAL_MASK = 3, MethodFlag::PREVIOUS = 4 } |
What should the runtime do when executing a method. More... | |
Functions | |
template<typename PartitionPolicy , typename NodeData = char, typename EdgeData = void> | |
galois::graphs::DistGraph < NodeData, EdgeData > * | cuspPartitionGraph (std::string graphFile, CUSP_GRAPH_TYPE inputType, CUSP_GRAPH_TYPE outputType, bool symmetricGraph=false, std::string transposeGraphFile="", std::string masterBlockFile="", bool cuspAsync=true, uint32_t cuspStateRounds=100, galois::graphs::MASTERS_DISTRIBUTION readPolicy=galois::graphs::BALANCED_EDGES_OF_MASTERS, uint32_t nodeWeight=0, uint32_t edgeWeight=0) |
Main CuSP function: partitions a graph on disk, one partition per host. More... | |
template<typename Ty > | |
const Ty | atomicMax (std::atomic< Ty > &a, const Ty b) |
galois::atomicMax + non-atomic max calls More... | |
template<typename Ty > | |
const Ty | max (std::atomic< Ty > &a, const Ty &b) |
template<typename Ty > | |
const Ty | max (Ty &a, const Ty &b) |
template<typename Ty > | |
const Ty | atomicMin (std::atomic< Ty > &a, const Ty b) |
galois::atomicMin More... | |
template<typename Ty > | |
const Ty | min (std::atomic< Ty > &a, const Ty &b) |
template<typename Ty > | |
const Ty | min (Ty &a, const Ty &b) |
template<typename Ty > | |
const Ty | atomicAdd (std::atomic< Ty > &val, Ty delta) |
galois::atomicAdd More... | |
template<typename Ty > | |
const Ty | add (std::atomic< Ty > &a, const Ty &b) |
template<typename Ty > | |
const Ty | add (Ty &a, std::atomic< Ty > &b) |
template<typename Ty > | |
const Ty | add (Ty &a, const Ty &b) |
template<typename Ty > | |
const Ty | atomicSubtract (std::atomic< Ty > &val, Ty delta) |
atomic subtraction of delta (because atomicAdd with negative numbers implies a signed integer cast) More... | |
template<typename Ty > | |
const Ty | set (Ty &a, const Ty &b) |
template<typename Ty > | |
const Ty | set (std::atomic< Ty > &a, const Ty &b) |
template<typename Ty > | |
const Ty | pairWiseAvg (Ty a, Ty b) |
Pair Wise Average function. More... | |
template<typename Ty > | |
void | pairWiseAvg_vec (std::vector< Ty > &a_vec, std::vector< Ty > &b_vec) |
template<typename Ty > | |
void | resetVec (Ty &a_arr) |
template<typename Ty > | |
void | pairWiseAvg_vec (Ty &a_arr, Ty &b_arr) |
template<typename Ty > | |
void | addArray (Ty &a_arr, Ty &b_arr) |
template<typename Ty > | |
void | resetVec (std::vector< Ty > &a_vec) |
template<typename ItrTy , typename Ty > | |
Ty | innerProduct (ItrTy a_begin, ItrTy a_end, ItrTy b_begin, Ty init_value) |
template<typename ItrTy , typename Ty > | |
Ty | innerProduct (ItrTy &a_arr, ItrTy &b_arr, Ty init_value) |
template<typename Ty > | |
void | reset (Ty &var, Ty val) |
template<typename Ty > | |
void | reset (std::atomic< Ty > &var, Ty val) |
template<typename _Key , typename _Tp , typename _Compare , typename _Alloc > | |
bool | operator== (const flat_map< _Key, _Tp, _Compare, _Alloc > &__x, const flat_map< _Key, _Tp, _Compare, _Alloc > &__y) |
template<typename _Key , typename _Tp , typename _Compare , typename _Alloc > | |
bool | operator< (const flat_map< _Key, _Tp, _Compare, _Alloc > &__x, const flat_map< _Key, _Tp, _Compare, _Alloc > &__y) |
template<typename _Key , typename _Tp , typename _Compare , typename _Alloc > | |
bool | operator!= (const flat_map< _Key, _Tp, _Compare, _Alloc > &__x, const flat_map< _Key, _Tp, _Compare, _Alloc > &__y) |
Based on operator==. More... | |
template<typename _Key , typename _Tp , typename _Compare , typename _Alloc > | |
bool | operator> (const flat_map< _Key, _Tp, _Compare, _Alloc > &__x, const flat_map< _Key, _Tp, _Compare, _Alloc > &__y) |
Based on operator<. More... | |
template<typename _Key , typename _Tp , typename _Compare , typename _Alloc > | |
bool | operator<= (const flat_map< _Key, _Tp, _Compare, _Alloc > &__x, const flat_map< _Key, _Tp, _Compare, _Alloc > &__y) |
Based on operator<. More... | |
template<typename _Key , typename _Tp , typename _Compare , typename _Alloc > | |
bool | operator>= (const flat_map< _Key, _Tp, _Compare, _Alloc > &__x, const flat_map< _Key, _Tp, _Compare, _Alloc > &__y) |
Based on operator<. More... | |
template<typename RangeFunc , typename FunctionTy , typename... Args> | |
void | for_each (const RangeFunc &rangeMaker, FunctionTy &&fn, const Args &...args) |
Galois unordered set iterator. More... | |
template<typename RangeFunc , typename FunctionTy , typename... Args> | |
void | do_all (const RangeFunc &rangeMaker, FunctionTy &&fn, const Args &...args) |
Standard do-all loop. More... | |
template<typename FunctionTy , typename... Args> | |
void | on_each (FunctionTy &&fn, const Args &...args) |
Low-level parallel loop. More... | |
void | gPrintStr (const std::string &) |
Prints a string. More... | |
void | gInfoStr (const std::string &) |
Prints an info string (for easy parsing) More... | |
void | gWarnStr (const std::string &) |
Prints a warning string (for easy parsing) More... | |
void | gDebugStr (const std::string &) |
Prints a debug string (for easy parsing) More... | |
void | gErrorStr (const std::string &) |
Prints an error string (for easy parsing) More... | |
template<typename... Args> | |
void | gPrint (Args &&...args) |
Prints a sequence of things. More... | |
template<typename... Args> | |
void | gInfo (Args &&...args) |
Prints an info string from a sequence of things. More... | |
template<typename... Args> | |
void | gWarn (Args &&...args) |
Prints a warning string from a sequence of things. More... | |
template<typename... Args> | |
void | gDebug (Args &&...GALOIS_USED_ONLY_IN_DEBUG(args)) |
Prints a debug string from a sequence of things; prints nothing if NDEBUG is defined. More... | |
template<typename... Args> | |
void | gError (Args &&...args) |
Prints error message. More... | |
void | gFlush () |
template<typename I > | |
auto | makeIterRange (const I &beg, const I &end) |
template<typename C > | |
auto | makeIterRange (C &&cont) |
template<typename IterTy , class Distance > | |
IterTy | safe_advance_dispatch (IterTy b, IterTy e, Distance n, std::random_access_iterator_tag) |
template<typename IterTy , class Distance > | |
IterTy | safe_advance_dispatch (IterTy b, IterTy e, Distance n, std::input_iterator_tag) |
template<typename IterTy , class Distance > | |
IterTy | safe_advance (IterTy b, IterTy e, Distance n) |
Like std::advance but returns end if end is closer than the advance amount. More... | |
template<typename IterTy > | |
IterTy | split_range (IterTy b, IterTy e) |
Finds the midpoint of a range. More... | |
template<typename IterTy , typename std::enable_if<!std::is_integral< IterTy >::value >::type * = nullptr> | |
std::pair< IterTy, IterTy > | block_range (IterTy b, IterTy e, unsigned id, unsigned num) |
Returns a continuous block from the range based on the number of divisions and the id of the block requested. More... | |
template<typename IntTy , typename std::enable_if< std::is_integral< IntTy >::value >::type * = nullptr> | |
std::pair< IntTy, IntTy > | block_range (IntTy b, IntTy e, unsigned id, unsigned num) |
template<typename I > | |
std::enable_if_t <!std::is_scalar < internal::Val_ty< I > >::value > | uninitialized_destroy (I first, I last) |
Destroy a range. More... | |
template<class I > | |
std::enable_if_t < std::is_scalar < internal::Val_ty< I > >::value > | uninitialized_destroy (I, I) |
template<typename Iter , typename Cmp , typename NhFunc , typename OpFunc > | |
void | for_each_ordered (Iter b, Iter e, const Cmp &cmp, const NhFunc &nhFunc, const OpFunc &fn, const char *loopname=0) |
Galois ordered set iterator for stable source algorithms. More... | |
template<typename Iter , typename Cmp , typename NhFunc , typename OpFunc , typename StableTest > | |
void | for_each_ordered (Iter b, Iter e, const Cmp &cmp, const NhFunc &nhFunc, const OpFunc &fn, const StableTest &stabilityTest, const char *loopname=0) |
Galois ordered set iterator for unstable source algorithms. More... | |
MethodFlag | operator& (MethodFlag x, MethodFlag y) |
Bitwise & for method flags. More... | |
MethodFlag | operator| (MethodFlag x, MethodFlag y) |
Bitwise | for method flags. More... | |
template<typename Iterator > | |
NoDerefIterator< Iterator > | make_no_deref_iterator (Iterator it) |
Convenience function to create NoDerefIterator. More... | |
template<typename MergeFn , typename IdFn > | |
auto | make_reducible (const MergeFn &mergeFn, const IdFn &idFn) |
make_reducible creates a Reducible from a merge function and identity function. More... | |
template<typename C > | |
auto | iterate (C &cont) |
template<typename T > | |
auto | iterate (std::initializer_list< T > initList) |
template<typename I > | |
auto | iterate (const I &beg, const I &end) |
unsigned int | setActiveThreads (unsigned int num) noexcept |
Sets the number of threads to use when running any Galois iterator. More... | |
unsigned int | getActiveThreads () noexcept |
Returns the number of threads in use. More... | |
template<typename F > | |
void | timeThis (const F &f, const char *const name) |
template<template< typename...> class TT, typename... Args> | |
auto | make_trait_with_args (Args...args) -> TT< Args...> |
Utility function to simplify creating traits that take unnamed functions (i.e., lambdas). More... | |
template<typename T , typename Tuple , size_t Int, size_t... Ints> | |
constexpr size_t | find_trait (std::index_sequence< Int, Ints...>) |
Returns index of first matching trait in Tuple. More... | |
template<typename T , typename Tuple > | |
constexpr size_t | find_trait () |
template<typename T , typename... Ts> | |
constexpr bool | has_trait (std::tuple< Ts...> *) |
Returns true if the tuple type contains the given trait T. More... | |
template<typename T , typename Tuple > | |
constexpr bool | has_trait () |
template<typename T , typename Tuple > | |
constexpr auto | get_trait_value (Tuple tpl) |
Returns the value associated with the given trait T in a tuple. More... | |
template<typename S , typename T , typename D > | |
constexpr auto | get_default_trait_value (S, T, D, typename std::enable_if< has_trait< T, S >()>::type *=nullptr) |
template<typename S , typename T , typename D > | |
constexpr auto | get_default_trait_value (S GALOIS_UNUSED(source), T GALOIS_UNUSED(tags), D defaults, typename std::enable_if<!has_trait< T, S >()>::type *=nullptr) |
template<typename S , typename T , typename D > | |
constexpr auto | get_default_trait_values (std::index_sequence<> GALOIS_UNUSED(seq), S GALOIS_UNUSED(source), T GALOIS_UNUSED(tags), D GALOIS_UNUSED(defaults)) |
Returns a tuple that has an element from defaults[i] for every type from tags[i] missing in source. More... | |
template<size_t... Ints, typename S , typename T , typename D > | |
constexpr auto | get_default_trait_values (std::index_sequence< Ints...> GALOIS_UNUSED(seq), S source, T tags, D defaults) |
template<typename S , typename T , typename D > | |
constexpr auto | get_default_trait_values (S source, T tags, D defaults) |
template<typename T > | |
constexpr auto | has_function_traits (int) -> decltype(std::declval< typename T::function_traits >(), bool()) |
template<typename > | |
constexpr auto | has_function_traits (...) -> bool |
template<typename Outer , typename InnerBegFn , typename InnerEndFn > | |
ChooseTwoLevelIterator< Outer, typename InnerBegFn::result_type, InnerBegFn, InnerEndFn >::type | make_two_level_begin (Outer beg, Outer end, InnerBegFn innerBegFn, InnerEndFn innerEndFn) |
Creates two level iterator. More... | |
template<typename Outer , typename InnerBegFn , typename InnerEndFn > | |
ChooseTwoLevelIterator< Outer, typename InnerBegFn::result_type, InnerBegFn, InnerEndFn >::type | make_two_level_end (Outer beg, Outer end, InnerBegFn innerBegFn, InnerEndFn innerEndFn) |
Creates two level iterator. More... | |
template<typename Outer > | |
internal::StlInnerIsIterator < Outer >::type | stl_two_level_begin (Outer beg, Outer end) |
template<typename Outer > | |
internal::StlInnerIsIterator < Outer >::type | stl_two_level_end (Outer beg, Outer end) |
template<typename Outer > | |
internal::StlInnerIsConstIterator < Outer >::type | stl_two_level_cbegin (Outer beg, Outer end) |
template<typename Outer > | |
internal::StlInnerIsConstIterator < Outer >::type | stl_two_level_cend (Outer beg, Outer end) |
template<typename Outer > | |
internal::StlInnerIsRvrsIterator < Outer >::type | stl_two_level_rbegin (Outer beg, Outer end) |
template<typename Outer > | |
internal::StlInnerIsRvrsIterator < Outer >::type | stl_two_level_rend (Outer beg, Outer end) |
template<typename Outer > | |
internal::StlInnerIsConstRvrsIterator < Outer >::type | stl_two_level_crbegin (Outer beg, Outer end) |
template<typename Outer > | |
internal::StlInnerIsConstRvrsIterator < Outer >::type | stl_two_level_crend (Outer beg, Outer end) |
template<class CategoryOrTraversal , class OuterIter , class InnerIter , class InnerBeginFn , class InnerEndFn > | |
std::pair< TwoLevelIteratorA < OuterIter, InnerIter, CategoryOrTraversal, InnerBeginFn, InnerEndFn > , TwoLevelIteratorA< OuterIter, InnerIter, CategoryOrTraversal, InnerBeginFn, InnerEndFn > > | make_two_level_iterator (OuterIter outer_begin, OuterIter outer_end) |
std::string | getVersion () |
std::string | getRevision () |
int | getVersionMajor () |
int | getVersionMinor () |
int | getVersionPatch () |
int | getCopyrightYear () |
Variables | |
template<typename Base , typename Derived > | |
constexpr bool | at_least_base_of |
True if Derived is derived from Base or is Base itself. More... | |
typedef worklists::PerSocketChunkFIFO < chunk_size<>::value > | defaultWL |
template<typename T , typename... Args> | |
s_wl< T, Args...> | wl (Args &&...args) |
The Galois namespace containing all Galois structures and functions.
TODO: Print intra host stats with per-thread details and inter-host stats with per-host details print to 2 files if supporting R format dist implements an addToStat with host ID and manages inter-host stats and their combining.
using galois::concurrent_gslist = typedef gslist_base<T, chunksize, true> |
Concurrent linked list.
To conserve space, allocator is maintained external to the list. Iteration order is unspecified.
using galois::ConcurrentFixedSizeBag = typedef FixedSizeBagBase<T, ChunkSize, true> |
Unordered collection of bounded size with concurrent insertion or deletion but not both simultaneously.
typedef worklists::PerSocketChunkFIFO<chunk_size<>::value> galois::defaultWL |
using galois::FixedSizeAllocator = typedef galois::runtime::FixedSizeAllocator<Ty> |
[PerIterAllocTy example]
Scalable fixed-sized allocator for T that conforms to STL allocator interface but does not support variable sized allocations
using galois::FixedSizeBag = typedef FixedSizeBagBase<T, ChunkSize, false> |
Unordered collection of bounded size.
using galois::gslist = typedef gslist_base<T, chunksize, false> |
Singly linked list.
To conserve space, allocator is maintained external to the list.
typedef galois::runtime::BumpWithMallocHeap< galois::runtime::FreeListHeap<galois::runtime::SystemHeap> > galois::IterAllocBaseTy |
[PerIterAllocTy example] Base allocator for per-iteration allocator
Per-iteration allocator that conforms to STL allocator interface.
using galois::Pow_2_VarSizeAlloc = typedef typename runtime::Pow_2_BlockAllocator<T> |
Scalable variable-sized allocator for T that allocates blocks of sizes in powers of 2 Useful for small and medium sized allocations, e.g.
small or medium vectors, strings, deques
|
strong |
What should the runtime do when executing a method.
Various methods take an optional parameter indicating what actions the runtime should do on the user's behalf: (1) checking for conflicts, and/or (2) saving undo information. By default, both are performed (ALL).
Enumerator | |
---|---|
UNPROTECTED | |
WRITE | |
READ | |
INTERNAL_MASK | |
PREVIOUS |
const Ty galois::add | ( | std::atomic< Ty > & | a, |
const Ty & | b | ||
) |
const Ty galois::add | ( | Ty & | a, |
std::atomic< Ty > & | b | ||
) |
const Ty galois::add | ( | Ty & | a, |
const Ty & | b | ||
) |
void galois::addArray | ( | Ty & | a_arr, |
Ty & | b_arr | ||
) |
const Ty galois::atomicAdd | ( | std::atomic< Ty > & | val, |
Ty | delta | ||
) |
const Ty galois::atomicMax | ( | std::atomic< Ty > & | a, |
const Ty | b | ||
) |
galois::atomicMax + non-atomic max calls
const Ty galois::atomicMin | ( | std::atomic< Ty > & | a, |
const Ty | b | ||
) |
const Ty galois::atomicSubtract | ( | std::atomic< Ty > & | val, |
Ty | delta | ||
) |
atomic subtraction of delta (because atomicAdd with negative numbers implies a signed integer cast)
std::pair<IterTy, IterTy> galois::block_range | ( | IterTy | b, |
IterTy | e, | ||
unsigned | id, | ||
unsigned | num | ||
) |
Returns a continuous block from the range based on the number of divisions and the id of the block requested.
std::pair<IntTy, IntTy> galois::block_range | ( | IntTy | b, |
IntTy | e, | ||
unsigned | id, | ||
unsigned | num | ||
) |
galois::graphs::DistGraph<NodeData, EdgeData>* galois::cuspPartitionGraph | ( | std::string | graphFile, |
CUSP_GRAPH_TYPE | inputType, | ||
CUSP_GRAPH_TYPE | outputType, | ||
bool | symmetricGraph = false , |
||
std::string | transposeGraphFile = "" , |
||
std::string | masterBlockFile = "" , |
||
bool | cuspAsync = true , |
||
uint32_t | cuspStateRounds = 100 , |
||
galois::graphs::MASTERS_DISTRIBUTION | readPolicy = galois::graphs::BALANCED_EDGES_OF_MASTERS , |
||
uint32_t | nodeWeight = 0 , |
||
uint32_t | edgeWeight = 0 |
||
) |
Main CuSP function: partitions a graph on disk, one partition per host.
graphFile | Graph file to read in the Galois binary CSR format |
inputType | Specifies which input format (CSR or CSC) should be given to the partitioner |
outputType | Specifies the output format (CSR or CSC) that each partition will be created in |
symmetricGraph | This should be "true" if the passed in graphFile is a symmetric graph |
transposeGraphFile | Transpose graph of graphFile in Galois binary CSC format (i.e. give it the transpose version of graphFile). Ignore this argument if the graph is symmetric. |
masterBlockFile | |
cuspAsync | Toggles asynchronous master assignment phase during partitioning |
cuspStateRounds | Toggles number of rounds used to synchronize partitioning state during master assignment phase |
readPolicy | Determines how each host should divide the reading load of the graph on disk |
nodeWeight | When using a read policy that involves nodes and edges, this argument assigns a weight to give each node. |
edgeWeight | When using a read policy that involves nodes and edges, this argument assigns a weight to give each edge. |
PartitionPolicy | Partitioning policy object that specifies the placement of nodes/edges during partitioning. |
NodeData | Data structure to be created for each node in the graph |
EdgeData | Type of data to be stored on each edge. Currently only guarantee support for void or uint32_t; all other types may cause undefined behavior. |
void galois::do_all | ( | const RangeFunc & | rangeMaker, |
FunctionTy && | fn, | ||
const Args &... | args | ||
) |
Standard do-all loop.
All iterations should be independent. Operator should conform to fn(item)
where item is a value from the iteration range.
rangeMaker | an iterate range maker typically returned by galois::iterate(...) ( |
fn | operator |
args | optional arguments to loop |
constexpr size_t galois::find_trait | ( | std::index_sequence< Int, Ints...> | ) |
Returns index of first matching trait in Tuple.
This function is not well-defined if there is no matching trait.
constexpr size_t galois::find_trait | ( | ) |
void galois::for_each | ( | const RangeFunc & | rangeMaker, |
FunctionTy && | fn, | ||
const Args &... | args | ||
) |
Galois unordered set iterator.
Operator should conform to fn(item, UserContext<T>&)
where item is a value from the iteration range and T is the type of item.
rangeMaker | an iterate range maker typically returned by galois::iterate(...) ( |
fn | operator |
args | optional arguments to loop, e.g., { |
void galois::for_each_ordered | ( | Iter | b, |
Iter | e, | ||
const Cmp & | cmp, | ||
const NhFunc & | nhFunc, | ||
const OpFunc & | fn, | ||
const char * | loopname = 0 |
||
) |
Galois ordered set iterator for stable source algorithms.
Operator should conform to fn(item, UserContext<T>&)
where item is a value from the iteration range and T is the type of item. Comparison function should conform to bool r = cmp(item1, item2)
where r is true if item1 is less than or equal to item2. Neighborhood function should conform to nhFunc(item)
and should visit every element in the neighborhood of active element item.
b | begining of range of initial items |
e | end of range of initial items |
cmp | comparison function |
nhFunc | neighborhood function |
fn | operator |
loopname | string to identity loop in statistics output |
void galois::for_each_ordered | ( | Iter | b, |
Iter | e, | ||
const Cmp & | cmp, | ||
const NhFunc & | nhFunc, | ||
const OpFunc & | fn, | ||
const StableTest & | stabilityTest, | ||
const char * | loopname = 0 |
||
) |
Galois ordered set iterator for unstable source algorithms.
Operator should conform to fn(item, UserContext<T>&)
where item is a value from the iteration range and T is the type of item. Comparison function should conform to bool r = cmp(item1, item2)
where r is true if item1 is less than or equal to item2. Neighborhood function should conform to nhFunc(item)
and should visit every element in the neighborhood of active element item. The stability test should conform to bool r = stabilityTest(item)
where r is true if item is a stable source.
b | begining of range of initial items |
e | end of range of initial items |
cmp | comparison function |
nhFunc | neighborhood function |
fn | operator |
stabilityTest | stability test |
loopname | string to identity loop in statistics output |
void galois::gDebug | ( | Args &&... | GALOIS_USED_ONLY_IN_DEBUGargs | ) |
Prints a debug string from a sequence of things; prints nothing if NDEBUG is defined.
void galois::gDebugStr | ( | const std::string & | s | ) |
Prints a debug string (for easy parsing)
void galois::gError | ( | Args &&... | args | ) |
Prints error message.
void galois::gErrorStr | ( | const std::string & | s | ) |
Prints an error string (for easy parsing)
constexpr auto galois::get_default_trait_value | ( | S | , |
T | , | ||
D | , | ||
typename std::enable_if< has_trait< T, S >()>::type * | = nullptr |
||
) |
constexpr auto galois::get_default_trait_value | ( | S | GALOIS_UNUSEDsource, |
T | GALOIS_UNUSEDtags, | ||
D | defaults, | ||
typename std::enable_if<!has_trait< T, S >()>::type * | = nullptr |
||
) |
constexpr auto galois::get_default_trait_values | ( | std::index_sequence<> | GALOIS_UNUSEDseq, |
S | GALOIS_UNUSEDsource, | ||
T | GALOIS_UNUSEDtags, | ||
D | GALOIS_UNUSEDdefaults | ||
) |
Returns a tuple that has an element from defaults[i] for every type from tags[i] missing in source.
constexpr auto galois::get_default_trait_values | ( | std::index_sequence< Ints...> | GALOIS_UNUSEDseq, |
S | source, | ||
T | tags, | ||
D | defaults | ||
) |
constexpr auto galois::get_default_trait_values | ( | S | source, |
T | tags, | ||
D | defaults | ||
) |
constexpr auto galois::get_trait_value | ( | Tuple | tpl | ) |
Returns the value associated with the given trait T in a tuple.
This function is not well-defined when there is not matching trait.
|
noexcept |
Returns the number of threads in use.
int galois::getCopyrightYear | ( | ) |
std::string galois::getRevision | ( | ) |
std::string galois::getVersion | ( | ) |
int galois::getVersionMajor | ( | ) |
int galois::getVersionMinor | ( | ) |
int galois::getVersionPatch | ( | ) |
void galois::gFlush | ( | ) |
void galois::gInfo | ( | Args &&... | args | ) |
Prints an info string from a sequence of things.
void galois::gInfoStr | ( | const std::string & | s | ) |
Prints an info string (for easy parsing)
void galois::gPrint | ( | Args &&... | args | ) |
Prints a sequence of things.
void galois::gPrintStr | ( | const std::string & | s | ) |
Prints a string.
void galois::gWarn | ( | Args &&... | args | ) |
Prints a warning string from a sequence of things.
void galois::gWarnStr | ( | const std::string & | s | ) |
Prints a warning string (for easy parsing)
constexpr auto galois::has_function_traits | ( | int | ) | -> decltype(std::declval<typename T::function_traits>(), bool()) |
constexpr auto galois::has_function_traits | ( | ... | ) | -> bool |
constexpr bool galois::has_trait | ( | std::tuple< Ts...> * | ) |
Returns true if the tuple type contains the given trait T.
constexpr bool galois::has_trait | ( | ) |
Ty galois::innerProduct | ( | ItrTy | a_begin, |
ItrTy | a_end, | ||
ItrTy | b_begin, | ||
Ty | init_value | ||
) |
Ty galois::innerProduct | ( | ItrTy & | a_arr, |
ItrTy & | b_arr, | ||
Ty | init_value | ||
) |
auto galois::iterate | ( | C & | cont | ) |
auto galois::iterate | ( | std::initializer_list< T > | initList | ) |
auto galois::iterate | ( | const I & | beg, |
const I & | end | ||
) |
NoDerefIterator<Iterator> galois::make_no_deref_iterator | ( | Iterator | it | ) |
Convenience function to create NoDerefIterator.
auto galois::make_reducible | ( | const MergeFn & | mergeFn, |
const IdFn & | idFn | ||
) |
make_reducible creates a Reducible from a merge function and identity function.
auto galois::make_trait_with_args | ( | Args... | args | ) | -> TT<Args...> |
Utility function to simplify creating traits that take unnamed functions (i.e., lambdas).
ChooseTwoLevelIterator<Outer, typename InnerBegFn::result_type, InnerBegFn, InnerEndFn>::type galois::make_two_level_begin | ( | Outer | beg, |
Outer | end, | ||
InnerBegFn | innerBegFn, | ||
InnerEndFn | innerEndFn | ||
) |
Creates two level iterator.
ChooseTwoLevelIterator<Outer, typename InnerBegFn::result_type, InnerBegFn, InnerEndFn>::type galois::make_two_level_end | ( | Outer | beg, |
Outer | end, | ||
InnerBegFn | innerBegFn, | ||
InnerEndFn | innerEndFn | ||
) |
Creates two level iterator.
std::pair<TwoLevelIteratorA<OuterIter, InnerIter, CategoryOrTraversal, InnerBeginFn, InnerEndFn>, TwoLevelIteratorA<OuterIter, InnerIter, CategoryOrTraversal, InnerBeginFn, InnerEndFn> > galois::make_two_level_iterator | ( | OuterIter | outer_begin, |
OuterIter | outer_end | ||
) |
auto galois::makeIterRange | ( | const I & | beg, |
const I & | end | ||
) |
auto galois::makeIterRange | ( | C && | cont | ) |
const Ty galois::max | ( | std::atomic< Ty > & | a, |
const Ty & | b | ||
) |
const Ty galois::max | ( | Ty & | a, |
const Ty & | b | ||
) |
const Ty galois::min | ( | std::atomic< Ty > & | a, |
const Ty & | b | ||
) |
const Ty galois::min | ( | Ty & | a, |
const Ty & | b | ||
) |
void galois::on_each | ( | FunctionTy && | fn, |
const Args &... | args | ||
) |
Low-level parallel loop.
Operator is applied for each running thread. Operator should confirm to fn(tid, numThreads)
where tid is the id of the current thread and numThreads is the total number of running threads.
fn | operator, which is never copied |
args | optional arguments to loop |
|
inline |
Based on operator==.
|
inline |
Bitwise & for method flags.
|
inline |
|
inline |
Based on operator<.
|
inline |
|
inline |
Based on operator<.
|
inline |
Based on operator<.
|
inline |
Bitwise | for method flags.
const Ty galois::pairWiseAvg | ( | Ty | a, |
Ty | b | ||
) |
Pair Wise Average function.
void galois::pairWiseAvg_vec | ( | std::vector< Ty > & | a_vec, |
std::vector< Ty > & | b_vec | ||
) |
void galois::pairWiseAvg_vec | ( | Ty & | a_arr, |
Ty & | b_arr | ||
) |
void galois::reset | ( | Ty & | var, |
Ty | val | ||
) |
void galois::reset | ( | std::atomic< Ty > & | var, |
Ty | val | ||
) |
void galois::resetVec | ( | Ty & | a_arr | ) |
void galois::resetVec | ( | std::vector< Ty > & | a_vec | ) |
IterTy galois::safe_advance | ( | IterTy | b, |
IterTy | e, | ||
Distance | n | ||
) |
Like std::advance but returns end if end is closer than the advance amount.
IterTy galois::safe_advance_dispatch | ( | IterTy | b, |
IterTy | e, | ||
Distance | n, | ||
std::random_access_iterator_tag | |||
) |
IterTy galois::safe_advance_dispatch | ( | IterTy | b, |
IterTy | e, | ||
Distance | n, | ||
std::input_iterator_tag | |||
) |
const Ty galois::set | ( | Ty & | a, |
const Ty & | b | ||
) |
const Ty galois::set | ( | std::atomic< Ty > & | a, |
const Ty & | b | ||
) |
|
noexcept |
Sets the number of threads to use when running any Galois iterator.
Returns the actual value of threads used, which could be less than the requested value. System behavior is undefined if this function is called during parallel execution or after the first parallel execution.
IterTy galois::split_range | ( | IterTy | b, |
IterTy | e | ||
) |
Finds the midpoint of a range.
The first half is always be bigger than the second half if the range has an odd length.
internal::StlInnerIsIterator<Outer>::type galois::stl_two_level_begin | ( | Outer | beg, |
Outer | end | ||
) |
internal::StlInnerIsConstIterator<Outer>::type galois::stl_two_level_cbegin | ( | Outer | beg, |
Outer | end | ||
) |
internal::StlInnerIsConstIterator<Outer>::type galois::stl_two_level_cend | ( | Outer | beg, |
Outer | end | ||
) |
internal::StlInnerIsConstRvrsIterator<Outer>::type galois::stl_two_level_crbegin | ( | Outer | beg, |
Outer | end | ||
) |
internal::StlInnerIsConstRvrsIterator<Outer>::type galois::stl_two_level_crend | ( | Outer | beg, |
Outer | end | ||
) |
internal::StlInnerIsIterator<Outer>::type galois::stl_two_level_end | ( | Outer | beg, |
Outer | end | ||
) |
internal::StlInnerIsRvrsIterator<Outer>::type galois::stl_two_level_rbegin | ( | Outer | beg, |
Outer | end | ||
) |
internal::StlInnerIsRvrsIterator<Outer>::type galois::stl_two_level_rend | ( | Outer | beg, |
Outer | end | ||
) |
void galois::timeThis | ( | const F & | f, |
const char *const | name | ||
) |
std::enable_if_t<!std::is_scalar<internal::Val_ty<I> >::value> galois::uninitialized_destroy | ( | I | first, |
I | last | ||
) |
Destroy a range.
std::enable_if_t<std::is_scalar<internal::Val_ty<I> >::value> galois::uninitialized_destroy | ( | I | , |
I | |||
) |
s_wl<T, Args...> galois::wl | ( | Args &&... | args | ) |
constexpr bool galois::at_least_base_of |
True if Derived is derived from Base or is Base itself.
A matching trait is any type that inherits from a trait.