|
Aleph-w 7.10.0
A C++ Library for Data Structures and Algorithms
|
The memory that the fallback of howard_minimum_mean_cycle() to Karp's algorithm reserves, measured on the allocations themselves (audit 2026-10-02, stage C). More...
#include <Howard_Min_Mean_Cycle.H>#include <gtest/gtest.h>#include <cstdio>#include <cstdlib>#include <new>#include <random>#include <tuple>#include <vector>#include <tpl_graph.H>#include "negative_cycles_test_support.H"Go to the source code of this file.
Macros | |
| #define | PROBE_ALLOCATIONS 1 |
| #define | PROBE_NOINLINE |
Functions | |
| void * | operator new (const std::size_t size) |
| void * | operator new[] (const std::size_t size) |
| void * | operator new (const std::size_t size, const std::nothrow_t &) noexcept |
| void * | operator new[] (const std::size_t size, const std::nothrow_t &) noexcept |
| void | operator delete (void *p) noexcept |
| void | operator delete[] (void *p) noexcept |
| void | operator delete (void *p, std::size_t) noexcept |
| void | operator delete[] (void *p, std::size_t) noexcept |
| void | operator delete (void *p, const std::nothrow_t &) noexcept |
| void | operator delete[] (void *p, const std::nothrow_t &) noexcept |
| TEST (HowardFallbackMemoryTest, TheLimitCountsTheTablesKarpReserves) | |
| TEST (HowardFallbackMemoryTest, SumsBeyondLongLongTakeSixteenBytesAndTheLimitKnows) | |
| TEST (HowardFallbackMemoryTest, NodesOutsideTheCyclesCostTheFallbackNothing) | |
The memory that the fallback of howard_minimum_mean_cycle() to Karp's algorithm reserves, measured on the allocations themselves (audit 2026-10-02, stage C).
This program replaces the global allocation functions: while the probe is active they record the two largest requests. The replacement stays out of the other test programs. A sanitizer that brings its own allocator defines those functions in its runtime (ThreadSanitizer and MemorySanitizer link them into the program, so a second definition does not link): under one, the replacement is left out and the tests are skipped.
Definition in file howard_fallback_memory_test.cc.
| #define PROBE_ALLOCATIONS 1 |
Definition at line 75 of file howard_fallback_memory_test.cc.
| #define PROBE_NOINLINE |
Definition at line 111 of file howard_fallback_memory_test.cc.
|
noexcept |
Definition at line 152 of file howard_fallback_memory_test.cc.
|
noexcept |
Definition at line 156 of file howard_fallback_memory_test.cc.
|
noexcept |
Definition at line 154 of file howard_fallback_memory_test.cc.
|
noexcept |
Definition at line 153 of file howard_fallback_memory_test.cc.
|
noexcept |
Definition at line 157 of file howard_fallback_memory_test.cc.
|
noexcept |
Definition at line 155 of file howard_fallback_memory_test.cc.
| void * operator new | ( | const std::size_t | size | ) |
Definition at line 135 of file howard_fallback_memory_test.cc.
References Negative_Cycles_Test_Support::build_graph(), and Aleph::size().
|
noexcept |
Definition at line 144 of file howard_fallback_memory_test.cc.
References Negative_Cycles_Test_Support::build_graph(), and Aleph::size().
| void * operator new[] | ( | const std::size_t | size | ) |
Definition at line 143 of file howard_fallback_memory_test.cc.
References Aleph::size().
|
noexcept |
Definition at line 148 of file howard_fallback_memory_test.cc.
References Negative_Cycles_Test_Support::build_graph(), and Aleph::size().
| TEST | ( | HowardFallbackMemoryTest | , |
| NodesOutsideTheCyclesCostTheFallbackNothing | |||
| ) |
Definition at line 300 of file howard_fallback_memory_test.cc.
References Negative_Cycles_Test_Support::build_graph(), Aleph::howard_minimum_mean_cycle(), nodes, PROBE_ALLOCATIONS, and r.
| TEST | ( | HowardFallbackMemoryTest | , |
| SumsBeyondLongLongTakeSixteenBytesAndTheLimitKnows | |||
| ) |
Definition at line 263 of file howard_fallback_memory_test.cc.
References Negative_Cycles_Test_Support::build_graph(), m, PROBE_ALLOCATIONS, r, rng, and Aleph::Howard_Mean_Cycle_Result< GT, Cost_Type >::used_karp.
| TEST | ( | HowardFallbackMemoryTest | , |
| TheLimitCountsTheTablesKarpReserves | |||
| ) |
Definition at line 219 of file howard_fallback_memory_test.cc.
References Negative_Cycles_Test_Support::build_graph(), PROBE_ALLOCATIONS, r, and rng.