From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,e19b5ae33edaea7c,start X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!local01.nntp.dca.giganews.com!nntp.comcast.com!news.comcast.com.POSTED!not-for-mail NNTP-Posting-Date: Thu, 15 Sep 2005 00:10:43 -0500 From: tmoran@acm.org Newsgroups: comp.lang.ada Subject: puzzled re hyperthreaded performance X-Newsreader: Tom's custom newsreader Message-ID: Date: Thu, 15 Sep 2005 00:10:43 -0500 NNTP-Posting-Host: 24.6.102.223 X-Trace: sv3-9DdUeHW2Mv+w62a7Ly/F+0JtTXlyHe98spvenJamLdPT6tPrBxy1ZPeSEU4xJagMl4L45hm6CmuTKj0!Qnx2l9tcZG8OcaloAB+10U0Y9hW90dWqnyLQQtEInppv8/ovtp4y9kbiq2n/UzaahHl5dHKR9J3f X-Complaints-To: abuse@comcast.net X-DMCA-Complaints-To: dmca@comcast.net X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly X-Postfilter: 1.3.32 Xref: g2news1.google.com comp.lang.ada:4678 Date: 2005-09-15T00:10:43-05:00 List-Id: I have a multitasking program that runs faster if I insert a "delay d;" statement to prevent some of the multitasking overlap. This is a version of the Shootout k-nucleotide program, which involves a series of create/fill/lookup in hash tables, using the Ada 95 version of Ada.Containers.Indefinite_Hashed_Maps I let the operations run in two tasks, each with their own hash table. Memory requirement are minor. Alt_Task.Start; delay d; Compute; Alt_Task.Finish; Alt_Task performs the same computations as Compute, reading the same String, but sharing no other data. There are no obvious task interactions, and I don't see any in Ada.Containers For every additional 1.0 seconds of "d", the sequence runs about 1.5 seconds faster. This is Gnat 3.15p on W2k on a hyperthreaded Pentium (two virtual CPUs). Any suggestions what's going on?