Opened 14 years ago
Closed 14 years ago
#6245 closed bug (invalid)
[patch] [clang] kernel crash at hash_insert()
Reported by: | kaliber | Owned by: | axeld |
---|---|---|---|
Priority: | normal | Milestone: | R1 |
Component: | System/Kernel | Version: | R1/Development |
Keywords: | clang | Cc: | andreasf |
Blocked By: | Blocking: | ||
Platform: | All |
Description
Kernel built with clang crashes at hash_insert() in main2 thread.
Attachments (1)
Change History (8)
by , 14 years ago
Attachment: | offsetof.patch added |
---|
comment:1 by , 14 years ago
patch: | 0 → 1 |
---|
follow-up: 4 comment:3 by , 14 years ago
Cc: | added |
---|
Any explanation why it crashes and why this change fixes it?
Patch itself looks okay, but it might be working around a bug in clang.
follow-up: 5 comment:4 by , 14 years ago
Replying to andreasf:
Any explanation why it crashes and why this change fixes it? Patch itself looks okay, but it might be working around a bug in clang.
((addr_t)&vnode->all_next - (addr_t)vnode) was a negative number somehow in this case. I'm not sure how it's possible.
comment:5 by , 14 years ago
Replying to kaliber:
Replying to andreasf:
Any explanation why it crashes and why this change fixes it? Patch itself looks okay, but it might be working around a bug in clang.
((addr_t)&vnode->all_next - (addr_t)vnode) was a negative number somehow in this case. I'm not sure how it's possible.
That's not exactly inspiring trust in the compiler. BTW, the long-term goal is to replace the C hash implementation by OpenHashTable.
comment:6 by , 14 years ago
I tried to reproduce this bug. I rebuilt haiku with latest clang and looks like the problem has gone. I propose to close this bug and apply this patch just in case.
comment:8 by , 14 years ago
Resolution: | → invalid |
---|---|
Status: | new → closed |
patch