<adrien>
does anyone know the granularity of Unix.gettimeofday? it's most probably implementation-dependant; I'm running on recent hardware with a recent linux kernel and glibc
ygrek has quit [Remote host closed the connection]
<adrien>
(I'm currently trying to see what clock_getres says but there is no guarantee that both have the same granularity)
ygrek has joined #ocaml
ttamttam has joined #ocaml
<adrien>
with a C and a cold CPU cache, I get around 500ns for delta between two clock_gettime(CLOCK_REALTIME, ...); and with a hot cache: down to 130ns
<adrien>
and for Unix.gettimeofday: granularity is 1µs or less and precision is 1µs since the C gettimeofday function only gives microseconds
<adrien>
and btw, there is /proc/timer_list on linux to get infos about the available timers and their use
Submarine has joined #ocaml
fantasti` has joined #ocaml
fantasticsid has quit [Remote host closed the connection]
<adrien>
thelema: I told someone "use odb" and then found myself unable to link at what odb is
<adrien>
thelema: but the forge page is not too bad
<adrien>
probably needs some more explanation but only a few more words I think
<thelema>
orbitz: yes, hashtables are based on arrays - an array of linked lists
<thelema>
adrien: I think I can make changes to the website too, so let me know if you have any specifics.
<adrien>
thelema: sure; I'll look at how it can be changed a bit later today or tomorrow
letrec has quit [Ping timeout: 252 seconds]
<adrien>
been building stuff the whole day; mostly C++ stuff, and usually dirty
EmmanuelOga has joined #ocaml
sebz has quit [Quit: Computer has gone to sleep.]
<adrien>
C++ is probably the language that best reminds me why I like OCaml
<adrien>
on the other hand, the slow compiles give enough time to go out, buy food, clean the dishes, ...
<thelema>
:)
<Drakken>
thelema where on github do you want that batbench plot?
ftrvxmtrx has quit [Ping timeout: 268 seconds]
ftrvxmtrx has joined #ocaml
<orbitz>
thelema: Some way to easily investigate the heap of an ocaml app would be great. Know of how bad this would be to implement/anyone doing this without patchingthe ocmpiler?
<orbitz>
This experience has taught me, even though I dislike the language, Java has really nice tools for understanding yoru application
sebz has joined #ocaml
<adrien>
as far as I'm concerned, I wouldn't mind having to have a second ocaml installation on disk with everything for profiling, no matter how slow it is
sebz has quit [Ping timeout: 244 seconds]
<orbitz>
Same
<orbitz>
Even if I had to switch to bytecode to find this memory leak, that would be ok
<orbitz>
But I'd prefer something that insruments the bytecode rather than modifies the compiler, since bytecode changes less often than the compiler code
lamawithonel has quit []
<orbitz>
ANyone know the internals enough to think of what would be needed for somethign like dumping the heap of a runnign program and navigating it (knowing the type of objects)?
<adrien>
automatic instrumentation of data structures would have helped in your case I think
<adrien>
and that's doable afaik
* adrien
gets ready for another 30-minutes recompile of Ogre3D
<orbitz>
Yes, in Java-land I would have opened up Yourkit, taken a heap dump of my app, saw that I had 10 trillion strings, foudn which container they were referenced from, and known immediatly it was this islly hashtbl
<orbitz>
I'm not saying I want to use Java, of coures, just saying a similar workflow would probably be great for Ocaml, more great than debating if we sohuld remove `let` from CoreML :)
Anarchos has joined #ocaml
<thelema>
Drakken: ?? if you can make a pull request...
<thelema>
orbitz: I think it's doable to investigate an ocaml heap, especially if you know the roots
<adrien>
globroots.c has three root lists (but maybe only one is enough) but I don't know if there's an easy way to access them
<hcarty>
That will download and build OCaml, findlib, odb, oasis, Batteries, utop, ocamlscript in $HOME/ocamlbrew/ocaml-3.12.1/
<hcarty>
adrien: Yes
<adrien>
ok; running, I hope it won't kill my computer
<adrien>
and slow connection here so it might take some time
<hcarty>
adrien: I hope so too. But if it does, you get to keep all the pieces!
<adrien>
\o/
<adrien>
"Retrieving OCaml" <- any way to have a progress meter?
<adrien>
ok, building now
ttamttam has left #ocaml []
<hcarty>
adrien: The closest thing you can get to a progress meter at the moment is tailing the log file
<adrien>
hcarty: I meant for downloading but it would probably be interesting to know a bit about compilation too
<adrien>
tee?
<hcarty>
adrien: You should get some progress updates from curl in the log file if you tail it during the download
<adrien>
too much work ;p
<adrien>
(actually: too many terminals opened)
<hcarty>
adrien: I could use tee to redirect the download output, but I wanted to keep the default output fairly terse
<hcarty>
adrien: Fair enough :-)
ocp has quit [Quit: Leaving.]
ocp has joined #ocaml
raichoo has quit [Ping timeout: 252 seconds]
Kakadu has joined #ocaml
raichoo has joined #ocaml
<adrien>
Enjoy!
<adrien>
Something errored out, please check the log file for details:
<adrien>
/tmp/ocamlfLpZVm.log
<adrien>
Exiting...
ocp has quit [Read error: No route to host]
<adrien>
so
ocp has joined #ocaml
<adrien>
everything worked and it says it failed =)
<hcarty>
adrien: Oops! Thanks, I'll fix that :-)
<hcarty>
I'm glad to hear it worked. You should now have (yet another) installation of OCaml 3.12.1 with a handful of libraries and tools to go with it.
<hcarty>
adrien: Thank you for testing!
<adrien>
# print_endline "You're welcome! =) ";;
<adrien>
You're welcome! =)
<adrien>
- : unit = ()
philtor has joined #ocaml
<adrien>
but I can't use backspace or C-W in utop
<adrien>
and I hate C++ ='(
everyonemines has joined #ocaml
<Kakadu>
Qrntzz: hi!
ocp has quit [Quit: Leaving.]
ocp has joined #ocaml
<adrien>
and I now have an entirely different view on pragmas
<Qrntzz>
Kakadu: hello
<Qrntzz>
Kakadu: I decided I will probably settle with QML for now
<Kakadu>
Qrntzz: what about qml + ocaml?
<Qrntzz>
Kakadu: sounds tempting for sure
<hcarty>
adrien: Not sure why utop isn't working for you - there may be a missing prerequisite or some kind of terminal handling mismatch.
<Qrntzz>
Kakadu: I will need backend code, no matter how much QML I stuff in my app, so it being ocaml would help much :-)
<Qrntzz>
any ideas for realization yet?
<adrien>
hcarty: iirc it was that; I could "fix" it with by changing xterm's config but that was not the best solution for other reasons (broke other things I think)
<Kakadu>
Qrntzz: I dont undestand completely how to bind C++ values to the qml ecmascript engine...
<Kakadu>
Qrntzz: I want to develop paladin level 20 for it, I think :D
<Qrntzz>
heh
<Qrntzz>
binding values e. g. transformating types?
<Kakadu>
mmm, no
raichoo has quit [Ping timeout: 248 seconds]
raichoo has joined #ocaml
<Kakadu>
If we want to access a field of C++ object from QML we should wrap this field with Q_PROPERT and Q_INVOKABLE macroses...
<Qrntzz>
oh.
<Kakadu>
It is not very hard but I don't completely understand how it works
<Qrntzz>
where should I look in the source if I want to try to figure it out? just to make sure we examine the same thing
Drakken has left #ocaml []
<Kakadu>
Qrntzz: I'm talking about qml at all, not lablqt
philtor has quit [Ping timeout: 255 seconds]
<Qrntzz>
Kakadu: me too.
<Qrntzz>
Kakadu: I can as well investigate the source myself and get back to you, though