public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug malloc/30301] New: "memalign: Support scanning for aligned chunks" causes regression in game "factorio"
@ 2023-04-01 12:31 manuel.lauss at gmail dot com
  2023-04-02 18:42 ` [Bug malloc/30301] " sam at gentoo dot org
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: manuel.lauss at gmail dot com @ 2023-04-01 12:31 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=30301

            Bug ID: 30301
           Summary: "memalign: Support scanning for aligned chunks" causes
                    regression in game "factorio"
           Product: glibc
           Version: 2.38
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: malloc
          Assignee: unassigned at sourceware dot org
          Reporter: manuel.lauss at gmail dot com
  Target Milestone: ---

Commit 24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f ("memalign: Support scanning
for aligned chunks.")  causes the game "factorio" (demo here:
https://factorio.com/get-download/1.1.76/demo/linux64) to abort when loading a
saved game:

Fatal glibc error: malloc.c:3617 (_mid_memalign): assertion failed: !p ||
chunk_is_mmapped (mem2chunk (p)) || ar_ptr == arena_for_chunk (mem2chunk (p))

Reverting 24cdd6c71d on top of current git head fixes the issue for me.
My system otherwise boots up and runs just fine, so this commit might expose
a bug in the factorio codebase. I'll report it to them as well.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug malloc/30301] "memalign: Support scanning for aligned chunks" causes regression in game "factorio"
  2023-04-01 12:31 [Bug malloc/30301] New: "memalign: Support scanning for aligned chunks" causes regression in game "factorio" manuel.lauss at gmail dot com
@ 2023-04-02 18:42 ` sam at gentoo dot org
  2023-04-02 18:42 ` [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: !p || chunk_is_mmapped (mem2chunk (p)) || ar_ptr == arena_for_chunk (mem2chun sam at gentoo dot org
                   ` (9 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: sam at gentoo dot org @ 2023-04-02 18:42 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=30301

Sam James <sam at gentoo dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dj at redhat dot com,
                   |                            |sam at gentoo dot org

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: !p || chunk_is_mmapped (mem2chunk (p)) || ar_ptr == arena_for_chunk (mem2chun
  2023-04-01 12:31 [Bug malloc/30301] New: "memalign: Support scanning for aligned chunks" causes regression in game "factorio" manuel.lauss at gmail dot com
  2023-04-02 18:42 ` [Bug malloc/30301] " sam at gentoo dot org
@ 2023-04-02 18:42 ` sam at gentoo dot org
  2023-04-02 18:42 ` [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: ...) sam at gentoo dot org
                   ` (8 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: sam at gentoo dot org @ 2023-04-02 18:42 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=30301

Sam James <sam at gentoo dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|"memalign: Support scanning |"memalign: Support scanning
                   |for aligned chunks" causes  |for aligned chunks"
                   |regression in game          |(24cdd6c71debfd10a9f7cb217f
                   |"factorio"                  |e2a2c4c486ed6f) causes
                   |                            |regression in game
                   |                            |"factorio" (malloc.c:3617
                   |                            |(_mid_memalign): assertion
                   |                            |failed: !p ||
                   |                            |chunk_is_mmapped (mem2chunk
                   |                            |(p)) || ar_ptr ==
                   |                            |arena_for_chunk (mem2chun

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: ...)
  2023-04-01 12:31 [Bug malloc/30301] New: "memalign: Support scanning for aligned chunks" causes regression in game "factorio" manuel.lauss at gmail dot com
  2023-04-02 18:42 ` [Bug malloc/30301] " sam at gentoo dot org
  2023-04-02 18:42 ` [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: !p || chunk_is_mmapped (mem2chunk (p)) || ar_ptr == arena_for_chunk (mem2chun sam at gentoo dot org
@ 2023-04-02 18:42 ` sam at gentoo dot org
  2023-04-03 13:06 ` fweimer at redhat dot com
                   ` (7 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: sam at gentoo dot org @ 2023-04-02 18:42 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=30301

Sam James <sam at gentoo dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|"memalign: Support scanning |"memalign: Support scanning
                   |for aligned chunks"         |for aligned chunks"
                   |(24cdd6c71debfd10a9f7cb217f |(24cdd6c71debfd10a9f7cb217f
                   |e2a2c4c486ed6f) causes      |e2a2c4c486ed6f) causes
                   |regression in game          |regression in game
                   |"factorio" (malloc.c:3617   |"factorio" (malloc.c:3617
                   |(_mid_memalign): assertion  |(_mid_memalign): assertion
                   |failed: !p ||               |failed: ...)
                   |chunk_is_mmapped (mem2chunk |
                   |(p)) || ar_ptr ==           |
                   |arena_for_chunk (mem2chun   |

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: ...)
  2023-04-01 12:31 [Bug malloc/30301] New: "memalign: Support scanning for aligned chunks" causes regression in game "factorio" manuel.lauss at gmail dot com
                   ` (2 preceding siblings ...)
  2023-04-02 18:42 ` [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: ...) sam at gentoo dot org
@ 2023-04-03 13:06 ` fweimer at redhat dot com
  2023-04-03 18:50 ` crrodriguez at opensuse dot org
                   ` (6 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: fweimer at redhat dot com @ 2023-04-03 13:06 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=30301

Florian Weimer <fweimer at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |fweimer at redhat dot com

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: ...)
  2023-04-01 12:31 [Bug malloc/30301] New: "memalign: Support scanning for aligned chunks" causes regression in game "factorio" manuel.lauss at gmail dot com
                   ` (3 preceding siblings ...)
  2023-04-03 13:06 ` fweimer at redhat dot com
@ 2023-04-03 18:50 ` crrodriguez at opensuse dot org
  2023-04-03 19:01 ` dj at redhat dot com
                   ` (5 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: crrodriguez at opensuse dot org @ 2023-04-03 18:50 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=30301

Cristian Rodríguez <crrodriguez at opensuse dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |crrodriguez at opensuse dot org

--- Comment #1 from Cristian Rodríguez <crrodriguez at opensuse dot org> ---
- the rustc compiler crashes with the same message.
- any rust app using the regex library does too
- spec 2017 benchmark tests crash

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: ...)
  2023-04-01 12:31 [Bug malloc/30301] New: "memalign: Support scanning for aligned chunks" causes regression in game "factorio" manuel.lauss at gmail dot com
                   ` (4 preceding siblings ...)
  2023-04-03 18:50 ` crrodriguez at opensuse dot org
@ 2023-04-03 19:01 ` dj at redhat dot com
  2023-04-10 18:36 ` manuel.lauss at gmail dot com
                   ` (4 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: dj at redhat dot com @ 2023-04-03 19:01 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=30301

--- Comment #2 from dj at redhat dot com <dj at redhat dot com> ---
I reproduced this locally :-)

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: ...)
  2023-04-01 12:31 [Bug malloc/30301] New: "memalign: Support scanning for aligned chunks" causes regression in game "factorio" manuel.lauss at gmail dot com
                   ` (5 preceding siblings ...)
  2023-04-03 19:01 ` dj at redhat dot com
@ 2023-04-10 18:36 ` manuel.lauss at gmail dot com
  2023-04-11  6:56 ` manuel.lauss at gmail dot com
                   ` (3 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: manuel.lauss at gmail dot com @ 2023-04-10 18:36 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=30301

--- Comment #3 from Manuel Lauss <manuel.lauss at gmail dot com> ---
DJ's latest patch does fix the issue for me.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: ...)
  2023-04-01 12:31 [Bug malloc/30301] New: "memalign: Support scanning for aligned chunks" causes regression in game "factorio" manuel.lauss at gmail dot com
                   ` (6 preceding siblings ...)
  2023-04-10 18:36 ` manuel.lauss at gmail dot com
@ 2023-04-11  6:56 ` manuel.lauss at gmail dot com
  2023-04-11  8:04 ` manuel.lauss at gmail dot com
                   ` (2 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: manuel.lauss at gmail dot com @ 2023-04-11  6:56 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=30301

--- Comment #4 from Manuel Lauss <manuel.lauss at gmail dot com> ---
(In reply to Manuel Lauss from comment #3)
> DJ's latest patch does fix the issue for me.

Ok I have to take that back:  With DJ's fix applied on top of git head,
Factorio now works, but mpv/ffmpeg now throw this error on any video file:
(ffmpeg-5.1.2, apologies for the missing symbol names, but it should illustrate
the issue):

#0  0x00007ffff5d53bfc in  () at /usr/lib64/libc.so.6
#1  0x00007ffff5d03572 in raise () at /usr/lib64/libc.so.6
#2  0x00007ffff5cec49f in abort () at /usr/lib64/libc.so.6
#3  0x00007ffff5ced3a4 in  () at /usr/lib64/libc.so.6
#4  0x00007ffff5cfbba3 in  () at /usr/lib64/libc.so.6
#5  0x00007ffff5d61b40 in  () at /usr/lib64/libc.so.6
#6  0x00007ffff5d62102 in  () at /usr/lib64/libc.so.6
#7  0x00007ffff5d6395d in posix_memalign () at /usr/lib64/libc.so.6
#8  0x00007ffff6663f0f in av_malloc () at /usr/lib64/libavutil.so.57
#9  0x00007ffff71490fa in  () at /usr/lib64/libavcodec.so.59
#10 0x00007ffff7141d2f in  () at /usr/lib64/libavcodec.so.59
#11 0x00007ffff7141ef8 in  () at /usr/lib64/libavcodec.so.59
#12 0x00007ffff714cde6 in  () at /usr/lib64/libavcodec.so.59
#13 0x00007ffff6e9cb6c in  () at /usr/lib64/libavcodec.so.59
#14 0x00007ffff6eb9a04 in  () at /usr/lib64/libavcodec.so.59
#15 0x00007ffff6f7d599 in avcodec_open2 () at /usr/lib64/libavcodec.so.59

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: ...)
  2023-04-01 12:31 [Bug malloc/30301] New: "memalign: Support scanning for aligned chunks" causes regression in game "factorio" manuel.lauss at gmail dot com
                   ` (7 preceding siblings ...)
  2023-04-11  6:56 ` manuel.lauss at gmail dot com
@ 2023-04-11  8:04 ` manuel.lauss at gmail dot com
  2023-04-12  6:42 ` manuel.lauss at gmail dot com
  2023-04-20 20:12 ` manuel.lauss at gmail dot com
  10 siblings, 0 replies; 12+ messages in thread
From: manuel.lauss at gmail dot com @ 2023-04-11  8:04 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=30301

--- Comment #5 from Manuel Lauss <manuel.lauss at gmail dot com> ---
(In reply to Manuel Lauss from comment #4)
> (In reply to Manuel Lauss from comment #3)
> > DJ's latest patch does fix the issue for me.
> 
> Ok I have to take that back:  With DJ's fix applied on top of git head,
> Factorio now works, but mpv/ffmpeg now throw this error on any video file:
> (ffmpeg-5.1.2, apologies for the missing symbol names, but it should
> illustrate the issue):
> 
> #0  0x00007ffff5d53bfc in  () at /usr/lib64/libc.so.6
> #1  0x00007ffff5d03572 in raise () at /usr/lib64/libc.so.6
> #2  0x00007ffff5cec49f in abort () at /usr/lib64/libc.so.6
> #3  0x00007ffff5ced3a4 in  () at /usr/lib64/libc.so.6
> #4  0x00007ffff5cfbba3 in  () at /usr/lib64/libc.so.6
> #5  0x00007ffff5d61b40 in  () at /usr/lib64/libc.so.6
> #6  0x00007ffff5d62102 in  () at /usr/lib64/libc.so.6
> #7  0x00007ffff5d6395d in posix_memalign () at /usr/lib64/libc.so.6
> #8  0x00007ffff6663f0f in av_malloc () at /usr/lib64/libavutil.so.57
> #9  0x00007ffff71490fa in  () at /usr/lib64/libavcodec.so.59
> #10 0x00007ffff7141d2f in  () at /usr/lib64/libavcodec.so.59
> #11 0x00007ffff7141ef8 in  () at /usr/lib64/libavcodec.so.59
> #12 0x00007ffff714cde6 in  () at /usr/lib64/libavcodec.so.59
> #13 0x00007ffff6e9cb6c in  () at /usr/lib64/libavcodec.so.59
> #14 0x00007ffff6eb9a04 in  () at /usr/lib64/libavcodec.so.59
> #15 0x00007ffff6f7d599 in avcodec_open2 () at /usr/lib64/libavcodec.so.59

Fatal glibc error: malloc.c:5197 (_int_memalign): assertion failed: newsize >=
nb && (((unsigned long) (chunk2mem (p))) % alignment) == 0

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: ...)
  2023-04-01 12:31 [Bug malloc/30301] New: "memalign: Support scanning for aligned chunks" causes regression in game "factorio" manuel.lauss at gmail dot com
                   ` (8 preceding siblings ...)
  2023-04-11  8:04 ` manuel.lauss at gmail dot com
@ 2023-04-12  6:42 ` manuel.lauss at gmail dot com
  2023-04-20 20:12 ` manuel.lauss at gmail dot com
  10 siblings, 0 replies; 12+ messages in thread
From: manuel.lauss at gmail dot com @ 2023-04-12  6:42 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=30301

--- Comment #6 from Manuel Lauss <manuel.lauss at gmail dot com> ---
With DJ's v3 patch I could not find any more failing packages.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: ...)
  2023-04-01 12:31 [Bug malloc/30301] New: "memalign: Support scanning for aligned chunks" causes regression in game "factorio" manuel.lauss at gmail dot com
                   ` (9 preceding siblings ...)
  2023-04-12  6:42 ` manuel.lauss at gmail dot com
@ 2023-04-20 20:12 ` manuel.lauss at gmail dot com
  10 siblings, 0 replies; 12+ messages in thread
From: manuel.lauss at gmail dot com @ 2023-04-20 20:12 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=30301

Manuel Lauss <manuel.lauss at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
             Status|UNCONFIRMED                 |RESOLVED

--- Comment #7 from Manuel Lauss <manuel.lauss at gmail dot com> ---
Cannot reproduce any issues on latest -master.  Thus closing as fixed.  Thanks
for your time!

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2023-04-20 20:12 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-04-01 12:31 [Bug malloc/30301] New: "memalign: Support scanning for aligned chunks" causes regression in game "factorio" manuel.lauss at gmail dot com
2023-04-02 18:42 ` [Bug malloc/30301] " sam at gentoo dot org
2023-04-02 18:42 ` [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: !p || chunk_is_mmapped (mem2chunk (p)) || ar_ptr == arena_for_chunk (mem2chun sam at gentoo dot org
2023-04-02 18:42 ` [Bug malloc/30301] "memalign: Support scanning for aligned chunks" (24cdd6c71debfd10a9f7cb217fe2a2c4c486ed6f) causes regression in game "factorio" (malloc.c:3617 (_mid_memalign): assertion failed: ...) sam at gentoo dot org
2023-04-03 13:06 ` fweimer at redhat dot com
2023-04-03 18:50 ` crrodriguez at opensuse dot org
2023-04-03 19:01 ` dj at redhat dot com
2023-04-10 18:36 ` manuel.lauss at gmail dot com
2023-04-11  6:56 ` manuel.lauss at gmail dot com
2023-04-11  8:04 ` manuel.lauss at gmail dot com
2023-04-12  6:42 ` manuel.lauss at gmail dot com
2023-04-20 20:12 ` manuel.lauss at gmail dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).