Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions builder/bdwgc.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,10 @@ var BoehmGC = Library{
// Use a minimal environment.
"-DNO_MSGBOX_ON_ERROR", // don't call MessageBoxA on Windows
"-DDONT_USE_ATEXIT",
"-DNO_GETENV",
"-DNO_GETENV", // smaller binary, more predictable configuration
"-DNO_CLOCK", // don't use system clock
"-DNO_DEBUGGING", // reduce code size
"-DGC_NO_FINALIZATION", // finalization is not used at the moment

// Special flag to work around the lack of __data_start in ld.lld.
// TODO: try to fix this in LLVM/lld directly so we don't have to
Expand All @@ -39,6 +42,8 @@ var BoehmGC = Library{

// Do not scan the stack. We have our own mechanism to do this.
"-DSTACK_NOT_SCANNED",
"-DNO_PROC_STAT", // we scan the stack manually (don't read /proc/self/stat on Linux)
"-DSTACKBOTTOM=0", // dummy value, we scan the stack manually

// Assertions can be enabled while debugging GC issues.
//"-DGC_ASSERTIONS",
Expand All @@ -63,15 +68,13 @@ var BoehmGC = Library{
"blacklst.c",
"dbg_mlc.c",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With the latest bdwgc master: dbg_mlc.c is not needed unless you use GC_debug_* API.

"dyn_load.c",
"finalize.c",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think there's no need to exclude finalize.c as it should compile to zero size if GC_NO_FINALIZATION is defined.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct, but there's no reason to include it either 🤷

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you update to latest bdwgc/master, remove obj_map.c from the list below.

"headers.c",
"mach_dep.c",
"malloc.c",
"mark.c",
"mark_rts.c",
"misc.c",
"new_hblk.c",
"obj_map.c",
"os_dep.c",
"reclaim.c",
}
Expand Down
2 changes: 1 addition & 1 deletion lib/bdwgc
Submodule bdwgc updated from 1166f1 to 7577ca