rustc-1.16.0 broken after jemalloc updated to 5.0.1

  • Done
  • quality assurance status badge
Details
5 participants
  • Adam Van Ymeren
  • Danny Milosavljevic
  • Jelle Licht
  • Ludovic Courtès
  • Nikolai Merinov
Owner
unassigned
Submitted by
Adam Van Ymeren
Severity
normal
A
A
Adam Van Ymeren wrote on 30 Nov 2017 23:41
(address . bug-guix@gnu.org)
87h8tb4cf1.fsf@vany.ca
I haven't had time to dig in to this further, but in case anyone wants
to fix rustc-1.16.0, it's broken after the upgrade of jemalloc to 5.0.1.

Reverting commit 475b99fa5cf402430aa93a40e406e854ad2ff6e4 which reverts
jemalloc back to 4.5.0 causes rustc to build successfully again. It has
been broken for some time.

J
J
Jelle Licht wrote on 4 Dec 2017 01:01
(name . Adam Van Ymeren)(address . adam@vany.ca)(address . 29522@debbugs.gnu.org)
CAPsKtf+A0cH3GhGtNgz8309odVVdsAUPC78PmZBiBD8xyKFuOQ@mail.gmail.com
2017-11-30 23:41 GMT+01:00 Adam Van Ymeren <adam@vany.ca>:

Toggle quote (12 lines)
> I haven't had time to dig in to this further, but in case anyone wants
> to fix rustc-1.16.0, it's broken after the upgrade of jemalloc to 5.0.1.
>
> Reverting commit 475b99fa5cf402430aa93a40e406e854ad2ff6e4 which reverts
> jemalloc back to 4.5.0 causes rustc to build successfully again. It has
> been broken for some time.
>
> https://hydra.gnu.org/job/gnu/master/rustc-1.16.0.x86_64-linux
>
>
>
>
It seems that the bundled copy of jemalloc in the rustc repo is currently
pinned at 4.5.0 partially
because of this specific issue as well.

I did find an issue on the rust GH repo [0], and it seems this also affects
the nix-rust project,
who seem to have the same errors as our currently failing build [1].

A temporary workaround could be to have a custom version of jemalloc with
the c++ features disabled
by building with `--disable-cxx'. Alternatively, we could just make use of
jemalloc 4.5.0 for rustc only
until this is all sorted our by upstream.

Attachment: file
L
L
Ludovic Courtès wrote on 4 Dec 2017 10:09
(name . Jelle Licht)(address . jlicht@fsfe.org)
878teirh99.fsf@gnu.org
Hi,

Jelle Licht <jlicht@fsfe.org> skribis:

Toggle quote (28 lines)
> 2017-11-30 23:41 GMT+01:00 Adam Van Ymeren <adam@vany.ca>:
>
>> I haven't had time to dig in to this further, but in case anyone wants
>> to fix rustc-1.16.0, it's broken after the upgrade of jemalloc to 5.0.1.
>>
>> Reverting commit 475b99fa5cf402430aa93a40e406e854ad2ff6e4 which reverts
>> jemalloc back to 4.5.0 causes rustc to build successfully again. It has
>> been broken for some time.
>>
>> https://hydra.gnu.org/job/gnu/master/rustc-1.16.0.x86_64-linux
>>
>>
>>
>>
> It seems that the bundled copy of jemalloc in the rustc repo is currently
> pinned at 4.5.0 partially
> because of this specific issue as well.
>
> I did find an issue on the rust GH repo [0], and it seems this also affects
> the nix-rust project,
> who seem to have the same errors as our currently failing build [1].
>
> A temporary workaround could be to have a custom version of jemalloc with
> the c++ features disabled
> by building with `--disable-cxx'. Alternatively, we could just make use of
> jemalloc 4.5.0 for rustc only
> until this is all sorted our by upstream.

Using a --disable-cxx variant of the latest jemalloc sounds preferable
to me over running an old jemalloc.

How does that sound?

Thanks,
Ludo’.
N
N
Nikolai Merinov wrote on 4 Dec 2017 15:54
Re: [bug#29555] [PATCH] gnu: rust: update rust to 1.22.1 and cargo to 1.23.0
(name . Jelle Licht)(address . jlicht@fsfe.org)
558D9F77-E950-4D77-86A3-4B633C0E2009@member.fsf.org
I added "-lstdc++" to rust standard lib to overcome issue. Which solution is better:
1. change link flags for rust standard library, or
2. create rust-specific jemalloc as suggested in #29522?

4 ??????? 2017 ?. 19:33:31 GMT+05:00, Jelle Licht <jlicht@fsfe.org> ?????:
Toggle quote (17 lines)
>2017-12-03 20:01 GMT+01:00 Nikolai Merinov
><nikolai.merinov@member.fsf.org>:
>
>> Update for a rustc and cargo packages. This update will also fix a
>> build.
>>
>>
>I do not have enough know-how to properly review your patch, but at
>least I
>can verify it seems to work.
>I was able to build rustc and cargo succesfully with your patches, and
>was
>able to build and run a trivial hello world program written in rust.
>When this patch is merged, I think we can also close
>http://lists.gnu.org/archive/html/bug-guix/2017-12/msg00006.html, as it
>will no longer be relevant.

--
Nikolai Merinov
Attachment: file
D
D
Danny Milosavljevic wrote on 4 Dec 2017 17:05
(name . Nikolai Merinov)(address . nikolai.merinov@member.fsf.org)
20171204170506.75f2ce36@scratchpost.org
Hi,

On Mon, 04 Dec 2017 19:54:13 +0500
Nikolai Merinov <nikolai.merinov@member.fsf.org> wrote:

Toggle quote (3 lines)
> I added "-lstdc++" to rust standard lib to overcome issue. Which solution is better:
> 1. change link flags for rust standard library, or

Sounds hacky and I'm not sure why it helps or whether it will keep working.

Toggle quote (2 lines)
> 2. create rust-specific jemalloc as suggested in #29522?

I vote for using a rust-specific jemalloc without the C++ parts (named "jemalloc-without-c++" or something, it just has to pass a flag to "configure"). It's smaller, too. Any downsides?
A
A
Adam Van Ymeren wrote on 4 Dec 2017 17:10
Re: bug#29522: rustc-1.16.0 broken after jemalloc updated to 5.0.1
(name . Ludovic Courtès)(address . ludo@gnu.org)
87d13uxyn1.fsf@vany.ca
ludo@gnu.org (Ludovic Courtès) writes:

Toggle quote (35 lines)
> Hi,
>
> Jelle Licht <jlicht@fsfe.org> skribis:
>
>> 2017-11-30 23:41 GMT+01:00 Adam Van Ymeren <adam@vany.ca>:
>>
>>> I haven't had time to dig in to this further, but in case anyone wants
>>> to fix rustc-1.16.0, it's broken after the upgrade of jemalloc to 5.0.1.
>>>
>>> Reverting commit 475b99fa5cf402430aa93a40e406e854ad2ff6e4 which reverts
>>> jemalloc back to 4.5.0 causes rustc to build successfully again. It has
>>> been broken for some time.
>>>
>>> https://hydra.gnu.org/job/gnu/master/rustc-1.16.0.x86_64-linux
>>>
>>>
>>>
>>>
>> It seems that the bundled copy of jemalloc in the rustc repo is currently
>> pinned at 4.5.0 partially
>> because of this specific issue as well.
>>
>> I did find an issue on the rust GH repo [0], and it seems this also affects
>> the nix-rust project,
>> who seem to have the same errors as our currently failing build [1].
>>
>> A temporary workaround could be to have a custom version of jemalloc with
>> the c++ features disabled
>> by building with `--disable-cxx'. Alternatively, we could just make use of
>> jemalloc 4.5.0 for rustc only
>> until this is all sorted our by upstream.
>
> Using a --disable-cxx variant of the latest jemalloc sounds preferable
> to me over running an old jemalloc.

I feel like if rust is pegged at jemalloc 4.5.0 then that's what we
should be feeding it. The changelog suggestst that jemalloc 5 has some
pretty significant changes, changing rust to use that theoretically lead
to some subtle bugs, I feel like I'd rather wait for upstream to make
the upgrade themselves.

Toggle quote (5 lines)
>
> How does that sound?
>
> Thanks,
> Ludo’.
L
L
Ludovic Courtès wrote on 4 Dec 2017 18:19
(name . Adam Van Ymeren)(address . adam@vany.ca)
878teimmvv.fsf@gnu.org
Adam Van Ymeren <adam@vany.ca> skribis:

Toggle quote (6 lines)
> ludo@gnu.org (Ludovic Courtès) writes:
>
>> Hi,
>>
>> Jelle Licht <jlicht@fsfe.org> skribis:

[...]

Toggle quote (23 lines)
>>> It seems that the bundled copy of jemalloc in the rustc repo is currently
>>> pinned at 4.5.0 partially
>>> because of this specific issue as well.
>>>
>>> I did find an issue on the rust GH repo [0], and it seems this also affects
>>> the nix-rust project,
>>> who seem to have the same errors as our currently failing build [1].
>>>
>>> A temporary workaround could be to have a custom version of jemalloc with
>>> the c++ features disabled
>>> by building with `--disable-cxx'. Alternatively, we could just make use of
>>> jemalloc 4.5.0 for rustc only
>>> until this is all sorted our by upstream.
>>
>> Using a --disable-cxx variant of the latest jemalloc sounds preferable
>> to me over running an old jemalloc.
>
> I feel like if rust is pegged at jemalloc 4.5.0 then that's what we
> should be feeding it. The changelog suggestst that jemalloc 5 has some
> pretty significant changes, changing rust to use that theoretically lead
> to some subtle bugs, I feel like I'd rather wait for upstream to make
> the upgrade themselves.

Right, that makes sense.

In that case, we should reintroduce jemalloc 4.5 and use that in Rust.

Ludo’.
A
A
Adam Van Ymeren wrote on 4 Dec 2017 20:35
(name . Ludovic Courtès)(address . ludo@gnu.org)
878teixp5g.fsf@vany.ca
ludo@gnu.org (Ludovic Courtès) writes:

Toggle quote (37 lines)
> Adam Van Ymeren <adam@vany.ca> skribis:
>
>> ludo@gnu.org (Ludovic Courtès) writes:
>>
>>> Hi,
>>>
>>> Jelle Licht <jlicht@fsfe.org> skribis:
>
> [...]
>
>>>> It seems that the bundled copy of jemalloc in the rustc repo is currently
>>>> pinned at 4.5.0 partially
>>>> because of this specific issue as well.
>>>>
>>>> I did find an issue on the rust GH repo [0], and it seems this also affects
>>>> the nix-rust project,
>>>> who seem to have the same errors as our currently failing build [1].
>>>>
>>>> A temporary workaround could be to have a custom version of jemalloc with
>>>> the c++ features disabled
>>>> by building with `--disable-cxx'. Alternatively, we could just make use of
>>>> jemalloc 4.5.0 for rustc only
>>>> until this is all sorted our by upstream.
>>>
>>> Using a --disable-cxx variant of the latest jemalloc sounds preferable
>>> to me over running an old jemalloc.
>>
>> I feel like if rust is pegged at jemalloc 4.5.0 then that's what we
>> should be feeding it. The changelog suggestst that jemalloc 5 has some
>> pretty significant changes, changing rust to use that theoretically lead
>> to some subtle bugs, I feel like I'd rather wait for upstream to make
>> the upgrade themselves.
>
> Right, that makes sense.
>
> In that case, we should reintroduce jemalloc 4.5 and use that in Rust.

Sounds good, I have a patch that does this and also bumps rust to latest
upstream, but the build is taking forever. Will post once I've built it
successfully.

Toggle quote (2 lines)
>
> Ludo’.
N
N
Nikolai Merinov wrote on 5 Dec 2017 07:10
Re: [bug#29555] [PATCH] gnu: rust: update rust to 1.22.1 and cargo to 1.23.0
(name . Danny Milosavljevic)(address . dannym@scratchpost.org)
87o9ndn1rm.fsf@member.fsf.org
Please find new version of patch: I removed linkage with libstdc++ and added new jemalloc-without-c++
D
D
Danny Milosavljevic wrote on 14 Dec 2017 00:18
(no subject)
(address . control@debbugs.gnu.org)
20171214001837.7fd5ebc7@scratchpost.org
close 29522
?
Your comment

This issue is archived.

To comment on this conversation send an email to 29522@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 29522
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch