From nobody Sun Nov 26 03:41:11 2023 X-Original-To: freebsd-arm@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 4SdDzB4VPdz52X62 for ; Sun, 26 Nov 2023 03:41:26 +0000 (UTC) (envelope-from bakul@iitbombay.org) Received: from mail-ot1-x330.google.com (mail-ot1-x330.google.com [IPv6:2607:f8b0:4864:20::330]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4SdDz90GV3z4bjD for ; Sun, 26 Nov 2023 03:41:24 +0000 (UTC) (envelope-from bakul@iitbombay.org) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=iitbombay-org.20230601.gappssmtp.com header.s=20230601 header.b=y8ElDpzM; spf=pass (mx1.freebsd.org: domain of bakul@iitbombay.org designates 2607:f8b0:4864:20::330 as permitted sender) smtp.mailfrom=bakul@iitbombay.org; dmarc=none Received: by mail-ot1-x330.google.com with SMTP id 46e09a7af769-6d81faeefc4so103547a34.2 for ; Sat, 25 Nov 2023 19:41:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=iitbombay-org.20230601.gappssmtp.com; s=20230601; t=1700970083; x=1701574883; darn=freebsd.org; h=to:date:message-id:subject:mime-version:from:from:to:cc:subject :date:message-id:reply-to; bh=VyrGGePTTPOdkXuJGIg0tmrDKxqJs43mWRwc2Mb7geo=; b=y8ElDpzMLybGkJ/sGOayYpq+jiwG0CthA+LmiqL7/FsKd0ifPgdA/YC2SxsXH2/Irl IdO3nFyr3ih6Ce8/prAbOCBWGpui6xaJ31LwRXHZR0eGmkU28xnk6oenP+ArorC3L5MY EnDPCOQlov3iq3qiNgF/jW3ZOudnNEF4O08WSrqztrV5j6x8MCcfmR9eMgsXI5Uyq+B+ vHK162ub/LHrWIJqb+r+4fgihaiPuxG0E1On0JYtxnON191w1ovqijpvBeRG/U7Fe9S0 7mru83IocTDfh6NKNUmQqVOxW1GsDP6L+yGVXTs6h+Y5aspq8MIrl4VQWbXwZMhaLDBI GW9w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700970083; x=1701574883; h=to:date:message-id:subject:mime-version:from:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=VyrGGePTTPOdkXuJGIg0tmrDKxqJs43mWRwc2Mb7geo=; b=m/6LJy0wuNiTtVm38VoRK7NqTGvpfBgKwL7SDueVGOIun87GnURTEUvaeKz0aYBJYo lxh1YSzTTd8jqWUBw8k7+gpoyXIo/9NJtEvEM36hSZAV6qWq2pS4SDXHMYGZaTN2fJsh a3wU95FulfxthZMA2Ss1yL7eItuugZ586TGTnaqnZW3KfA6zkVt2+7gsgI8gjJdO9HQy 3840npgZ3eZumvu3tAd5XA4Qak4HBmnuFl2elMO7p4GJB8Ew/MIddAl18hI0GX5mbPXu dgNWZz8VvYbSu8eSdHDfG5e0tmIaeLh1FYPEwf0vLKNShdV6hNRI6TnTB/4QgAYk9hLt +5mA== X-Gm-Message-State: AOJu0YyWkJRb3IJs6u1ny14mtLz56usof5nfUcYTkZsjTzuzKv5ZcdfA gDJ+GzWUoXyxuAdt5Vy1r59pKrA9nlCfYKxVPoc= X-Google-Smtp-Source: AGHT+IFH9e5jgLPehMySFZBz4PVaVhzyKQ6OFBDyfszK1sgTYeu1AglOoqhDIrjNpbVaiE4tV++KEw== X-Received: by 2002:a05:6830:18f:b0:6b8:9483:35ba with SMTP id q15-20020a056830018f00b006b8948335bamr9113964ota.24.1700970082859; Sat, 25 Nov 2023 19:41:22 -0800 (PST) Received: from smtpclient.apple (107-215-223-229.lightspeed.sntcca.sbcglobal.net. [107.215.223.229]) by smtp.gmail.com with ESMTPSA id jj14-20020a170903048e00b001c9d6923e7dsm5673961plb.222.2023.11.25.19.41.22 for (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Sat, 25 Nov 2023 19:41:22 -0800 (PST) From: Bakul Shah Content-Type: multipart/alternative; boundary="Apple-Mail=_BE49AF84-1DD8-4F35-AF29-6589DDEC5993" List-Id: Porting FreeBSD to ARM processors List-Archive: https://lists.freebsd.org/archives/freebsd-arm List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-arm@freebsd.org Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3774.200.91.1.1\)) Subject: sbrk Message-Id: <2F758BA2-F7F5-4A2C-85CF-6969EE50309C@iitbombay.org> Date: Sat, 25 Nov 2023 19:41:11 -0800 To: freebsd-arm@freebsd.org X-Mailer: Apple Mail (2.3774.200.91.1.1) X-Spamd-Result: default: False [-3.00 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_SHORT(-1.00)[-0.998]; MV_CASE(0.50)[]; R_DKIM_ALLOW(-0.20)[iitbombay-org.20230601.gappssmtp.com:s=20230601]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::330:from]; MLMMJ_DEST(0.00)[freebsd-arm@freebsd.org]; RCVD_VIA_SMTP_AUTH(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; FROM_EQ_ENVFROM(0.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; RCVD_TLS_LAST(0.00)[]; DKIM_TRACE(0.00)[iitbombay-org.20230601.gappssmtp.com:+]; DMARC_NA(0.00)[iitbombay.org]; RCPT_COUNT_ONE(0.00)[1]; FREEFALL_USER(0.00)[bakul]; ARC_NA(0.00)[]; RCVD_COUNT_TWO(0.00)[2]; FROM_HAS_DN(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-arm@freebsd.org]; TO_MATCH_ENVRCPT_ALL(0.00)[]; TO_DN_NONE(0.00)[]; MID_RHS_MATCH_FROM(0.00)[] X-Rspamd-Queue-Id: 4SdDz90GV3z4bjD X-Spamd-Bar: -- --Apple-Mail=_BE49AF84-1DD8-4F35-AF29-6589DDEC5993 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=us-ascii Does sbrk not exist on FreeBSD-14 on arm64? Is this by design? $ cat sb.c #include #include int main(int c, char**v) { void *x = sbrk(102400); printf("%p\n", x); } $ cc sb.c ld: error: undefined symbol: sbrk >>> referenced by sb.c >>> /tmp/sb-e97caf.o:(main) cc: error: linker command failed with exit code 1 (use -v to see invocation) --Apple-Mail=_BE49AF84-1DD8-4F35-AF29-6589DDEC5993 Content-Transfer-Encoding: 7bit Content-Type: text/html; charset=us-ascii Does sbrk not exist on FreeBSD-14 on arm64? Is this by design?

cat sb.c
#include <unistd.h>
#include <stdio.h>
int main(int c, char**v) {
        void *x = sbrk(102400);
        printf("%p\n", x);
}
$ cc sb.c
ld: error: undefined symbol: sbrk
>>> referenced by sb.c
>>>               /tmp/sb-e97caf.o:(main)
cc: error: linker command failed with exit code 1 (use -v to see invocation)

--Apple-Mail=_BE49AF84-1DD8-4F35-AF29-6589DDEC5993--