Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 02 Jan 2019 06:28:50 -0500
From:      "Garance A Drosehn" <drosih@rpi.edu>
To:        "Johannes Lundberg" <johalun0@gmail.com>
Cc:        freebsd-hackers@freebsd.org
Subject:   Re: Speculative: Rust for base system components
Message-ID:  <AC2473C1-DCA9-47D2-943F-150B38E902C9@rpi.edu>
In-Reply-To: <804bd7ee-d9c3-08ba-031f-df0348860d35@gmail.com>
References:  <20190101045638.D280E1F56@spqr.komquats.com> <a2d04773-c7cc-457d-4db6-913cb84e885b@metricspace.net> <CADWvR2izXwGRwkWn52x6s3U73ki5Qdg98Y-00use=G9febhrGA@mail.gmail.com> <4ea0612bbad08e61a15d495459b2bede@rpi.edu> <CAG6CVpWJ=AOVt7zXZKCXqJnbtJ8U_EyYTpTHOVzpoRk5JDWjyA@mail.gmail.com> <804bd7ee-d9c3-08ba-031f-df0348860d35@gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 2 Jan 2019, at 6:06, Johannes Lundberg wrote:

> On 1/2/19 12:35 AM, Conrad Meyer wrote:
>>
>> All are dynamically linked and stripped amd64 binaries.  Ripgrep
>> (Rust) is 48x the binary size of ag and 37x that of grep(1).  Like
>> grep(1), 'ag' is written in C.

>
> Rust by default statically link everything in executable binaries.
> This is comparable to statically link in libc and all other
> dependencies in your C program. You can have Rust programs link
> against shared rust libraries (std, etc) and get the size down
> to basically same as C.
>
> If Rust is used in base and everything is built at the same time,
> with same version compiler, it would make sense to link dynamically
> I think.
>
> Switching topic a bit. Just wanted to also add my contribution,
> a simple sysctl Rust library
>    https://github.com/johalun/sysctl-rs .

Personally I think it's interesting and helpful to see some more
projects like this, so we can get a better understanding of how
well the language works for systems-level programs.  I'm going to
take a look at this, just for my own curiosity.   Thanks!

-- 
Garance Alistair Drosehn                =     drosih@rpi.edu
Senior Systems Programmer               or   gad@FreeBSD.org
Rensselaer Polytechnic Institute;             Troy, NY;  USA



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?AC2473C1-DCA9-47D2-943F-150B38E902C9>