From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: manolis837@gmail.com Newsgroups: gmane.lisp.guile.devel Subject: [PATCH] On Hurd, don't use not implemented madvise() Date: Tue, 30 May 2017 12:26:27 +0300 Message-ID: <20170530092627.19412-1-manolis837@gmail.com> NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1496136408 8511 195.159.176.226 (30 May 2017 09:26:48 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 30 May 2017 09:26:48 +0000 (UTC) To: guile-devel@gnu.org Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Tue May 30 11:26:44 2017 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dFdQK-00025S-Ag for guile-devel@m.gmane.org; Tue, 30 May 2017 11:26:44 +0200 Original-Received: from localhost ([::1]:52467 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dFdQP-0008R1-Je for guile-devel@m.gmane.org; Tue, 30 May 2017 05:26:49 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:40218) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dFdQE-0008Po-Va for guile-devel@gnu.org; Tue, 30 May 2017 05:26:39 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dFdQB-0004zG-Pb for guile-devel@gnu.org; Tue, 30 May 2017 05:26:38 -0400 Original-Received: from mail-wm0-x241.google.com ([2a00:1450:400c:c09::241]:36481) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dFdQB-0004z5-Il for guile-devel@gnu.org; Tue, 30 May 2017 05:26:35 -0400 Original-Received: by mail-wm0-x241.google.com with SMTP id k15so23755510wmh.3 for ; Tue, 30 May 2017 02:26:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=BmydSzMTKlsyOwQ5udmfk8iMw8rfHR8galg7zJ3asrg=; b=DB+gBd+QnJjq1gpxUXfx6nmYpeo7CFuByh0IAXLVt+HQvhVmOn3FfOo0PHtya75Icl e3kjbEGkAxxAthjgffaPcjBN/ugVKRRsj2+XAVuJkp+DCB4KUBDz0dkKIYvt7Etv3vg1 bd9ZFBYoe/TxKJV5dxeOJV1z/CBBEBJl1uFY+HY2QXm8TnCyIfaZpDv/sqxD0RkHv52j Sp+o0VVxAO31g1bDTCCVnho4Xmw7WoqMxncZCDKaFMkgeRvZIiCvc9GbhXVPKVt3wKQu 8FSRXBuYRHiyT6P6cDv7LCQNpUSjk3z9QbGoLAIqlq7rMjO9+e10kSTloEEUx7BRDP+/ UMPw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=BmydSzMTKlsyOwQ5udmfk8iMw8rfHR8galg7zJ3asrg=; b=c0dq/Su8JMeYHO8MerA/zJn9TpF1/UzE5ff39ZOtjBJpHa74eCMEvWJRPvc8w5PKRK e38O72se5Q0XV0xfQ6X8OvIPqhK3zssxPoRqeJZyYGg3JGSZ0LtuRqgAQJuSay57mGDe 540TKFu+Qw/oPYLSUgMuNHavYCJ6o8xc8qjrcTFoWvKNS8dTIaiklAZpaeP0Hzxi6fh5 82kA2SXA+o7mgQhkzu6nUJpTzd6zIj8fugt3gHFmHfoE8VRChTHk5wH766MpYry8nLiU /Nv9ZeaNaH9cOwU7FI4soQadYdVpqzQ4P12zqi63BT+SUSXROI0cXSm006SzqRCmHfq0 NI3g== X-Gm-Message-State: AODbwcAoO8ULmwBEssCWXzlqurucoaqSOZESa+ilsGEhzxnt/oLo7jee SaLBguNXzkLHeKI1EAQ= X-Received: by 10.223.131.129 with SMTP id 1mr13026445wre.104.1496136394085; Tue, 30 May 2017 02:26:34 -0700 (PDT) Original-Received: from localhost.localdomain (ppp-2-84-15-85.home.otenet.gr. [2.84.15.85]) by smtp.gmail.com with ESMTPSA id v45sm14291291wrb.68.2017.05.30.02.26.33 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 30 May 2017 02:26:33 -0700 (PDT) X-Mailer: git-send-email 2.13.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:400c:c09::241 X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Original-Sender: "guile-devel" Xref: news.gmane.org gmane.lisp.guile.devel:19175 Archived-At: From: Manolis Ragkousis On Hurd, because madvise() is not implemented we disable it. * libguile/vm.c (return_unused_stack_to_os): Don't use madvise() on Hurd. --- libguile/vm.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libguile/vm.c b/libguile/vm.c index 18f219249..7089f23c7 100644 --- a/libguile/vm.c +++ b/libguile/vm.c @@ -896,6 +896,8 @@ return_unused_stack_to_os (struct scm_vm *vp) /* Return these pages to the OS. The next time they are paged in, they will be zeroed. */ +#if !defined __gnu_hurd__ + /* madvise() is not implemented on GNU Hurd. */ if (lo < hi) { int ret = 0; @@ -907,7 +909,7 @@ return_unused_stack_to_os (struct scm_vm *vp) if (ret) perror ("madvise failed"); } - +#endif vp->sp_min_since_gc = vp->sp; #endif } -- 2.13.0