From nobody Sun Dec 10 05:37:07 2023 X-Original-To: standards@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4SnttC72Cbz537yZ for ; Sun, 10 Dec 2023 05:37:07 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4SnttC5CRQz3SSm for ; Sun, 10 Dec 2023 05:37:07 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1702186627; a=rsa-sha256; cv=none; b=Ort9fNNl+SQYGlYQzYB+oa3ue0/rmqaRCDbyLpUt4yU48I+4y8/JU8PRH6ztpk35g2g40B bQpasbjm6nXhRWtlQcxx5+mDDQ5HPNsWHBdnw3g3sRkMgUkg3FoU6VZit4zLQjwrkuQYiG ewWiSBzZvkc2jwCYJ8JO2ti8J6qXOw8wm9VH7DLJyalevRNfM9jf0tKaQ95GdJx1VN8y3v dhGqsM7Lmw0s4bC2AjlCMug7Hddxny23FOQIJFmYlPvVlReRr/qCgkkp/EdhA6xDoJn2I+ 3IsLoD1gWjIiO0Vq1MneIcI6MhQhLhZv2Al30o7cZnz8zQ5WKuYjKB0wGL82yA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1702186627; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=0meazOu6TqON6WJl0bTNtlnoBx1nXz6wlncxjZADQac=; b=MQKw1ahDZ1w3aMMx64M+M/JZnA+9VBd1gTzhILWwG3SgYlKQnvmf5BAyx2/PhNaGnmHs+r 4QBHVX0C0S8IfMsnIY+OYta5F4h5FQpcv6triESYUxR0PvcK4i9tuCRfLFUh21/hqrgh27 UkeWHpFpM6s8RIMbnwwaEJnKP1QMf7rOKEHZNLFYXIzwedohdrrdByqQdf3dV2gCLfrd+Q tF6LzE9Lwgmj7q6KpehD5azE7LYIiDQmqXCICAN8u8rd/4lio5EYbOoM+GhQnbCIMXvQ0m 55eydKHBZ/VDr0KAkRFZ5GL4ek7l0hW5V09NAYZCRYnJo6Q+aU4OhxrgSnpKDA== Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4SnttC4BGRzbWH for ; Sun, 10 Dec 2023 05:37:07 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 3BA5b76m096703 for ; Sun, 10 Dec 2023 05:37:07 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 3BA5b7VW096701 for standards@FreeBSD.org; Sun, 10 Dec 2023 05:37:07 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: standards@FreeBSD.org Subject: [Bug 275661] /usr/bin/dc hangs with a trivial calculation Date: Sun, 10 Dec 2023 05:37:07 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: standards X-Bugzilla-Version: 13.2-RELEASE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Many People X-Bugzilla-Who: dclarke@blastwave.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: standards@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Standards compliance List-Archive: https://lists.freebsd.org/archives/freebsd-standards List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-standards@freebsd.org X-BeenThere: freebsd-standards@freebsd.org MIME-Version: 1.0 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D275661 --- Comment #2 from Dennis Clarke --- (In reply to Mark Millard from comment #1) Excellent ! Thank you. I knew it was from Scientific American but clearly not Martin Gardner. Also, it seems that dc is not hung or strangely locked up. It is just very very very slow. Also it gets slower and slower depending on the exponent in this trivial computation :=20 (1) firstly I need something that will kick out the current UNIX time along with the subseconds : https://git.sr.ht/~blastwave/bw/tree/bw/item/time_and_date/timenow/tn.c pluto$ cc -std=3Diso9899:1999 -g -O0 -m64 -o $HOME/bin/tn /opt/bulk/users/dclarke/tn.c pluto$ $HOME/bin/tn 1702150944 pluto$ bin/tn -f 1702150948.185400780 I can generally trust that time data down to the millisecond but no further. (2) try that same computation with an exponent of 2^21 : pluto$ bin/tn -f ; echo "16k 1.0000001 2 21^ ^ pq" | dc ; bin/tn -f 1702150982.359058318 1.2333267455406059 1702151041.388274513 pluto$ echo '16k 1702151041.388274513 1702150982.359058318 - pq' | dc 59.029216195 (3) same thing again with 2^22 : pluto$ bin/tn -f ; echo "16k 1.0000001 2 22^ ^ pq" | dc ; bin/tn -f 1702151116.511391274 1.5210948612657825 1702151292.913553255 pluto$ echo '16k 1702151292.913553255 1702151116.511391274 - pq' | dc 176.402161981 (4) and now 2^23 pluto$ bin/tn -f ; echo "16k 1.0000001 2 23^ ^ pq" | dc ; bin/tn -f 1702151370.327805625 2.3137295769691702 1702151899.256797300 pluto$ echo '16k 1702151899.256797300 1702151370.327805625 - pq' | dc 528.928991675 (5) things are really getting slow with 2^24 pluto$ bin/tn -f ; echo "16k 1.0000001 2 24^ ^ pq" | dc ; bin/tn -f 1702152105.644851540 5.3533445553419354 1702153691.392552070 pluto$ echo '16k 1702153691.392552070 1702152105.644851540 - pq' | dc 1585.747700530 (6) again with 2^25 pluto$ bin/tn -f ; echo "16k 1.0000001 2 25^ ^ pq" | dc ; bin/tn -f 1702154005.973187537 28.6582979282091444 1702158766.756840716 pluto$=20=20 pluto$ echo '16k 1702158766.756840716 1702154005.973187537 - pq' | dc 4760.783653179 It looks like a factor of three increase in time required with each test. The test for 2^26 is still running and I expect 5 hours or so will be needed and that means the computation with 2^27 may be about 16 hours or so. Dennis --=20 You are receiving this mail because: You are the assignee for the bug.= From nobody Sun Dec 10 05:37:24 2023 X-Original-To: standards@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4SnttX0vRbz537WR for ; Sun, 10 Dec 2023 05:37:24 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4SnttW6vKZz3SZ3 for ; Sun, 10 Dec 2023 05:37:23 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1702186644; a=rsa-sha256; cv=none; b=GsdpFFbeY2QcQ0pG7rpzVJ1Tf32GHS6Hc+l947YIO1a+77UgSQSwYpGaVrtOUHZmqMR+t1 4AeVfxT8+Os7H6hEBG4vGMHInjJvst48z9zlkv2JO3+sVt58lbQDZC30Bdlf3VjhgFwIve //qbFRic+PNLdGMVsZzGR+ILgUPSDDcl99NYoxOiQElfTs7sedKo8Eso4GO0KMtsWXKopB 8G3XcuiYn3aq2hGqdpTDTXx/WMnlOp+JCA00lVXEcRHWDZWEWpMetmS8zusyjyCC3mCqym pNgY/QP4IgwuvBBJApkKQiE9i+lkSslfe1i0Glen1r9jhJxN6MaXGLK74wiuTw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1702186644; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=tMx7hfbwotw8Ogbdi2Lq21omoo4P4V+iEGkOzlcPR/8=; b=CPSCxa2GSnzflMDQie/n5skrGYT0ptNuShCuDTwkcNep0BARLe3xKUwdJ/u5QpnuIe5d3k Iz1qcBObx7rGpjUaugSutttCbcbPoGtGvUaiXwWjzxtID2CrJBTh+fClK2Z5BOy7VAqJX1 fJVmZmhty4WWvy+ajjsdk9YRO5zBBI/xN81iVmRmk4GdFa+lsGKcLW15kCe8nxr6ei15WK 1l/rsXLgh+Si3nEF/PCqMoEKuxtOe4cNZW11xJTJFBo0oEsXhNEbChfdE8QQCBvCAQISdL 5cz9dYCkjxJE4ZW8KTOHbNZx0jFVSFyN8jFvVRV+ReiHJJe1nam34ALm8f5/kA== Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4SnttW5zShzbmq for ; Sun, 10 Dec 2023 05:37:23 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 3BA5bNtG096837 for ; Sun, 10 Dec 2023 05:37:23 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 3BA5bNV0096836 for standards@FreeBSD.org; Sun, 10 Dec 2023 05:37:23 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: standards@FreeBSD.org Subject: [Bug 275661] /usr/bin/dc really slow with a trivial calculation Date: Sun, 10 Dec 2023 05:37:24 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: standards X-Bugzilla-Version: 13.2-RELEASE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Many People X-Bugzilla-Who: dclarke@blastwave.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: standards@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: short_desc Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Standards compliance List-Archive: https://lists.freebsd.org/archives/freebsd-standards List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-standards@freebsd.org X-BeenThere: freebsd-standards@freebsd.org MIME-Version: 1.0 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D275661 Dennis Clarke changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|/usr/bin/dc hangs with a |/usr/bin/dc really slow |trivial calculation |with a trivial calculation --=20 You are receiving this mail because: You are the assignee for the bug.= From nobody Sun Dec 10 21:01:15 2023 X-Original-To: standards@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4SpHNW5W2kz53BNs for ; Sun, 10 Dec 2023 21:01:15 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4SpHNW39bTz4LPV for ; Sun, 10 Dec 2023 21:01:15 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1702242075; a=rsa-sha256; cv=none; b=Mb4L4FoIMO1QhJ9by6TEv1Tru9OYNWIPGMvarLUjvoS14FoEnfA0VEv6tHMpheDtmNA9Z3 wVyu089igH3Y0ZLzEoLcDcbl2/S0by2vE2PUAYhrwrmUZsJFTPzvVOzDNJIWNgGGYoh7Eh aXV/O2CWLkp/Rycppo5io1udZllZMT93Nr971SXDrT9xI8QkoK2Mq36eKEjmNZDdfzaGFW xCfG3JEBX3AYL4ZqcL2chG5I5gP56ppT9e451ECBz4+ldGaFr0WlwYm8WMTioIv3X+4c7o /ZKITCmZ0FvOnI5mRD4SkUgiSUcC5oC554nFClDfh7ccRUw0dF9oXP4cSDE5vg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1702242075; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=1vi6IXSsU6HDGm1uAyzg7F5CQxLGbZj2x+2bZuKhFhs=; b=vLxFC55CVp4/KgFQ47zW63EcNYe7fScm6+18qK1W+KFOyVXxRE+V/804hPFfLHodxXs4sQ 2lbsJCVeYPUe+NzsFWwdyerYEdyKKtEVpqfWgmaO4ZuqXKFCcPFg52uISGlwdNGKE6sWwh UMLJFpf64rAxYyfcgp97DrUZ87qaVegiyRZDFQ8dNOR0ov8i4uIoR+4Ks0QA5csT96QA0T 6NO8gC8lM7RHkdIGyxuOe/o+cVSH+OJGacVnnakh9hShdA1f6CP36sElIhQRCW6+Q/yijL nm+U6u1w3d2vU7X/zNNDhbshbhXdPT6x7UXZ3zs6Ys+yHxbZCIa4wVjfT/NqxQ== Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4SpHNW2Fg9z12vG for ; Sun, 10 Dec 2023 21:01:15 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 3BAL1F2p093956 for ; Sun, 10 Dec 2023 21:01:15 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 3BAL1Fli093955 for standards@FreeBSD.org; Sun, 10 Dec 2023 21:01:15 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: standards@FreeBSD.org Subject: [Bug 275661] /usr/bin/dc really slow with a trivial calculation Date: Sun, 10 Dec 2023 21:01:15 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: standards X-Bugzilla-Version: 13.2-RELEASE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Many People X-Bugzilla-Who: dclarke@blastwave.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: standards@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Standards compliance List-Archive: https://lists.freebsd.org/archives/freebsd-standards List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-standards@freebsd.org X-BeenThere: freebsd-standards@freebsd.org MIME-Version: 1.0 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D275661 --- Comment #3 from Dennis Clarke --- Indeed it look like /usr/bin/dc is doing something ... slowly : pluto$ bin/tn -f ; echo "16k 1.0000001 2 26^ ^ pq" | dc ; bin/tn -f 1702174885.863497199 821.2980401419965396 1702189165.176900562 pluto$ echo '16k 1702189165.1769 1702174885.8635 - pq' | dc 14279.3134 Just under 4 hours. --=20 You are receiving this mail because: You are the assignee for the bug.=