[Git][debian-gis-team/spatialindex][experimental] 6 commits: New upstream version 2.0.0~b2
Bas Couwenberg (@sebastic)
gitlab at salsa.debian.org
Tue May 28 20:21:22 BST 2024
Bas Couwenberg pushed to branch experimental at Debian GIS Project / spatialindex
Commits:
0a9a8d3a by Bas Couwenberg at 2024-05-28T21:04:21+02:00
New upstream version 2.0.0~b2
- - - - -
e883bf6e by Bas Couwenberg at 2024-05-28T21:04:23+02:00
Update upstream source from tag 'upstream/2.0.0_b2'
Update to upstream version '2.0.0~b2'
with Debian dir 87d13da056dfea929bae253a01aaacff8aafe330
- - - - -
8baf85a0 by Bas Couwenberg at 2024-05-28T21:05:14+02:00
New upstream beta release.
- - - - -
4a201f12 by Bas Couwenberg at 2024-05-28T21:06:39+02:00
Update symbols for other architectures.
- - - - -
6fa194dc by Bas Couwenberg at 2024-05-28T21:16:55+02:00
Update symbols for amd64.
- - - - -
30859ffc by Bas Couwenberg at 2024-05-28T21:16:55+02:00
Set distribution to experimental.
- - - - -
17 changed files:
- CMakeLists.txt
- debian/changelog
- debian/libspatialindex-c7.symbols
- debian/libspatialindex7.symbols
- src/CMakeLists.txt
- src/mvrtree/Index.cc
- src/mvrtree/MVRTree.cc
- src/mvrtree/PointerPoolNode.h
- src/rtree/BulkLoader.cc
- src/rtree/PointerPoolNode.h
- src/rtree/RTree.cc
- src/spatialindex/MovingRegion.cc
- src/spatialindex/Region.cc
- src/tprtree/Index.cc
- src/tprtree/Node.cc
- src/tprtree/PointerPoolNode.h
- src/tprtree/TPRTree.cc
Changes:
=====================================
CMakeLists.txt
=====================================
@@ -16,6 +16,7 @@ project(spatialindex
HOMEPAGE_URL "https://github.com/libspatialindex/libspatialindex"
)
+
set(SIDX_VERSION_MAJOR "${PROJECT_VERSION_MAJOR}")
set(SIDX_VERSION_MINOR "${PROJECT_VERSION_MINOR}")
set(SIDX_VERSION_PATCH "${PROJECT_VERSION_PATCH}")
@@ -26,6 +27,14 @@ set(SIDX_LIB_SOVERSION "7")
include(GNUInstallDirs)
+
+IF(NOT CMAKE_BUILD_TYPE)
+ SET(CMAKE_BUILD_TYPE Release CACHE STRING
+ "Choose the type of build, options are: None Debug Release RelWithDebInfo MinSizeRel"
+ FORCE)
+ENDIF()
+
+
message(STATUS
"Configuring CMake ${CMAKE_VERSION} to build spatialindex ${PROJECT_VERSION}")
=====================================
debian/changelog
=====================================
@@ -1,3 +1,10 @@
+spatialindex (2.0.0~b2-1~exp1) experimental; urgency=medium
+
+ * New upstream beta release.
+ * Update symbols for other architectures.
+
+ -- Bas Couwenberg <sebastic at debian.org> Tue, 28 May 2024 21:08:14 +0200
+
spatialindex (2.0.0~b1-1~exp1) experimental; urgency=medium
* New upstream beta release.
=====================================
debian/libspatialindex-c7.symbols
=====================================
@@ -1,4 +1,4 @@
-# SymbolsHelper-Confirmed: 2.0.0~a1 amd64 arm64 armel armhf hppa hurd-i386 i386 loong64 m68k mips64el powerpc ppc64 ppc64el riscv64 s390x sh4 sparc64 x32
+# SymbolsHelper-Confirmed: 2.0.0~b2 amd64
libspatialindex_c.so.7 #PACKAGE# #MINVER#
* Build-Depends-Package: libspatialindex-dev
Error_GetErrorCount at Base 1.8.1
@@ -237,8 +237,8 @@ libspatialindex_c.so.7 #PACKAGE# #MINVER#
(optional=templinst)_ZNSt6vectorI15LeafQueryResultSaIS0_EE17_M_realloc_insertIJS0_EEEvN9__gnu_cxx17__normal_iteratorIPS0_S2_EEDpOT_ at Base 1.9.0
(optional=templinst)_ZNSt6vectorIPN12SpatialIndex5IDataESaIS2_EE17_M_realloc_insertIJRKS2_EEEvN9__gnu_cxx17__normal_iteratorIPS2_S4_EEDpOT_ at Base 1.9.0
(optional=templinst|arch=amd64 arm64 loong64 mips64el ppc64 ppc64el riscv64 s390x sparc64)_ZNSt6vectorIlSaIlEE17_M_default_appendEm at Base 1.9.0
- (optional=templinst)_ZNSt6vectorIlSaIlEED1Ev at Base 2.0.0~a1
- (optional=templinst)_ZNSt6vectorIlSaIlEED2Ev at Base 2.0.0~a1
+ (optional=templinst)_ZNSt6vectorIlSaIlEED1Ev at Base 2.0.0~b2
+ (optional=templinst)_ZNSt6vectorIlSaIlEED2Ev at Base 2.0.0~b2
(optional=templinst|arch=amd64 arm64 loong64 mips64el ppc64 ppc64el riscv64 s390x sparc64)_ZNSt6vectorImSaImEE17_M_realloc_insertIJmEEEvN9__gnu_cxx17__normal_iteratorIPmS1_EEDpOT_ at Base 1.9.0
(optional=templinst|arch=!amd64 !arm64 !ia64 !kfreebsd-amd64 !loong64 !mips64el !ppc64 !ppc64el !riscv64 !s390x !sparc64)_ZNSt6vectorIxSaIxEE17_M_default_appendEj at Base 1.9.0
(optional=templinst|arch=armel armhf hppa hurd-i386 i386 m68k powerpc sh4 x32)_ZNSt6vectorIxSaIxEED1Ev at Base 2.0.0~a1
=====================================
debian/libspatialindex7.symbols
=====================================
@@ -1,4 +1,4 @@
-# SymbolsHelper-Confirmed: 2.0.0~a1 amd64 arm64 armel armhf hppa hurd-i386 i386 loong64 m68k mips64el powerpc ppc64 ppc64el riscv64 s390x sh4 sparc64 x32
+# SymbolsHelper-Confirmed: 2.0.0~b2 amd64
libspatialindex.so.7 #PACKAGE# #MINVER#
* Build-Depends-Package: libspatialindex-dev
Error_GetErrorCount at Base 1.9.0
@@ -1450,8 +1450,8 @@ libspatialindex.so.7 #PACKAGE# #MINVER#
(optional=templinst)_ZNSt6vectorIjSaIjEED2Ev at Base 2.0.0~a1
(optional=templinst|arch=amd64 arm64 ia64 loong64 mips64el ppc64 ppc64el riscv64 s390x sparc64)_ZNSt6vectorIlSaIlEE17_M_default_appendEm at Base 1.9.0
(optional=templinst|arch=amd64 arm64 ia64 loong64 mips64el ppc64 ppc64el riscv64 s390x sparc64)_ZNSt6vectorIlSaIlEE17_M_realloc_insertIJRKlEEEvN9__gnu_cxx17__normal_iteratorIPlS1_EEDpOT_ at Base 1.9.0
- (optional=templinst)_ZNSt6vectorIlSaIlEED1Ev at Base 2.0.0~a1
- (optional=templinst)_ZNSt6vectorIlSaIlEED2Ev at Base 2.0.0~a1
+ (optional=templinst)_ZNSt6vectorIlSaIlEED1Ev at Base 2.0.0~b2
+ (optional=templinst)_ZNSt6vectorIlSaIlEED2Ev at Base 2.0.0~b2
(optional=templinst|arch=amd64 arm64 ia64 loong64 mips64el ppc64 ppc64el riscv64 s390x sparc64)_ZNSt6vectorImSaImEE17_M_realloc_insertIJmEEEvN9__gnu_cxx17__normal_iteratorIPmS1_EEDpOT_ at Base 1.9.0
(optional=templinst|arch=!amd64 !arm64 !ia64 !kfreebsd-amd64 !loong64 !mips64el !ppc64 !ppc64el !riscv64 !s390x !sparc64)_ZNSt6vectorIxSaIxEE17_M_default_appendEj at Base 1.9.0
(optional=templinst|arch=!amd64 !arm64 !ia64 !kfreebsd-amd64 !loong64 !mips64el !ppc64 !ppc64el !riscv64 !s390x !sparc64)_ZNSt6vectorIxSaIxEE17_M_realloc_insertIJRKxEEEvN9__gnu_cxx17__normal_iteratorIPxS1_EEDpOT_ at Base 1.9.0
@@ -1459,9 +1459,6 @@ libspatialindex.so.7 #PACKAGE# #MINVER#
(optional=templinst|arch=armel armhf hppa hurd-i386 i386 m68k powerpc sh4 x32)_ZNSt6vectorIxSaIxEED2Ev at Base 2.0.0~a1
(optional=templinst|arch=!amd64 !arm64 !ia64 !kfreebsd-amd64 !loong64 !mips64el !ppc64 !ppc64el !riscv64 !s390x !sparc64)_ZNSt6vectorIySaIyEE17_M_realloc_insertIJyEEEvN9__gnu_cxx17__normal_iteratorIPyS1_EEDpOT_ at Base 1.9.0
(optional=templinst|subst)_ZNSt6vectorI{int64_t}SaI{int64_t}EE17_M_realloc_insertIJ{int64_t}EEEvN9__gnu_cxx17__normal_iteratorIP{int64_t}S1_EEDpOT_ at Base 1.9.3
- (optional=templinst)_ZNSt7__cxx1115basic_stringbufIcSt11char_traitsIcESaIcEED0Ev at Base 1.9.0
- (optional=templinst)_ZNSt7__cxx1115basic_stringbufIcSt11char_traitsIcESaIcEED1Ev at Base 1.9.0
- (optional=templinst)_ZNSt7__cxx1115basic_stringbufIcSt11char_traitsIcESaIcEED2Ev at Base 1.9.0
(optional=templinst)_ZNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_N5Tools7VariantEESt10_Select1stISA_ESt4lessIS5_ESaISA_EE17_M_emplace_uniqueIJS6_IS5_S9_EEEES6_ISt17_Rb_tree_iteratorISA_EbEDpOT_ at Base 1.9.0
(optional=templinst)_ZNSt8_Rb_treeIjSt4pairIKjjESt10_Select1stIS2_ESt4lessIjESaIS2_EE17_M_emplace_uniqueIJS0_IjjEEEES0_ISt17_Rb_tree_iteratorIS2_EbEDpOT_ at Base 1.9.0
(optional=templinst|arch=sparc)_ZNSt8_Rb_treeIjSt4pairIKjjESt10_Select1stIS2_ESt4lessIjESaIS2_EE17_M_insert_unique_ESt23_Rb_tree_const_iteratorIS2_ERKS2_ at Base 1.8.1
=====================================
src/CMakeLists.txt
=====================================
@@ -201,12 +201,22 @@ target_compile_options(spatialindex
target_compile_options(spatialindex_c
PRIVATE ${SIDX_COMMON_CXX_FLAGS})
-set_target_properties( spatialindex PROPERTIES
- RUNTIME_OUTPUT_DIRECTORY
+target_compile_definitions(spatialindex
+ PRIVATE
+ $<$<CONFIG:Debug>:SIDX_DEBUG>
+)
+
+target_compile_definitions(spatialindex_c
+ PRIVATE
+ $<$<CONFIG:Debug>:SIDX_DEBUG>
+)
+
+set_target_properties( spatialindex PROPERTIES
+ RUNTIME_OUTPUT_DIRECTORY
${CMAKE_BINARY_DIR}/bin)
-set_target_properties( spatialindex_c PROPERTIES
- RUNTIME_OUTPUT_DIRECTORY
+set_target_properties( spatialindex_c PROPERTIES
+ RUNTIME_OUTPUT_DIRECTORY
${CMAKE_BINARY_DIR}/bin)
=====================================
src/mvrtree/Index.cc
=====================================
@@ -5,7 +5,7 @@
* Copyright (c) 2002, Marios Hadjieleftheriou
*
* All rights reserved.
- *
+ *
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
@@ -180,7 +180,7 @@ uint32_t Index::findLeastEnlargement(const TimeRegion& r) const
}
}
-#ifndef NDEBUG
+#ifdef SIDX_DEBUG
if (best == std::numeric_limits<uint32_t>::max())
{
std::ostringstream s;
@@ -237,7 +237,7 @@ uint32_t Index::findLeastOverlap(const TimeRegion& r) const
++cLiveEntries;
}
-#ifndef NDEBUG
+#ifdef SIDX_DEBUG
if (cLiveEntries == 0)
{
std::ostringstream s;
=====================================
src/mvrtree/MVRTree.cc
=====================================
@@ -1337,7 +1337,7 @@ std::ostream& SpatialIndex::MVRTree::operator<<(std::ostream& os, const MVRTree&
os << t.m_stats;
os << t.printRootInfo();
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
os << "Leaf pool hits: " << t.m_leafPool.m_hits << std::endl
<< "Leaf pool misses: " << t.m_leafPool.m_misses << std::endl
<< "Index pool hits: " << t.m_indexPool.m_hits << std::endl
=====================================
src/mvrtree/PointerPoolNode.h
=====================================
@@ -5,7 +5,7 @@
* Copyright (c) 2002, Marios Hadjieleftheriou
*
* All rights reserved.
- *
+ *
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
@@ -36,7 +36,7 @@ namespace Tools
public:
explicit PointerPool(uint32_t capacity) : m_capacity(capacity)
{
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
m_hits = 0;
m_misses = 0;
m_pointerCount = 0;
@@ -50,13 +50,13 @@ namespace Tools
while (! m_pool.empty())
{
SpatialIndex::MVRTree::Node* x = m_pool.top(); m_pool.pop();
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
--m_pointerCount;
#endif
delete x;
}
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
std::cerr << "Lost pointers: " << m_pointerCount << std::endl;
#endif
}
@@ -66,13 +66,13 @@ namespace Tools
if (! m_pool.empty())
{
SpatialIndex::MVRTree::Node* p = m_pool.top(); m_pool.pop();
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
++m_hits;
#endif
return PoolPointer<SpatialIndex::MVRTree::Node>(p, this);
}
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
else
{
// fixme: well sort of...
@@ -107,7 +107,7 @@ namespace Tools
}
else
{
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
--m_pointerCount;
#endif
delete p;
@@ -128,7 +128,7 @@ namespace Tools
uint32_t m_capacity;
std::stack<SpatialIndex::MVRTree::Node*> m_pool;
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
public:
uint64_t m_hits;
uint64_t m_misses;
=====================================
src/rtree/BulkLoader.cc
=====================================
@@ -333,7 +333,7 @@ void BulkLoader::bulkLoadUsingSTR(
NodePtr n = pTree->readNode(pTree->m_rootID);
pTree->deleteNode(n.get());
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
std::cerr << "RTree::BulkLoader: Sorting data." << std::endl;
#endif
@@ -360,7 +360,7 @@ void BulkLoader::bulkLoadUsingSTR(
while (true)
{
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
std::cerr << "RTree::BulkLoader: Building level " << level << std::endl;
#endif
=====================================
src/rtree/PointerPoolNode.h
=====================================
@@ -5,7 +5,7 @@
* Copyright (c) 2002, Marios Hadjieleftheriou
*
* All rights reserved.
- *
+ *
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
@@ -38,7 +38,7 @@ namespace Tools
public:
explicit PointerPool(uint32_t capacity) : m_capacity(capacity)
{
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
m_hits = 0;
m_misses = 0;
m_pointerCount = 0;
@@ -52,13 +52,13 @@ namespace Tools
while (! m_pool.empty())
{
RTree::Node* x = m_pool.top(); m_pool.pop();
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
--m_pointerCount;
#endif
delete x;
}
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
std::cerr << "Lost pointers: " << m_pointerCount << std::endl;
#endif
}
@@ -68,13 +68,13 @@ namespace Tools
if (! m_pool.empty())
{
RTree::Node* p = m_pool.top(); m_pool.pop();
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
++m_hits;
#endif
return PoolPointer<RTree::Node>(p, this);
}
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
else
{
// fixme: well sort of...
@@ -112,7 +112,7 @@ namespace Tools
}
else
{
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
--m_pointerCount;
#endif
delete p;
@@ -133,7 +133,7 @@ namespace Tools
uint32_t m_capacity;
std::stack<RTree::Node*> m_pool;
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
public:
uint64_t m_hits;
uint64_t m_misses;
=====================================
src/rtree/RTree.cc
=====================================
@@ -1334,7 +1334,7 @@ SpatialIndex::id_type SpatialIndex::RTree::RTree::writeNode(Node* n)
n->m_identifier = page;
++(m_stats.m_u32Nodes);
-#ifndef NDEBUG
+#ifdef SIDX_DEBUG
try
{
m_stats.m_nodesInLevel[n->m_level] = m_stats.m_nodesInLevel.at(n->m_level) + 1;
@@ -1563,7 +1563,7 @@ std::ostream& SpatialIndex::RTree::operator<<(std::ostream& os, const RTree& t)
os << "Utilization: " << 100 * t.m_stats.getNumberOfData() / (t.m_stats.getNumberOfNodesInLevel(0) * t.m_leafCapacity) << "%" << std::endl
<< t.m_stats;
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
os << "Leaf pool hits: " << t.m_leafPool.m_hits << std::endl
<< "Leaf pool misses: " << t.m_leafPool.m_misses << std::endl
<< "Index pool hits: " << t.m_indexPool.m_hits << std::endl
=====================================
src/spatialindex/MovingRegion.cc
=====================================
@@ -183,7 +183,7 @@ void MovingRegion::initialize(
if (m_endTime <= m_startTime) throw Tools::IllegalArgumentException("MovingRegion: Cannot support degenerate time intervals.");
-#ifndef NDEBUG
+#ifdef SIDX_DEBUG
for (uint32_t cDim = 0; cDim < m_dimension; ++cDim)
{
if (pLow[cDim] > pHigh[cDim]) throw Tools::IllegalArgumentException("MovingRegion: Low point has larger coordinates than High point.");
@@ -982,14 +982,14 @@ double MovingRegion::getIntersectingAreaInTime(const IInterval& ivI, const Movin
// add up the total area of the intersecting pieces.
double area = 0.0;
-#ifndef NDEBUG
+#ifdef SIDX_DEBUG
double _t = -std::numeric_limits<double>::max();
#endif
while (! pq.empty())
{
c = pq.top(); pq.pop();
-#ifndef NDEBUG
+#ifdef SIDX_DEBUG
assert(_t <= c.m_t);
_t = c.m_t;
#endif
=====================================
src/spatialindex/Region.cc
=====================================
@@ -5,7 +5,7 @@
* Copyright (c) 2004, Marios Hadjieleftheriou
*
* All rights reserved.
- *
+ *
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
@@ -61,7 +61,7 @@ void Region::initialize(const double* pLow, const double* pHigh, uint32_t dimens
m_pLow = nullptr;
m_dimension = dimension;
-#ifndef NDEBUG
+#ifdef SIDX_DEBUG
for (uint32_t cDim = 0; cDim < m_dimension; ++cDim)
{
if ((pLow[cDim] > pHigh[cDim]))
@@ -295,7 +295,7 @@ bool Region::touchesRegion(const Region& r) const
throw Tools::IllegalArgumentException(
"Region::touchesRegion: Regions have different number of dimensions."
);
-
+
for (uint32_t i = 0; i < m_dimension; ++i)
{
if (
@@ -361,11 +361,11 @@ bool Region::intersectsLineSegment(const LineSegment& in) const
// Points/LineSegment for the segment
Point p1 = Point(in.m_pStartPoint, 2);
Point p2 = Point(in.m_pEndPoint, 2);
-
+
//Check whether either or both the endpoints are within the region OR
//whether any of the bounding segments of the Region intersect the segment
- return (containsPoint(p1) || containsPoint(p2) ||
+ return (containsPoint(p1) || containsPoint(p2) ||
in.intersectsShape(LineSegment(ll, ul)) || in.intersectsShape(LineSegment(ul, ur)) ||
in.intersectsShape(LineSegment(ur, lr)) || in.intersectsShape(LineSegment(lr, ll)));
=====================================
src/tprtree/Index.cc
=====================================
@@ -5,7 +5,7 @@
* Copyright (c) 2002, Marios Hadjieleftheriou
*
* All rights reserved.
- *
+ *
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
@@ -321,7 +321,7 @@ void Index::adjustTree(Node* n, std::stack<id_type>& pathBuffer)
}
//}
-#ifndef NDEBUG
+#ifdef SIDX_DEBUG
for (uint32_t cChild = 0; cChild < m_children; ++cChild)
{
assert(m_nodeMBR.containsRegionAfterTime(m_pTree->m_currentTime, *(m_ptrMBR[cChild])) == true);
@@ -382,7 +382,7 @@ void Index::adjustTree(Node* n1, Node* n2, std::stack<id_type>& pathBuffer, uint
}
//}
-#ifndef NDEBUG
+#ifdef SIDX_DEBUG
for (uint32_t cChild = 0; cChild < m_children; ++cChild)
{
assert(m_nodeMBR.containsRegionAfterTime(m_pTree->m_currentTime, *(m_ptrMBR[cChild])) == true);
=====================================
src/tprtree/Node.cc
=====================================
@@ -5,7 +5,7 @@
* Copyright (c) 2002, Marios Hadjieleftheriou
*
* All rights reserved.
- *
+ *
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
@@ -376,7 +376,7 @@ bool Node::insertEntry(uint32_t dataLength, uint8_t* pData, MovingRegion& mbr, i
}
}
-#ifndef NDEBUG
+#ifdef SIDX_DEBUG
for (uint32_t cChild = 0; cChild < m_children; ++cChild)
{
assert(m_nodeMBR.containsRegionAfterTime(m_nodeMBR.m_startTime, *(m_ptrMBR[cChild])));
@@ -434,7 +434,7 @@ void Node::deleteEntry(uint32_t index)
m_nodeMBR.m_pHigh[cDim] += 2.0 * std::numeric_limits<double>::epsilon();
}
-#ifndef NDEBUG
+#ifdef SIDX_DEBUG
for (uint32_t cChild = 0; cChild < m_children; ++cChild)
{
assert(m_nodeMBR.containsRegionAfterTime(m_pTree->m_currentTime, *(m_ptrMBR[cChild])) == true);
@@ -460,9 +460,9 @@ bool Node::insertData(uint32_t dataLength, uint8_t* pData, MovingRegion& mbr, id
return bNeedToAdjust;
}
- else if (false &&
- m_pTree->m_treeVariant == TPRV_RSTAR &&
- !pathBuffer.empty() &&
+ else if (false &&
+ m_pTree->m_treeVariant == TPRV_RSTAR &&
+ !pathBuffer.empty() &&
overflowTable[m_level] == 0)
{
overflowTable[m_level] = 1;
@@ -559,7 +559,7 @@ bool Node::insertData(uint32_t dataLength, uint8_t* pData, MovingRegion& mbr, id
m_nodeMBR.m_pHigh[cDim] += 2.0 * std::numeric_limits<double>::epsilon();
}
-#ifndef NDEBUG
+#ifdef SIDX_DEBUG
for (uint32_t cChild = 0; cChild < m_children; ++cChild)
{
assert(m_nodeMBR.containsRegionAfterTime(m_nodeMBR.m_startTime, *(m_ptrMBR[cChild])));
@@ -604,7 +604,7 @@ bool Node::insertData(uint32_t dataLength, uint8_t* pData, MovingRegion& mbr, id
n->m_identifier = -1;
nn->m_identifier = -1;
-#ifndef NDEBUG
+#ifdef SIDX_DEBUG
for (uint32_t cChild = 0; cChild < n->m_children; ++cChild)
{
assert(n->m_nodeMBR.containsRegionAfterTime(n->m_nodeMBR.m_startTime, *(n->m_ptrMBR[cChild])) == true);
@@ -647,7 +647,7 @@ bool Node::insertData(uint32_t dataLength, uint8_t* pData, MovingRegion& mbr, id
n->m_identifier = m_identifier;
nn->m_identifier = -1;
-#ifndef NDEBUG
+#ifdef SIDX_DEBUG
for (uint32_t cChild = 0; cChild < n->m_children; ++cChild)
{
assert(n->m_nodeMBR.containsRegionAfterTime(n->m_nodeMBR.m_startTime, *(n->m_ptrMBR[cChild])) == true);
=====================================
src/tprtree/PointerPoolNode.h
=====================================
@@ -5,7 +5,7 @@
* Copyright (c) 2002, Marios Hadjieleftheriou
*
* All rights reserved.
- *
+ *
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
@@ -37,7 +37,7 @@ namespace Tools
public:
explicit PointerPool(uint32_t capacity) : m_capacity(capacity)
{
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
m_hits = 0;
m_misses = 0;
m_pointerCount = 0;
@@ -51,13 +51,13 @@ namespace Tools
while (! m_pool.empty())
{
TPRTree::Node* x = m_pool.top(); m_pool.pop();
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
--m_pointerCount;
#endif
delete x;
}
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
std::cerr << "Lost pointers: " << m_pointerCount << std::endl;
#endif
}
@@ -67,13 +67,13 @@ namespace Tools
if (! m_pool.empty())
{
TPRTree::Node* p = m_pool.top(); m_pool.pop();
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
++m_hits;
#endif
return PoolPointer<TPRTree::Node>(p, this);
}
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
else
{
// fixme: well sort of...
@@ -108,7 +108,7 @@ namespace Tools
}
else
{
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
--m_pointerCount;
#endif
delete p;
@@ -129,7 +129,7 @@ namespace Tools
uint32_t m_capacity;
std::stack<TPRTree::Node*> m_pool;
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
public:
uint64_t m_hits;
uint64_t m_misses;
=====================================
src/tprtree/TPRTree.cc
=====================================
@@ -1098,7 +1098,7 @@ SpatialIndex::id_type SpatialIndex::TPRTree::TPRTree::writeNode(Node* n)
n->m_identifier = page;
++(m_stats.m_nodes);
-#ifndef NDEBUG
+#ifdef SIDX_DEBUG
try
{
m_stats.m_nodesInLevel[n->m_level] = m_stats.m_nodesInLevel.at(n->m_level) + 1;
@@ -1264,7 +1264,7 @@ std::ostream& SpatialIndex::TPRTree::operator<<(std::ostream& os, const TPRTree&
os << "Utilization: " << 100 * t.m_stats.getNumberOfData() / (t.m_stats.getNumberOfNodesInLevel(0) * t.m_leafCapacity) << "%" << std::endl
<< t.m_stats;
- #ifndef NDEBUG
+ #ifdef SIDX_DEBUG
os << "Leaf pool hits: " << t.m_leafPool.m_hits << std::endl
<< "Leaf pool misses: " << t.m_leafPool.m_misses << std::endl
<< "Index pool hits: " << t.m_indexPool.m_hits << std::endl
View it on GitLab: https://salsa.debian.org/debian-gis-team/spatialindex/-/compare/26363d6d42f8e28e6ca87b74f9c3a56d06b3d8a1...30859ffc6940a5b49d88999f2d92577ccc73c20d
--
This project does not include diff previews in email notifications.
View it on GitLab: https://salsa.debian.org/debian-gis-team/spatialindex/-/compare/26363d6d42f8e28e6ca87b74f9c3a56d06b3d8a1...30859ffc6940a5b49d88999f2d92577ccc73c20d
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-grass-devel/attachments/20240528/1479d43a/attachment-0001.htm>
More information about the Pkg-grass-devel
mailing list