﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
13933	[Patch] Simplify QuadBuckets and improve memory footprint	GerdP	team	"I've noticed that the spatial index requires quite a lot of memory when loading large files (say more than 1.000.000 nodes). 

The patch includes these changes:
1) Let `QBLevel` extend BBox and reduce the bytes needed used for some fields, 
don't store a reference of QuadBuckts in `QBLevel`
2) Allow up to 48 primitives in one `QBLevel` instance.

Effects: (all numbers for 64 Bit System)
1) the memory footprint of a single `QBLevel` instance is reduced: 
- The unpatched version allocates a BBox instance (48 bytes) and requires 97 for the fields 
- The patched version requires 107 Bytes for the fields and no additional BBox instance.
In both cases the structures have a few ""unused"" bytes because JRE uses multiples of 8 (or 16?) Bytes for alignment.
2) Fewer `QBLevel` instances 
Numbers:
For an older extract of Bremen.osm.pbf (2016-03-26) I see ~521 MiB for r11123 and ~489 MiB for the patched version (~6 % more for the unpatched version),
for alaska (4.360.697 nodes) I see ~12 % more, so, the larger the file the higher the improvement.
I did not find any significant change in runtime.

"	enhancement	closed	normal	16.12	Core		fixed	performance	
