forked from idris-lang/Idris2
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[RefC] Object Immortalization and Pre-Generation of Constants (idris-…
…lang#3242) * [RefC] shrink value_header; object imortalized; stock well knwon values. * Shrink Value_Header to improve utilization of memory. * When refCounter reaches its maximum, the object is immortalized to avoid overflow. This immotalization is also used to represent statically allocated stock objects. * Prepare some commonly seen values and share it to improve memory usage. * Added debug code to dump memory stats. * [RefC] Allocated constants statically; Predefined commonly seen values. * Commonly seen values such as integers less than 100 are predefined and shared. * Constant String, Int64, Bits64 and Double values are allocated statically as indestructible and shared. * linter * [RefC] make constants const. * cleanup * cleanup * update CHANGELOG_NEXT * [refc][test] revert debugging code * Refactor constantName function in RefC.idr Refactor constantName function to return Core String type and handle unsupported types by throwing InternalError exception. * lint * fix typo in support/refc/memoryManagement.c Co-authored-by: Mathew Polzin <matt.polzin@gmail.com> * [RefC] erase runtime error of constantName * [RefC] Fixed the missing case expression coverage. --------- Co-authored-by: Mathew Polzin <matt.polzin@gmail.com>
- Loading branch information
1 parent
6364532
commit 95e4e0c
Showing
10 changed files
with
400 additions
and
203 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.