• Austin Clements's avatar
    runtime: control background scan credit flushing with flag · c18b163c
    Austin Clements authored
    Currently callers of gcDrain control whether it flushes scan work
    credit to gcController.bgScanCredit by passing a value other than -1
    for the flush threshold. Shortly we're going to make this always flush
    scan work to gcController.scanWork and optionally also flush scan work
    to gcController.bgScanCredit. This will be much easier if the flush
    threshold is simply a constant (which it is in practice) and callers
    merely control whether or not the flush includes the background
    credit. Hence, replace the flush threshold argument with a flag.
    
    Change-Id: Ia27db17de8a3f1e462a5d7137d4b5dc72f99a04e
    Reviewed-on: https://go-review.googlesource.com/15406Reviewed-by: default avatarRick Hudson <rlh@golang.org>
    c18b163c
mgc.go 58.2 KB