jao has quit [Read error: Connection reset by peer]
porchetta has quit [Ping timeout: 246 seconds]
TakinOver has joined #ocaml
porchetta has joined #ocaml
jmagnusj has joined #ocaml
jao has joined #ocaml
olle has quit [Ping timeout: 246 seconds]
olle has joined #ocaml
dborisog has joined #ocaml
wingsorc has joined #ocaml
wingsorc has quit [Quit: Leaving]
mfp has quit [Ping timeout: 264 seconds]
lyxia has quit [Ping timeout: 244 seconds]
lyxia has joined #ocaml
objmagic has joined #ocaml
waleee-cl has quit [Quit: Connection closed for inactivity]
objmagic has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
mbuf has joined #ocaml
jao has quit [Ping timeout: 265 seconds]
objmagic has joined #ocaml
objmagic has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Haudegen has joined #ocaml
FreeBirdLjj has joined #ocaml
FreeBirdLjj has quit [Ping timeout: 260 seconds]
nullcone has joined #ocaml
sugarwren has joined #ocaml
chripell has joined #ocaml
olle__ has joined #ocaml
Anarchos has joined #ocaml
andreas303 has quit [Ping timeout: 240 seconds]
ryxai has joined #ocaml
Anarchos2 has joined #ocaml
Anarchos has quit [Ping timeout: 260 seconds]
andreas303 has joined #ocaml
def has quit [Remote host closed the connection]
def has joined #ocaml
def has left #ocaml [#ocaml]
def has joined #ocaml
ryxai has quit [Read error: Connection reset by peer]
mfp has joined #ocaml
kvda has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
nullcone has quit [Quit: Connection closed for inactivity]
pigeonv has joined #ocaml
Haudegen has quit [Quit: Bin weg.]
zolk3ri has joined #ocaml
Haudegen has joined #ocaml
corecode has joined #ocaml
<corecode>
hi
<corecode>
i think i found a bug in camlzip; campzip_new_stream in zlibstubs.c allocates a a new custom, but zlib expects its location not to change
<corecode>
am i diagnosing this right?
sz0 has quit [Ping timeout: 260 seconds]
terrorjack has quit [Ping timeout: 260 seconds]
<corecode>
or not? basically i'm observing that the zlib z_streamp pointer changes during runtime
sz0 has joined #ocaml
terrorjack has joined #ocaml
pigeonv has quit [Ping timeout: 265 seconds]
Anarchos2 has quit [Quit: Vision[0.10.3]: i've been blurred!]
<flux1>
corecode: does it crash?
<flux1>
I don't know the code, but can it also be the case that the location of the pointer changes, but the pointee's location stays the same
<flux1>
granted OCaml bindings can be tricky, but camlzip is an older one, I'd think it has gotten it right..
<corecode>
correction: it seems to allocate only a custom for the pointer to a struct, then a caml_stat_alloc() for the struct itself
<corecode>
yea it looks right
<corecode>
but i can see the struct address change
<corecode>
and then zlib is unhappy
<flux1>
well, that's not good :)
<corecode>
the question is, why does the address change
<corecode>
i.e. pointer itself
<corecode>
surprisingly the contents of the struct don't change
<corecode>
so something copied them
<flux1>
compacting garbage collection
<corecode>
yea that was my thought
<corecode>
are blocks allocated by caml_stat_alloc() allowed to be moved?
<flux1>
it should either register the address as a GC root, or add a layer of indirection. amazing camlzip didn't get it right.
<corecode>
i can't find documentation for that function
<corecode>
it looks correct, i didn't read it right first
<flux1>
it seems caml_tat_alloc returns a normal memory block, so yes, it can move
<corecode>
how would i find this information?
<flux1>
hmm
<flux1>
I'm reading runtime/caml/memory.h from the OCaml source
<corecode>
without asking you, i mean
<corecode>
ok
<flux1>
"[caml_stat_*] functions below provide an interface to the static memory manager built into the runtime, which can be used for managing static (that is, non-moving) blocks of heap memory."
<flux1>
I've never used them but it sounds like they shouldn't move :)
<flux1>
maybe it's an OCaml bug?
<corecode>
i hope not :)
<flux1>
it could be a regression
<flux1>
which OCaml version?
<corecode>
4.10.0
<flux1>
so a very recent one. with memory management changes perhaps..