Commit graph

37 commits

Author SHA1 Message Date
kbkpbot
fa904c495e
builtin,cgen,markused: add struct @[aligned] support for structs allocated on the heap too (#24886) 2025-07-13 20:56:28 +03:00
Delyan Angelov
b305fa5743 docs: cleanup doc comments of public APIs in builtin (found by find_doc_comments_with_no_dots.v) 2025-07-02 16:33:24 +03:00
Laurent Cheylus
364f9ebda3
builtin: use local static libgc for FreeBSD with tcc (fix #24710) (fix #24683) (#24720) 2025-06-15 09:35:53 +03:00
kbkpbot
89305aabe7
builtin: fix mix prod and debug ucrt lib (#24498) 2025-05-21 06:07:56 +03:00
Felipe Pena
f291ed8541
builtin: make public the FnGC_WarnCB alias (#23633) 2025-02-02 13:45:28 +02:00
Delyan Angelov
8b36856692
builtin: support -d no_gc_threads for turning off passing -DGC_THREADS=1 while compiling the GC library 2024-10-23 16:10:19 +03:00
Meng Zhuo
b1c9941065
builtin: enable GC lib on rv64 build (#22319) 2024-09-26 10:58:33 +03:00
Laurent Cheylus
c3b55a68a5
builtin: fix compilation with tcc on OpenBSD using libgc (#22234) 2024-09-16 17:02:30 +03:00
Delyan Angelov
6834ccb2d5 builtin,thirdparty: fix compilation of libgc with -cc msvc -gc boehm (thanks to @Ekopalypse) 2024-08-22 18:43:45 +03:00
Delyan Angelov
bbbb86442d
builtin: support -d use_bundled_libgc to make it easier to debug/upgrade reliably libgc cloned from ivmai/bdwgc (#21869) 2024-07-15 04:34:14 +03:00
yuyi
209063ffd0
fmt: implement wrapping function's super long arguments (fix #15545, fix #21643) (#21782) 2024-07-02 23:10:00 +03:00
Joe Conigliaro
a1c5c6c8f2
builtin: add missing return type to fn signature for C.GC_get_stack_base 2024-03-14 00:08:39 +11:00
Joe C
f315676882
coroutines: manually create photon vcpu's & add functions to set photon log output (#21012) 2024-03-14 00:00:42 +11:00
Delyan Angelov
a373bee98b
builtin: expose gc_disable(), gc_enable(), gc_is_enabled(), in addition to the existing gc_collect() (#21002) 2024-03-12 17:03:33 +02:00
Delyan Angelov
8793aebe65
builtin: add gc_collect/0, gc_get_warn_proc/0, gc_set_warn_proc/1. Use them to turn off GC warnings by default. (#20788) 2024-02-11 16:07:36 +02:00
Joe C
212adfab92
builtin,coroutines,cgen: fix using coroutines with boehm GC, by using a stack pointer corrector (#20771) 2024-02-10 15:20:11 +02:00
zeozeozeo
99579acaf2
builtin: link to user32 to fix boehm GC compilation on Windows with clang released from the LLVM project (fix #20724) (#20767) 2024-02-10 09:00:08 +02:00
Joe C
f79dd79242
coroutines: fix segfaults with GC (part 1) (#20549) 2024-01-27 23:27:38 +02:00
Delyan Angelov
9c7e3707b6
builtin: use #pkgconfig bdw-gc-threaded where available, instead of #pkgconfig bdw-gc (on FreeBSD) 2024-01-18 07:31:40 +02:00
Bakul Shah
63ba05b5ca
builtin: pass USE_MMAP when compiling the GC library on freebsd, when tcc is not used (#20006) 2023-11-27 07:35:17 +02:00
Joe Conigliaro
9604a3f491
coroutines: get photonlib/coroutines working with GC 2023-10-09 12:10:19 +11:00
Kim Shrier
621cb6dde0
builtin: use libgc-threaded on FreeBSD, to get the threaded version of libgc (#19294) 2023-09-07 12:26:46 +03:00
Felipe Pena
5008515b03
builtin: heap memory usage api (#18103) 2023-05-03 20:33:52 +03:00
spaceface
201598e68a
builtin: fix gc.o compilation on macos (#15832) 2022-09-21 12:19:02 +03:00
Emily Hudson
90d9b200f9
gc: fix msvc not using libatomic_ops (#15418) 2022-08-14 13:16:52 +03:00
Davide Beatrici
c9a5896468
bultin: always enable GC_THREADS, even with -d dynamic_boehm, otherwise multithread operation is unsafe (#15275)
According to upstream documentation, only GC_WIN32_THREADS is explicit.

This PR fixes a random memory corruption(s) with "-d dynamic_boehm" on OpenMandriva.
https://file-store.openmandriva.org/api/v1/file_stores/1679adc04d8e765d5cea302c15789f9aaa188428.log
```
DEBUG: + VFLAGS='-prod -d dynamic_boehm'
DEBUG: + /usr/bin/clang -Os -fomit-frame-pointer -g3 -gdwarf-4 -Wstrict-aliasing=2 -pipe -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2 -fstack-protector-all --param=ssp-buffer-size=4 -m64 -mtune=generic -flto -std=gnu99 -w -o tmp_1 v.c -lm -lpthread -Os -fomit-frame-pointer -g3 -gdwarf-4 -Wstrict-aliasing=2 -pipe -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2 -fstack-protector-all --param=ssp-buffer-size=4 -m64 -mtune=generic -flto -Wl,-O2 -Wl,--no-undefined -flto
DEBUG: + ./tmp_1 -no-parallel -o tmp_2 -prod -d dynamic_boehm cmd/v
DEBUG: + ./tmp_2 -o v -prod -d dynamic_boehm cmd/v
DEBUG: /var/tmp/rpm-tmp.mcjmqc: line 52:   644 Bus error               (core dumped) ./v build-tools
```
2022-07-30 14:59:12 +03:00
Delyan Angelov
473d26ce47 builtin: enforce linking to libgc.a with -prod on macos 2022-06-20 21:29:27 +03:00
spaceface
4ed9780b80
all: enable -gc boehm by default (#14577) 2022-06-09 00:44:29 +03:00
Delyan Angelov
58ebc0680e
builtin: fix sporadic linking failures on v -cc gcc -gc boehm examples/hello_world.v 2022-05-30 15:17:01 +03:00
spaceface
ba859c584b
builtin: add static GC support on Windows with TCC (#14497) 2022-05-22 21:25:46 +03:00
Delyan Angelov
0e5c1cee48
builtin: improve musl/Alpine support (define weak backtrace/backtrace_symbols/backtrace_symbols_fd symbols) (#14250) 2022-05-03 09:17:53 +03:00
lemon
960225f7a7
builtin: fix -cc gcc -gc boehm on linux and macos (#14115) 2022-04-21 00:12:17 +03:00
spaceface
775c4c34b5
builtin: compile the gc statically by default (#14063) 2022-04-18 10:50:21 +03:00
Ekopalypse
cb684b5c64
builtin: allow msvc users to link against a custom compiled Boehm library (#13133) 2022-01-11 15:23:21 +02:00
Bakul Shah
cc2847f6ff
builtin: fix compilation with -gc boehm on some FreeBSD versions (#12289) 2021-10-25 10:24:08 +03:00
Enzo
e3b65092d6
parser: deprecate size_t (#11443) 2021-09-08 13:09:32 +03:00
Delyan Angelov
47884dfd1f
builtin: move C. calls to .c.v files (#11164) 2021-08-12 21:46:38 +03:00
Renamed from vlib/builtin/builtin_d_gcboehm.v (Browse further)