Skip to content

Commit 436d84e

Browse files
authored
Merge pull request #70 from GPUEngineering/feature/count-bytes-allocated
Count allocated bytes
2 parents 96e8f27 + b690452 commit 436d84e

File tree

6 files changed

+678
-506
lines changed

6 files changed

+678
-506
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# Custom
2+
python/*.bt
3+
14
## Ignore Visual Studio temporary files, build results, and
25
## files generated by popular Visual Studio add-ons.
36

CHANGELOG.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,16 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
<!-- ---------------------
9+
v1.8.0
10+
--------------------- -->
11+
## v1.8.0 - 21-03-2025
12+
13+
### Added
14+
15+
- Support for counting total allocated memory via `Session::getInstance().totalAllocatedBytes()`
16+
17+
818
<!-- ---------------------
919
v1.7.2
1020
--------------------- -->

README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -395,4 +395,14 @@ N.project(vectors);
395395
std::cout << vectors << "\n";
396396
```
397397

398+
## 5. Other
399+
400+
We can get the total allocated bytes (on the GPU) with
401+
```c++
402+
size_t allocatedBytes =
403+
Session::getInstance().totalAllocatedBytes();
404+
```
405+
406+
407+
398408
## Happy number crunching!

0 commit comments

Comments
 (0)