Opened 6 years ago

Last modified 6 years ago

#14699 new bug

Jam segfault - hashitem

Reported by: kallisti5 Owned by: bonefish
Priority: normal Milestone: Unscheduled
Component: Build System Version: R1/Development
Keywords: jam Cc:
Blocked By: Blocking:
Platform: All

Description

I see this while running a build using the custom python configure.py tool i'm working on.

I'm sure i'm missing setting a variable somewhere, but nothing should cause jam to segfault :-)

jam from our buildtools. compiled with -g

gef➤  run -q
Starting program: /usr/local/bin/jam -q
Missing separate debuginfos, use: dnf debuginfo-install glibc-2.28-9.fc29.x86_64
Starting build of type regular ... 
AddHaikuImagePackages: package bash not available! 
AddHaikuImagePackages: package bc not available! 
AddHaikuImagePackages: package coreutils not available! 
AddHaikuImagePackages: package curl not available! 
AddHaikuImagePackages: package freetype not available! 
AddHaikuImagePackages: package icu not available! 
AddHaikuImagePackages: package libsolv not available! 
AddHaikuImagePackages: package zlib not available! 
AddHaikuImagePackages: package zstd not available! 
AddHaikuImagePackages: package gcc_syslibs not available! 
/home/kallisti5/Code/haiku/src/add-ons/kernel/bus_managers/config_manager/arch/Jamfile: No such file or directory
/home/kallisti5/Code/haiku/src/add-ons/kernel/bus_managers/isa/arch/Jamfile: No such file or directory
/home/kallisti5/Code/haiku/src/add-ons/kernel/bus_managers/pci/arch/Jamfile: No such file or directory

Program received signal SIGSEGV, Segmentation fault.
0x0000000000404bd3 in hashitem ()
[ Legend: Modified register | Code | Heap | Stack | String ]
──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────[ registers ]────
$rax   : 0x7fffff7ff038      →  0x00007fffff7ff9f0  →  0x000000000331023c  →  0x0000000000000000
$rbx   : 0x7fffff7ff9f0      →  0x000000000331023c  →  0x0000000000000000
$rcx   : 0x3               
$rdx   : 0x1               
$rsp   : 0x7fffff7ff000      →  0x0000000000000000
$rbp   : 0x0               
$rsi   : 0x7fffff7ff030      →  0x00007fffff7ff038  →  0x00007fffff7ff9f0  →  0x000000000331023c  →  0x0000000000000000
$rdi   : 0x420570            →  0x00007fff000119eb
$rip   : 0x404bd3            →  <hashitem+9> push rbx
$r8    : 0x0               
$r9    : 0x7fffff803820      →  0x0000000000000001
$r10   : 0x420010            →  0x0000000000000003
$r11   : 0x0               
$r12   : 0x0               
$r13   : 0x34343a0           →  0x0000000003436c40  →  0x0000000003436ae0  →  0x0000000003436b40  →  0x0000000003436b60  →  0x0000000003434e80  →  0x0000000003436b20  →  0x0000000003436b80
$r14   : 0x7fffff7ff9f4      →  0xff8003a000000000
$r15   : 0x0               
$eflags: [zero carry parity adjust sign trap INTERRUPT direction overflow RESUME virtualx86 identification]
$ss: 0x002b  $fs: 0x0000  $ds: 0x0000  $gs: 0x0000  $es: 0x0000  $cs: 0x0033  
──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────[ stack ]────
0x00007fffff7ff000│+0x00: 0x0000000000000000	 ← $rsp
0x00007fffff7ff008│+0x08: 0x0000000000000000
0x00007fffff7ff010│+0x10: 0x00000000034343a0  →  0x0000000003436c40  →  0x0000000003436ae0  →  0x0000000003436b40  →  0x0000000003436b60  →  0x0000000003434e80  →  0x0000000003436b20
0x00007fffff7ff018│+0x18: 0x00007fffff7ff9f4  →  0xff8003a000000000
0x00007fffff7ff020│+0x20: 0x0000000000000000
0x00007fffff7ff028│+0x28: 0x00000000004064ed  →  <newstr+59> test eax, eax
0x00007fffff7ff030│+0x30: 0x00007fffff7ff038  →  0x00007fffff7ff9f0  →  0x000000000331023c  →  0x0000000000000000	 ← $rsi
0x00007fffff7ff038│+0x38: 0x00007fffff7ff9f0  →  0x000000000331023c  →  0x0000000000000000	 ← $rax
───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────[ code:i386:x86-64 ]────
     0x404bce <hashitem+4>     push   r13
     0x404bd0 <hashitem+6>     push   r12
     0x404bd2 <hashitem+8>     push   rbp
 →   0x404bd3 <hashitem+9>     push   rbx
     0x404bd4 <hashitem+10>    sub    rsp, 0x18
     0x404bd8 <hashitem+14>    mov    rbx, rdi
     0x404bdb <hashitem+17>    mov    r12, rsi
     0x404bde <hashitem+20>    mov    r14d, edx
     0x404be1 <hashitem+23>    mov    rax, QWORD PTR [rsi]
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────[ threads ]────
[#0] Id 1, Name: "jam", stopped, reason: SIGSEGV
──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────[ trace ]────
[#0] 0x404bd3 → Name: hashitem()
[#1] 0x4064ed → Name: newstr()
[#2] 0x404ffd → Name: list_new()
[#3] 0x40b369 → Name: var_expand()
[#4] 0x40b42a → Name: var_expand()
[#5] 0x40b42a → Name: var_expand()
[#6] 0x40b42a → Name: var_expand()
[#7] 0x40c4d4 → Name: compile_list()
[#8] 0x40c066 → Name: compile_append()
[#9] 0x40c0a4 → Name: compile_break()
───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
gef➤  

Change History (1)

comment:1 by kallisti5, 6 years ago

Reproduction steps:

  • from haiku/generated.test
  • ../3rdparty/kallisti5/configure.py --target-arch arm --use-clang
  • run jam -q
  • segfault
Note: See TracTickets for help on using tickets.