summary refs log tree commit diff stats
path: root/lib/system/mmdisp.nim
Commit message (Collapse)AuthorAgeFilesLines
* forward type alignment information to seqs (#12430)Arne Döring2020-04-191-2/+2
|
* catchable defects (#13626)Andreas Rumpf2020-03-121-2/+4
| | | | | | | | | | * allow defects to be caught even for --exceptions:goto (WIP) * implemented the new --panics:on|off switch; refs https://github.com/nim-lang/RFCs/issues/180 * new implementation for integer overflow checking * produce a warning if a user-defined exception type inherits from Exception directly * applied Timothee's suggestions; improved the documentation and replace the term 'checked runtime check' by 'panic' * fixes #13627 * don't inherit from Exception directly
* Cleaned up mmdisp.nim, moved implementations into lib/system/mm/ (#13254)Ico Doornekamp2020-01-251-392/+4
|
* Removed lib/system/allocators.nim. seqs_v2 and strs_v2 now uses ↵Ico Doornekamp2020-01-231-63/+40
| | | | | | | | | | | | | | | | | | | | | | | | | allocShared0. (#13190) * Cleanup, remove lib/system/allocators.nim. seqs_v2 and strs_v2 now use allocShared0 by default. * Fixed -d:useMalloc allocShared / reallocShared / deallocShared. These now use the alloc/dealloc/realloc implementation that also takes care of zeroing memory at realloc. * Removed debug printfs * Removed unpairedEnvAllocs() from tests/destructor/tnewruntime_misc * More mmdisp cleanups. The shared allocators do not need to zero memory or throw since the regular ones already do that * Introduced realloc0 and reallocShared0, these procs are now used by strs_v2 and seqs_v2. This also allowed the -d:useMalloc allocator to drop the extra header with allocation length. * Moved strs_v2/seqs_v2 'allocated' flag into 'cap' field * Added 'getAllocStats()' to get low level alloc/dealloc counters. Enable with -d:allocStats * *allocShared implementations for boehm and go allocators now depend on the proper *allocImpl procs
* Added 'ansic' os support for minimal (embedded) targets (#13088)Ico Doornekamp2020-01-151-13/+6
| | | | | | | | * os:any implementation * os:asny: omit flock/funlock calls in echoBinSafe * Disabled default "unhandled expection" reporting for `--os:any` to reduce code size. Added unhandledExceptionHook instead which can be used to get a notification from Nim and handle it from the application.
* take the one good idea from --os:standalone and enable it via ↵Andreas Rumpf2020-01-091-1/+1
| | | | -d:StandaloneHeapSize (#13077)
* ARC: cycle detector (#12823)Andreas Rumpf2019-12-171-1/+2
| | | | | | | | | | | | | * first implementation of the =trace and =dispose hooks for the cycle collector * a cycle collector for ARC: progress * manual: the .acyclic pragma is a thing once again * gcbench: adaptations for --gc:arc * enable valgrind tests for the strutils tests * testament: better valgrind support * ARC refactoring: growable jumpstacks * ARC cycle detector: non-recursive algorithm * moved and renamed core/ files back to system/ * refactoring: --gc:arc vs --gc:orc since 'orc' is even more experimental and we want to ship --gc:arc soonish
* --gc:destructors now means Nim uses pure refcounting (#12557)Andreas Rumpf2019-10-301-2/+2
|
* first implementation of the new --seqsv2 switchAraq2019-10-201-1/+1
|
* Fixes #12286 - require explicit disabling of boehm interior pointer checking ↵genotrance2019-10-111-1/+3
| | | | (#12406) [backport]
* Fix spellings (#12277) [backport]Federico Ceratto2019-09-271-1/+1
|
* gc:destructors progressAndreas Rumpf2019-09-161-2/+4
|
* fixes a critical --gc:boehm regressionAndreas Rumpf2019-09-061-4/+4
|
* fixes #11447Andreas Rumpf2019-07-061-1/+3
|
* [feature] Add boehm gc finalizer (#11446)yatsen12019-06-171-0/+7
|
* --newruntime: progressAndreas Rumpf2019-03-141-1/+2
|
* --newruntime: work in progressAndreas Rumpf2019-03-141-0/+2
|
* system refactorings (#10559)Andreas Rumpf2019-02-061-1/+1
| | | | | | | | * move IO subsystem into its own module; refs #10385 * make standalone test compile again * make C++ examples compile again * make more tests green * make sysAssert and gcAssert work again
* Disable interior pointer checking by default for the Boehm GC. (#10316)Reimer Behrends2019-01-151-0/+3
| | | | | | | | | | | | | | | The Boehm GC only needs interior pointer checking if pointers in global variables or on the heap point to the interior of an object rather than the beginning. If this does not happen, then checking for interior pointers causes additional overhead, in particular because any objects whose sizes are an exact multiple of two words gain another two words of padding, wasting memory. If checking of interior pointers is still desired, this can be achieved by setting the environment variable GC_ALL_INTERIOR_POINTERS. Pointers on the stack will always be treated as potential interior pointers, as compiler optimizations may advance the only live reference to a point past the beginning of an object.
* Remove dead code (#9777)Jacek Sieka2018-11-261-8/+8
| | | | | | | | | * gc/gc2: remove unused ref counting stuff * also removes some false threading support - hasSharedHeap is always false in gc/gc2 * gc: remove some threading cruft * remove asgnRefNoCycle * compiler: remove TLoc.dup (unused)
* removes deprecated T/P typesAraq2018-11-161-1/+0
|
* gogc: GCC-8.2.0 compatibility and other improvements (#9211)Ștefan Talpalaru2018-10-111-107/+53
| | | | | | | | - Go's write barriers are now plugged-in in all the relevant points - "gcGo" is correctly classified by usesWriteBarrier() - some gogc structures and functions now use golib wrappers to keep GCC version-specific conditions out of the compiler/stdlib code - we no longer allow mixing the C malloc with Go's - fix a problem with string copying
* more progress on destructor based stringsAndreas Rumpf2018-07-131-1/+1
|
* mmdisp: code cleanupsAndreas Rumpf2018-07-111-64/+59
|
* hotfix 3221ac094398492e09ea618638204793b0990eca broke gc:regions/aka gc:stack byCharles Blake2018-06-131-1/+2
| | | | | underallocating for sequences of any type larger than 1 byte. This does the necessary multiply to restore basic functionality.
* Expose GC_setStackBottom (#7885)Yuriy Glukhov2018-06-041-4/+4
|
* hotfix for --gc:regionsAndreas Rumpf2018-05-281-6/+9
|
* Don't zeroMem result of boehmAlloc() (#7029)Mathias Stearn2018-01-051-3/+1
| | | | From the man page: "Unlike the standard implementations of malloc, GC_malloc clears the newly allocated storage. GC_malloc_atomic does not."
* cleanup todo.txtAraq2017-12-071-1/+2
|
* make asyncdispatch compile with the foreign GCsAraq2017-12-011-0/+8
|
* remove goFree() (#6808)Ștefan Talpalaru2017-11-251-2/+0
| | | | __go_free() was removed from gcc-7.2.0 so we stop trying to help the garbage collector by marking no longer used memory regions
* newSeqOfCap: skip initialization step for non-GC-ed dataAndreas Rumpf2017-09-241-1/+5
|
* remove ArrayDummySize with unchecked arrays (#5818)Jacek Sieka2017-08-281-1/+1
|
* WIP: --gc:regions instead of --gc:stackAraq2017-08-131-3/+3
|
* fixes #6234Andreas Rumpf2017-08-111-1/+1
|
* support libgo from GCC 6.3 (#5964)Ștefan Talpalaru2017-06-081-1/+10
|
* Control leakDetector from cmdlineYuriy Glukhov2016-12-061-1/+1
|
* Add define value `nimBurnFree` which allow deallocation procedures to fill ↵cheatfate2016-09-201-1/+1
| | | | memory with 0xFF before freeing it.
* added system.newSeqOfCap for improved efficiencyAndreas Rumpf2016-07-151-0/+14
|
* fix types of ansi_c/sysio to more closely match C ABIJacek Sieka2016-06-051-12/+12
| | | | | also fixes some instances of using C library functions when there are nim alternatives available
* Merge remote-tracking branch 'origin/devel' into malloc-store-sizeJacek Sieka2016-04-261-4/+8
|\
| * simple stuff works with --gc:stackAndreas Rumpf2016-04-181-4/+5
| |
| * beginnings of --gc:stackAndreas Rumpf2016-03-281-0/+3
| |
* | store block size in when using malloc and nogcJacek Sieka2016-03-251-5/+20
|/ | | | | this allows for a correct implementation of realloc, which is needed as code using it assumes new values will be zeroed out / nil
* newObj can clear memory, even when using malloc and nogcJacek Sieka2016-03-071-1/+1
|
* further progress on --gc:v2Andreas Rumpf2016-02-171-1/+1
|
* some progress on GC v2Andreas Rumpf2016-02-031-2/+2
|
* set debug switch to false againAraq2015-12-011-1/+1
|
* next steps for the GCAraq2015-12-011-1/+1
|
* Remove spurious unsigned operations from system/threads.nim.Reimer Behrends2015-09-081-3/+0
| | | | | | These operations were included before the unsigned module was incorporated directly into system.nim and subsequently caused compilation errors with --gc:go due to duplicate definitions.