Commit Graph

28 Commits

Author SHA1 Message Date
10d5c141f2 alloc: rationalise the 'arena' allocator 2018-12-19 17:16:57 +11:00
043dd73677 pointer: rename align as align_up, and add align_down 2018-12-17 14:45:54 +11:00
bc03b36ffc alloc/raw/linear: explain why begin/end members aren't const 2018-09-22 12:40:13 +10:00
2e0b51baa4 alloc/raw/linear: enable move operators 2018-09-21 17:00:56 +10:00
b60aaccf6f build; fix compilation errors under win32
win32 builds are still totally unsupported, untested, and functionally
broken.
2018-08-13 14:52:40 +10:00
f6056153e3 rename root namespace from util to cruft
This places, at long last, the core library code into the same namespace
as the extended library code.
2018-08-05 14:42:02 +10:00
803acc9a87 relicense under MPL-2.0 2018-08-04 15:14:06 +10:00
7d315c8095 allow/raw/linear: add typed offset query 2018-05-18 16:51:42 +10:00
38e1a19e37 alloc: all allocators should take a type for alloc/dealloc 2018-05-10 13:53:06 +10:00
2620e2ed33 alloc: return views rather than raw pointers 2018-05-10 12:54:45 +10:00
497d3ca970 build: update for gcc-8.1 warnings 2018-05-03 18:32:08 +10:00
e7b12e7792 alloc/raw/linear: add offset overload for views 2018-04-20 15:08:06 +10:00
09b9c1dc8b alloc/raw/linear: don't align by default 2018-04-20 15:08:06 +10:00
b23c274742 alloc/foreign: don't use a null base pointer
We can't use null for the proxy view passed to the successor allocators
because it triggers undefined behaviour.
2018-03-05 15:58:36 +11:00
15fad39e8a alloc/foreign: add warning about non-trivial child allocators 2018-03-02 12:45:52 +11:00
950ac2229f alloc/foreign: correctly rebase 'offset' 2018-03-02 12:45:27 +11:00
c2265b9ed2 alloc: add aligned::foreign allocator
sometimes we need to ensure memory allocation has a particular alignment
in an _offset_ buffer (which we have no control over, eg renderdoc's
OpenGL buffers).

this applies an offset to various operations that make the
aligned::direct allocator correctly align allocations for buffers that
aren't themselves aligned.
2018-03-02 12:21:38 +11:00
35537b07ca alloc/aligned: add accessor for alignment 2018-03-01 14:43:37 +11:00
7af076e2de alloc: prefer std::byte representations for iterators
this allows the users to more easily walk the byte ranges (or perform
simply pointer arithmetic), without as much danger of using the values
in an expression inadvertantly.
2018-02-28 17:55:56 +11:00
2941a5a3e1 alloc/raw: add 'data' accessor 2018-02-28 16:19:27 +11:00
82a8446e10 build: silence various type conversion warnings 2018-01-18 11:56:42 +11:00
1d11f05918 cast: move casting functions into util::cast namespace 2018-01-16 15:11:15 +11:00
0351313c36 Merge branch 'master' into coord 2017-11-23 17:24:11 +11:00
f06eab9a3a a/r/aligned: add forgotten headers and namespace qualifiers 2017-09-21 15:06:35 +10:00
0e97044adf allow/raw: rename base as begin 2017-08-31 13:48:33 +10:00
0f4fece00f alloc/raw/linear: add constructor from range types 2017-08-30 15:13:43 +10:00
cfc8cb5691 allow/raw/stack: remove unused ipp file 2017-08-29 16:59:54 +10:00
9d5e599246 alloc: seperate out the raw allocators from the adapters 2017-08-29 16:53:11 +10:00