Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 29 Mar 2021 13:12:44 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 254639] Fork syscall performance
Message-ID:  <bug-254639-227@https.bugs.freebsd.org/bugzilla/>

index | next in thread | raw e-mail

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=254639

            Bug ID: 254639
           Summary: Fork syscall performance
           Product: Base System
           Version: Unspecified
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: kern
          Assignee: bugs@FreeBSD.org
          Reporter: kirill@varnakov.com

Hello.

Can someone please explain where is the error? I am running Python code that
simulates forking a large process and gives poor performance results. Average 4
seconds.

import time
import os
some_str = ' ' * (100 * 1024 * 1024 * 1024)
while True:
    p = time.time()
    pid = os.fork()
    tt = time.time() - p
    if pid != 0:
        print("%d "%pid + str(tt) )
        time.sleep(1)
    if pid == 0:
        break

-- 
You are receiving this mail because:
You are the assignee for the bug.

help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-254639-227>