Message ID | 20240627142028.134709-1-mmartinv@redhat.com |
---|---|
Headers |
Return-Path: <libc-alpha-bounces+patchwork=sourceware.org@sourceware.org> X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 41D473832E4A for <patchwork@sourceware.org>; Thu, 27 Jun 2024 14:21:17 +0000 (GMT) X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTPS id 1E243384AB62 for <libc-alpha@sourceware.org>; Thu, 27 Jun 2024 14:20:37 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1E243384AB62 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 1E243384AB62 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.133.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1719498043; cv=none; b=PJwoqEX/Y2cS7+23kGS0jprSfXG0Swqup+McYjWbYJwmZxJmyXLdbN7nEvMLFCzZXZkyPATj19/9GGfAzyW8UClZV5cDpHSN39d2jnCC7B23c4FvsIgIyus3dIM/3nSPvz7bqDGCFMAueqJcvBSvxUg3vwP/22TEL3JykRVeU6k= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1719498043; c=relaxed/simple; bh=Z1ZyIthBVF6JpXMU+ZK/uRBuA0Q0xThySsAbwlfj9yU=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=UbkLcTCj6C8Q46fjVZxgSatX60PzVkPthRfpUQ/suaJdhKBraPjIXQZ00ExxcG6C/q8Q1LK4kxTx9d72dE2r3BRlVPsCeuWU4Pc1KUG7QFdGeABQ8R2AhqFbXKmtzzQ3PwCFVlAqNKhPiqBK8aY7wPyT5swH+PDxEKnYQyWfhyo= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1719498036; 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; bh=bZMPM+TBlawekxrmLO7HCJKUyBhRFH8AN+YnG1MxT78=; b=HcXMrOUDjpF1LWrbZAm7TRwo2GCVi0s2XdsoJzV1s2D9IOrFn7XN88gw+yjRZCTmDaO7AM fdKxuPhX3s7kbr3YDk5Xsd+uFaOgSEovJuE62oONa/EyzASFHLwQNyHrts76SOfKjs8Pjy nhw5vYN/G+tt6M1ITIiVewVroUpK+KM= Received: from mail-qv1-f70.google.com (mail-qv1-f70.google.com [209.85.219.70]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-632-swSWoXAkMgahh0NcaLnEHA-1; Thu, 27 Jun 2024 10:20:34 -0400 X-MC-Unique: swSWoXAkMgahh0NcaLnEHA-1 Received: by mail-qv1-f70.google.com with SMTP id 6a1803df08f44-6b51042049eso130240756d6.1 for <libc-alpha@sourceware.org>; Thu, 27 Jun 2024 07:20:34 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1719498033; x=1720102833; h=content-transfer-encoding:mime-version:message-id:date:subject:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=bZMPM+TBlawekxrmLO7HCJKUyBhRFH8AN+YnG1MxT78=; b=syE+Gbeqde2RbzGz9mF20YoauitMWb7WMO1KjiMQkaxqq3uqY1xsbJEui7i0yswd8u zZhWZ4fYL851NH6LaR8dVpq16Pq3YysCDSvSS/rN0c6lbjmUViJGfzLfVRsTN/JBhddC GDzrfc53oULIHJ9VhrBid8v4OwkKMLfplQBY+w+CEdHuwE0aGvPH4E+8cr7BOmhGwBdI x0Vhb7aDEpzMfYQ3sH8wyKCp9NtHgwJMOChokpTsloXC1TSPkN7yJqj1VVW7AY8+co4G l888cQIjHlN7NC/OXxgLMjwv0YcWDAWeh90QqfY9IB4MWskdmd+/nX+Te1Cf5DmKkZ06 pVpA== X-Gm-Message-State: AOJu0YwKKBqaX2as3cGyjwgyWSMH39k+XqKj3OfeAuf8nppf5AzS9AZx P/9HCPcSFbDDW1mNywTJEh4EW8D0CFSbavCQ4HWPy7PxZdvcqGqKOvtAv3ktkfiiCPF5HH1QsEB 1wLXLV6CDj5sMWUP9nXbmqvqJIGFNjo1C9Jhic2+QFPgbIQ9lw9aG/jh78f+FYaMf5R328WnWpa n3AtLhbk9BwVVd6gEXmlL0QG3gmzQ9rXQpFNVL2jiTPA== X-Received: by 2002:a05:6214:c4b:b0:6b5:7d92:3dd3 with SMTP id 6a1803df08f44-6b57d92404bmr76324396d6.24.1719498033348; Thu, 27 Jun 2024 07:20:33 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGsFvvZGnM8DzUPgwcokMwOjOQrZkVn95vQx9mNn5c30Ux4axZtnbKWyDqe13OpcSrTvqSTYg== X-Received: by 2002:a05:6214:c4b:b0:6b5:7d92:3dd3 with SMTP id 6a1803df08f44-6b57d92404bmr76323966d6.24.1719498032924; Thu, 27 Jun 2024 07:20:32 -0700 (PDT) Received: from lenovo-p1.mamux.org.com ([213.229.137.162]) by smtp.gmail.com with ESMTPSA id 6a1803df08f44-6b59241b5a5sm5442306d6.28.2024.06.27.07.20.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 27 Jun 2024 07:20:32 -0700 (PDT) From: =?utf-8?q?Miguel_Mart=C3=ADn?= <mmartinv@redhat.com> To: libc-alpha@sourceware.org Subject: [PATCH 0/2] malloc: add multi-threaded tests for aligned_alloc/calloc/malloc Date: Thu, 27 Jun 2024 16:20:21 +0200 Message-ID: <20240627142028.134709-1-mmartinv@redhat.com> X-Mailer: git-send-email 2.45.2 MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-3.5 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H4, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Libc-alpha mailing list <libc-alpha.sourceware.org> List-Unsubscribe: <https://sourceware.org/mailman/options/libc-alpha>, <mailto:libc-alpha-request@sourceware.org?subject=unsubscribe> List-Archive: <https://sourceware.org/pipermail/libc-alpha/> List-Post: <mailto:libc-alpha@sourceware.org> List-Help: <mailto:libc-alpha-request@sourceware.org?subject=help> List-Subscribe: <https://sourceware.org/mailman/listinfo/libc-alpha>, <mailto:libc-alpha-request@sourceware.org?subject=subscribe> Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org |
Series |
malloc: add multi-threaded tests for aligned_alloc/calloc/malloc
|
|
Message
Miguel Martín
June 27, 2024, 2:20 p.m. UTC
Improve aligned_alloc/calloc/malloc test coverage by adding multi-threaded tests with random memory allocations and with/without cross-thread memory deallocations. Modify the existing DSO used for random memory allocations to avoid getting global locks in the allocation process. The new tests are added to tests-exclude-mcheck as they don't seem to play well with mcheck and I have not been able to find any problem with the tests themselves. Happy to fix anything and/or file an issue in mcheck for further investigation. Miguel Martín (2): malloc: avoid global locks in tst-aligned_alloc-lib.c malloc: add multi-threaded tests for aligned_alloc/calloc/malloc malloc/Makefile | 8 + .../tst-aligned-alloc-random-thread-cross.c | 19 ++ malloc/tst-aligned-alloc-random-thread.c | 170 ++++++++++++++++++ malloc/tst-aligned_alloc-lib.c | 39 ++-- 4 files changed, 217 insertions(+), 19 deletions(-) create mode 100644 malloc/tst-aligned-alloc-random-thread-cross.c create mode 100644 malloc/tst-aligned-alloc-random-thread.c -- Miguel Martín mmartinv@redhat.com