diff --git a/lib/system/gc.nim b/lib/system/gc.nim index 8cc9c63878..d5925162d0 100644 --- a/lib/system/gc.nim +++ b/lib/system/gc.nim @@ -892,9 +892,6 @@ when not defined(useNimRtl): "API usage error: GC_enable called but GC is already enabled") dec(gch.recGcLock) - proc GC_setStrategy(strategy: GC_Strategy) = - discard - proc GC_enableMarkAndSweep() = gch.cycleThreshold = InitialCycleThreshold diff --git a/lib/system/gc_interface.nim b/lib/system/gc_interface.nim index 256efbe547..8d01ffade0 100644 --- a/lib/system/gc_interface.nim +++ b/lib/system/gc_interface.nim @@ -3,14 +3,6 @@ when not usesDestructors: {.pragma: nodestroy.} -when hasAlloc: - type - GC_Strategy* = enum ## The strategy the GC should use for the application. - gcThroughput, ## optimize for throughput - gcResponsiveness, ## optimize for responsiveness (default) - gcOptimizeTime, ## optimize for speed - gcOptimizeSpace ## optimize for memory footprint - when hasAlloc and not defined(js) and not usesDestructors: proc GC_disable*() {.rtl, inl, gcsafe, raises: [].} ## Disables the GC. If called `n` times, `n` calls to `GC_enable` @@ -66,9 +58,6 @@ when hasAlloc and defined(js): template GC_fullCollect* = {.warning: "GC_fullCollect is a no-op in JavaScript".} - template GC_setStrategy* = - {.warning: "GC_setStrategy is a no-op in JavaScript".} - template GC_enableMarkAndSweep* = {.warning: "GC_enableMarkAndSweep is a no-op in JavaScript".} diff --git a/lib/system/gc_ms.nim b/lib/system/gc_ms.nim index fcaae690ba..d25bd7e42c 100644 --- a/lib/system/gc_ms.nim +++ b/lib/system/gc_ms.nim @@ -491,8 +491,6 @@ when not defined(useNimRtl): "API usage error: GC_enable called but GC is already enabled") dec(gch.recGcLock) - proc GC_setStrategy(strategy: GC_Strategy) = discard - proc GC_enableMarkAndSweep() = gch.cycleThreshold = InitialThreshold diff --git a/lib/system/gc_regions.nim b/lib/system/gc_regions.nim index c1bf61d283..38babf784e 100644 --- a/lib/system/gc_regions.nim +++ b/lib/system/gc_regions.nim @@ -415,7 +415,6 @@ when hasThreadSupport: proc GC_disable() = discard proc GC_enable() = discard proc GC_fullCollect() = discard -proc GC_setStrategy(strategy: GC_Strategy) = discard proc GC_enableMarkAndSweep() = discard proc GC_disableMarkAndSweep() = discard proc GC_getStatistics(): string = return "" diff --git a/lib/system/mm/boehm.nim b/lib/system/mm/boehm.nim index 1617bfec0e..6edaac1fcf 100644 --- a/lib/system/mm/boehm.nim +++ b/lib/system/mm/boehm.nim @@ -76,7 +76,6 @@ when not defined(useNimRtl): proc GC_disable() = boehmGC_disable() proc GC_enable() = boehmGC_enable() proc GC_fullCollect() = boehmGCfullCollect() - proc GC_setStrategy(strategy: GC_Strategy) = discard proc GC_enableMarkAndSweep() = discard proc GC_disableMarkAndSweep() = discard proc GC_getStatistics(): string = return "" diff --git a/lib/system/mm/go.nim b/lib/system/mm/go.nim index 853364bdb1..1b63f9478c 100644 --- a/lib/system/mm/go.nim +++ b/lib/system/mm/go.nim @@ -12,7 +12,6 @@ proc GC_disable() = discard proc GC_enable() = discard proc go_gc() {.importc: "go_gc", dynlib: goLib.} proc GC_fullCollect() = go_gc() -proc GC_setStrategy(strategy: GC_Strategy) = discard proc GC_enableMarkAndSweep() = discard proc GC_disableMarkAndSweep() = discard diff --git a/lib/system/mm/malloc.nim b/lib/system/mm/malloc.nim index b3f81b5421..d1e61e6a8b 100644 --- a/lib/system/mm/malloc.nim +++ b/lib/system/mm/malloc.nim @@ -55,8 +55,6 @@ when not defined(gcOrc) and not defined(gcYrc): proc GC_enableMarkAndSweep() = discard proc GC_disableMarkAndSweep() = discard -proc GC_setStrategy(strategy: GC_Strategy) = discard - proc getOccupiedMem(): int = discard proc getFreeMem(): int = discard proc getTotalMem(): int = discard diff --git a/lib/system/mm/none.nim b/lib/system/mm/none.nim index 53cea7f503..ab68d5a8b2 100644 --- a/lib/system/mm/none.nim +++ b/lib/system/mm/none.nim @@ -8,7 +8,6 @@ proc initGC() = discard proc GC_disable() = discard proc GC_enable() = discard proc GC_fullCollect() = discard -proc GC_setStrategy(strategy: GC_Strategy) = discard proc GC_enableMarkAndSweep() = discard proc GC_disableMarkAndSweep() = discard proc GC_getStatistics(): string = return ""