@@ -122,7 +122,10 @@ type control =
122122 number is less than or equal to 1000, it is a percentage of
123123 the current heap size (i.e. setting it to 100 will double the heap
124124 size at each increase). If it is more than 1000, it is a fixed
125- number of words that will be added to the heap. Default: 15. *)
125+ number of words that will be added to the heap.
126+
127+ This field is currently not available in OCaml 5: the field value is
128+ always [0]. *)
126129
127130 space_overhead : int ;
128131 (* * The major GC speed is computed from this parameter.
@@ -157,16 +160,19 @@ type control =
157160 compaction is triggered at the end of each major GC cycle
158161 (this setting is intended for testing purposes only).
159162 If [max_overhead >= 1000000], compaction is never triggered.
160- Default: 500. *)
163+
164+ This field is currently not available in OCaml 5: the field value is
165+ always [0]. *)
161166
162167 stack_limit : int ;
163168 (* * The maximum size of the fiber stacks (in words).
164- Default: 1024k . *)
169+ Default: 128M . *)
165170
166171 allocation_policy : int ;
167172 (* * The policy used for allocating in the major heap.
168173
169- This option is ignored in OCaml 5.x.
174+ This field is currently not available in OCaml 5: the field value is
175+ always [0].
170176
171177 Prior to OCaml 5.0, possible values were 0, 1 and 2.
172178
@@ -182,8 +188,10 @@ type control =
182188 (* * The size of the window used by the major GC for smoothing
183189 out variations in its workload. This is an integer between
184190 1 and 50.
185- Default: 1.
186- @since 4.03 *)
191+ @since 4.03
192+
193+ This field is currently not available in OCaml 5: the field value is
194+ always [0]. *)
187195
188196 custom_major_ratio : int ;
189197 (* * Target ratio of floating garbage to major heap size for
@@ -257,14 +265,22 @@ external get : unit -> control = "caml_gc_get"
257265[@@ alert unsynchronized_access
258266 "GC parameters are a mutable global state."
259267]
260- (* * Return the current values of the GC parameters in a [control] record. *)
268+ (* * Return the current values of the GC parameters in a [control] record.
269+
270+ The [major_heap_increment], [max_overhead], [allocation_policy], and
271+ [window_size] fields are currently not available in OCaml 5: their returned
272+ field values are therefore [0]. *)
261273
262274external set : control -> unit = " caml_gc_set"
263275[@@ alert unsynchronized_access
264276 "GC parameters are a mutable global state."
265277]
266- (* * [set r] changes the GC parameters according to the [control] record [r].
267- The normal usage is: [Gc.set { (Gc.get()) with Gc.verbose = 0x00d }] *)
278+ (* * [set r] changes the GC parameters according to the [control] record [r].
279+ The normal usage is: [Gc.set { (Gc.get()) with Gc.verbose = 0x00d }]
280+
281+ The [major_heap_increment], [max_overhead], [allocation_policy], and
282+ [window_size] fields are currently not available in OCaml 5: setting them
283+ therefore has no effect. *)
268284
269285external minor : unit -> unit = " caml_gc_minor"
270286(* * Trigger a minor collection. *)
0 commit comments