adrien changed the topic of #ocaml to: Discussions about the OCaml programming language | http://www.ocaml.org | OCaml MOOC http://1149.fr/ocaml-mooc | OCaml 4.02.3 announced http://ocaml.org/releases/4.02.html | Try OCaml in your browser: http://try.ocamlpro.com | Public channel logs at http://irclog.whitequark.org/ocaml
sz0 has quit [Ping timeout: 260 seconds]
sz0 has joined #ocaml
struk|desk|away is now known as struk|desk2
tautologico has joined #ocaml
pierpa has joined #ocaml
fantasti` has joined #ocaml
fantasti` has quit [Read error: Connection reset by peer]
fantasticsid has quit [Read error: Connection reset by peer]
fantasti` has joined #ocaml
fantasti` has quit [Remote host closed the connection]
<aantron> are threads from the Thread module able to pre-empt each other anywhere, or only at certain points in execution (like calls to the GC)? i know they will be time-shared (no multiprocessing), but i want to know if they are fully pre-emptive
kakadu_ has quit [Remote host closed the connection]
chris2 has quit [Ping timeout: 256 seconds]
mcmillhj has joined #ocaml
chris2 has joined #ocaml
ollehar has joined #ocaml
ollehar has quit [Client Quit]
<Enjolras> aantron: it depends if you are taling about bytecode execution or native threads
<Enjolras> afaik, in bytecode it can only preempt at certain points of execution, but on native compilation, it's just pthread.
<aantron> i see, good to know. thanks
FreeBirdLjj has joined #ocaml
hunteriam has quit [Quit: Connection closed for inactivity]
ncthom91 has joined #ocaml
shinnya has quit [Ping timeout: 260 seconds]
struk|desk2 is now known as struk|desk|away
struk|desk|away is now known as struk|desk2
ygrek has quit [Ping timeout: 272 seconds]
segmond has joined #ocaml
sh0t has quit [Remote host closed the connection]
ncthom91 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ncthom91 has joined #ocaml
psy_ has quit [Ping timeout: 245 seconds]
psy_ has joined #ocaml
psy_ has quit [Max SendQ exceeded]
psy_ has joined #ocaml
mort___ has joined #ocaml
ncthom91 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
mort___1 has joined #ocaml
divyanshu has joined #ocaml
mort___ has quit [Read error: Connection timed out]
tmtwd has joined #ocaml
ncthom91 has joined #ocaml
ncthom91 has quit [Ping timeout: 240 seconds]
johnelse has quit [Ping timeout: 245 seconds]
johnelse has joined #ocaml
johnelse is now known as Guest10452
mort___ has joined #ocaml
divyanshu has quit [Quit: Computer has gone to sleep.]
mort___2 has joined #ocaml
mort___1 has quit [Ping timeout: 255 seconds]
mort___ has quit [Ping timeout: 272 seconds]
mac10688 has quit [Ping timeout: 255 seconds]
struk|desk2 is now known as struk|desk|away
Sorella has quit [Quit: Connection closed for inactivity]
divyanshu has joined #ocaml
nicholas_ has joined #ocaml
nicholasf has quit [Ping timeout: 240 seconds]
tmtwd has quit [Ping timeout: 260 seconds]
psy_ has quit [Quit: Leaving]
struk|desk|away is now known as struk|desk2
nicholasf has joined #ocaml
nichola__ has joined #ocaml
nicholas_ has quit [Ping timeout: 272 seconds]
nicholasf has quit [Ping timeout: 240 seconds]
MercurialAlchemi has joined #ocaml
nichola__ has quit [Ping timeout: 260 seconds]
MercurialAlchemi has quit [Ping timeout: 260 seconds]
struk|desk2 has quit [Remote host closed the connection]
struk|desk has joined #ocaml
JacobEdelman has quit [Quit: Connection closed for inactivity]
divyanshu has quit [Quit: Computer has gone to sleep.]
divyanshu has joined #ocaml
ygrek has joined #ocaml
badon has joined #ocaml
nicholasf has joined #ocaml
ygrek has quit [Ping timeout: 240 seconds]
<aantron> Enjolras: testing suggests that even on native, posix threads are serialized
divyanshu has quit [Quit: Computer has gone to sleep.]
divyanshu has joined #ocaml
MercurialAlchemi has joined #ocaml
Intensity has quit [Remote host closed the connection]
darkf has joined #ocaml
struk|desk is now known as struk|desk|away
Intensity has joined #ocaml
cross has quit [Ping timeout: 240 seconds]
FreeBirdLjj has quit [Read error: Connection reset by peer]
FreeBirdLjj has joined #ocaml
divyanshu has quit [Quit: Computer has gone to sleep.]
mort___2 has quit [Quit: Leaving.]
ivan\ has quit [Quit: ERC Version 5.3 (IRC client for Emacs)]
ivan\_ has joined #ocaml
ivan\_ has quit [Remote host closed the connection]
mj12` has joined #ocaml
inr has quit [Read error: Connection reset by peer]
aantron has quit [Remote host closed the connection]
nicholasf has quit [Ping timeout: 250 seconds]
Haudegen has quit [Ping timeout: 276 seconds]
nicholasf has joined #ocaml
divyanshu has joined #ocaml
divyanshu has quit [Client Quit]
divyanshu has joined #ocaml
zpe has joined #ocaml
Algebr_ has joined #ocaml
Haudegen has joined #ocaml
rks is now known as Guest98524
Guest98524 has quit [Killed (hitchcock.freenode.net (Nickname regained by services))]
rks_ has joined #ocaml
pierpa has quit [Ping timeout: 265 seconds]
sepp2k has joined #ocaml
Simn has joined #ocaml
xyh has quit [Read error: No route to host]
ontologiae has joined #ocaml
nicholasf has quit [Remote host closed the connection]
divyanshu has quit [Quit: Computer has gone to sleep.]
inr has joined #ocaml
nicholas_ has joined #ocaml
theblatte has quit [Ping timeout: 272 seconds]
divyanshu has joined #ocaml
inr has quit [Read error: Connection timed out]
inr has joined #ocaml
sepp2k has quit [Ping timeout: 256 seconds]
larhat1 has quit [Quit: Leaving.]
Algebr_ has quit [Ping timeout: 260 seconds]
jwatzman|work has joined #ocaml
nicholas_ has quit []
srcerer has quit [Ping timeout: 265 seconds]
d0nn1e has quit [Ping timeout: 255 seconds]
d0nn1e has joined #ocaml
divyanshu has quit [Quit: Computer has gone to sleep.]
zpe has quit [Remote host closed the connection]
zpe has joined #ocaml
_andre has joined #ocaml
zpe has quit [Remote host closed the connection]
divyanshu has joined #ocaml
accname has joined #ocaml
zump has joined #ocaml
divyanshu has quit [Quit: Computer has gone to sleep.]
freehck has joined #ocaml
<accname> Hi there, does anyone has experience with HOL Light and debugging?
<accname> or to be more specific: does anyone has experience with the ocaml top level debugging? (I want to see how much memory is used, how often a function is called etc.)
<accname> any tips, hints etc. are welcome :)
<companion_cube> well, first, I'd use utop instead of the regular toplevel
<companion_cube> there is a #trace primitive, but for debugging and profiling I can't help you much, sorry :/
<accname> oh i forgot i use rlwrap :) but I will look at utop
<accname> np :)
divyanshu has joined #ocaml
<accname> hmm yeah I found the #trace primitive, but that didn't really help
<accname> I thought about using ocamlprof but therefore the program must be compiled in profiling mode. however HOL Light uses various toplevel primitives which yield error
<accname> when I am trying to compile the program
Haudegen has quit [Ping timeout: 250 seconds]
<accname> I think for now I will look at the Gc module, maybe that will help
sillyotter has joined #ocaml
accname has quit [Quit: Leaving]
sillyotter has quit [Quit: leaving]
Haudegen has joined #ocaml
kakadu has joined #ocaml
accname has joined #ocaml
zpe has joined #ocaml
divyanshu has quit [Quit: Computer has gone to sleep.]
divyanshu has joined #ocaml
divyanshu has quit [Quit: Computer has gone to sleep.]
zpe_ has joined #ocaml
zpe has quit [Ping timeout: 264 seconds]
malc_ has joined #ocaml
rks_ is now known as rks`
accname has quit [Ping timeout: 260 seconds]
<freehck> g
fluter has quit [Killed (Sigyn (Spam is off topic on freenode.))]
fluter has joined #ocaml
BitPuffin has joined #ocaml
lokien_ has joined #ocaml
zpe_ has quit [Remote host closed the connection]
govg has joined #ocaml
Sorella has joined #ocaml
govg has quit [Ping timeout: 256 seconds]
xyh has joined #ocaml
xyh is now known as xie-1900
xie-1900 is now known as XIE1900
XIE1900 is now known as xyh
govg has joined #ocaml
JacobEdelman has joined #ocaml
ollehar has joined #ocaml
ollehar has quit [Client Quit]
shinnya has joined #ocaml
lesshaste has joined #ocaml
<lesshaste> hi.. I am trying to run this piece of code http://paste.ubuntu.com/14575309/ but there is something confusingly wrong. It just outputs 0
<lesshaste> I am using ocaml 4.01.0
<lesshaste> is it it too old is there maybe a problem with using a 32 bit system?
<freehck> mmm... my lovely version of ocaml. ;)
<reynir> that's quite a lot of code
<freehck> lesshaste: what should it output? )
<lesshaste> if someone could try running it themselves I would be very grateful. You need ocamlopt -inline 100 -nodynlink -o orthcirc unix.cmxa bigarray.cmxa orthcirc.ml
<lesshaste> to compile it
<lesshaste> freehck, it should output ./orthcirc -n 4 should output 4: 12
<lesshaste> reynir, sorry about that but there is some stupid problem. It worked fine on my other computer in another city where I tried it
<lesshaste> my only guess is either it depends on a compiler version or that it needs a 64 bit system somehow
<lesshaste> ./orthcirc -n 4 should output 4: 12
<edwin> outputs 12 here
<edwin> 4.01 64-bit
<lesshaste> edwin, oh so that's weird.. on my 32 bit system I get 4: 0
<freehck> freehck@ws-kashin:~/tmp% ./orthcirc -n 4
<freehck> 4: 12
aantron has joined #ocaml
<freehck> eh.. I'm a little bit late. :)
<lesshaste> freehck, 64 bit as well?
<freehck> yep
<lesshaste> hmm
<freehck> lesshaste: why do u use unsafe functions?
<lesshaste> so what about this code requires 64 buts!
<lesshaste> freehck, I am sorry to say it is not my code but I would guess maybe speed?
<lesshaste> 64 bits I mean
<freehck> I never do it explicitly.
<freehck> You can use safe functions and then traverse them into unsafe variants while compiling.
<lesshaste> freehck, interesting
<edwin> you could use int64 instead of int
<edwin> (bc n) + (bc (n lsr 16)) + (bc (n lsr 32)) + (bc (n lsr 48))
<edwin> you obviously odn't ahve 48 bits if your int is <32
<lesshaste> aha!
<edwin> using int64 might be slower than using plain int, it depends how many bits you really need there
<edwin> you'd have to replace every operator with functions from Int64
<edwin> i.e. use Int64.add instead of +, etc.
<bernardofpc> lesshaste: this code calculates orthogonal circulant matrices or something related to it ?
<lesshaste> bernardofpc, exactly!!
<lesshaste> bernardofpc, that was very quick :)
<lesshaste> edwin, sorry to sound stupid but what exactly do I need to change to make the code use int64?
<lesshaste> I tried the most obvious thing but it didn't compile
<bernardofpc> you'd have to change *all* operations on your bit-rows to use Int64.add, Int64.sub, etcf
<bernardofpc> *etc
xyh has quit [Ping timeout: 265 seconds]
<bernardofpc> for instance, bitcount n which divides in chunks of 16 bits
<bernardofpc> n should be of type Int64
<bernardofpc> but bitcount16 expects a "normal" (machine-native) int
<bernardofpc> so maybe the simplest thing (in this point of your code) is to replace the definition of "bc n = ..." so that n is Int64, but after the land 65535 it becomes a regular int
<bernardofpc> (I have no ocaml on this machine, so I can't ensure an example, but it's probably goind to be something like "Int64.to_int (Int64.land n (Int64.of_int 65535))"
<lesshaste> ah ok
<lesshaste> thanks
<bernardofpc> Int64.logand in fact
<bernardofpc> but once you do this, everywhere else your bitcount function is used, it expects an Int64, so there will be compilation errors saying that some var is "int" but the compiler expected Int64
<bernardofpc> so you'll have to trickle the changes down
<bernardofpc> so sad that Int64 does not provide popcount() access
<companion_cube> indeed
<companion_cube> I suppose it could be included in the compiler/stdlib, but that might have been debated already
<bernardofpc> but it doesn't *need* to be on compiler, I guess a lib with the properly written asm in a C stub + OCaml external will be enough
<companion_cube> yeah, that too
<companion_cube> although it is not always as good as a proper primitive
<malc_> bernardofpc: Int64.of_int 65535 == 65535L
<bernardofpc> oh, I didn't know Int64 was built-in the language parser
<bernardofpc> thanks
<lesshaste> looks like I have opened a can of worms :)
<bernardofpc> nah, we're not talking implicit categories ;-)
accname has joined #ocaml
octachron has joined #ocaml
<companion_cube> it's also dealt with in Format,Printf, etc
<Drup> bernardofpc: it would be difficult to create big constants otherwise
xyh has joined #ocaml
Simn has quit [Quit: Leaving]
FreeBirdLjj has quit [Remote host closed the connection]
divyanshu has joined #ocaml
sternenseemann has joined #ocaml
MercurialAlchemi has quit [Ping timeout: 276 seconds]
lokien_ has quit [Quit: Connection closed for inactivity]
divyanshu has quit [Quit: Computer has gone to sleep.]
lesshaste has quit [Quit: Leaving]
jhaberku has joined #ocaml
<jhaberku> #/join #scala
sepp2k has joined #ocaml
divyanshu has joined #ocaml
<Drup> jhaberku: Are you making a typo on purpose for each other language you are joining ? :p
<companion_cube> #/join #haskell
demonimin has quit [Ping timeout: 246 seconds]
tane has joined #ocaml
tane has quit [Ping timeout: 265 seconds]
struk|desk|away is now known as struk|desk
MercurialAlchemi has joined #ocaml
tane has joined #ocaml
sternenseemann has left #ocaml [#ocaml]
lokien_ has joined #ocaml
slash^ has joined #ocaml
<tautologico> #/join #mumps
darkf has quit [Ping timeout: 260 seconds]
jeffmo has joined #ocaml
ontologiae has quit [Ping timeout: 245 seconds]
ygrek has joined #ocaml
xyh has quit [Quit: ChatZilla 0.9.92 [SeaMonkey 2.39/20151206235742]]
darkf has joined #ocaml
xyh has joined #ocaml
octachron has quit [Quit: Leaving]
ygrek has quit [Ping timeout: 250 seconds]
Simn has joined #ocaml
jwatzman|work has quit [Quit: jwatzman|work]
psy_ has joined #ocaml
psy_ has quit [Max SendQ exceeded]
psy_ has joined #ocaml
jhaberku has quit [Ping timeout: 276 seconds]
Haudegen has quit [Ping timeout: 256 seconds]
cody` has joined #ocaml
madroach has joined #ocaml
jhaberku has joined #ocaml
<jhaberku> Drup: I knew you'd call me out on that. :D
<Drup> jhaberku: are you touring all the FP language channels ? :p
Algebr_ has joined #ocaml
govg has quit [Ping timeout: 264 seconds]
Haudegen has joined #ocaml
gdrooid has joined #ocaml
ia0 has quit [Quit: leaving]
kakadu has quit [Quit: Page closed]
ia0 has joined #ocaml
<jhaberku> Drup: I usually like having Haskell, OCaml, Scala, C++ open. I should really automate joining them when I connect. FWIW, OCaml is my favourite ATM.
lokien_ has quit [Quit: Connection closed for inactivity]
Algebr_ has quit [Ping timeout: 260 seconds]
theblatte has joined #ocaml
parataxis has quit [Ping timeout: 255 seconds]
jkni_ has joined #ocaml
ggherdov has quit [Ping timeout: 255 seconds]
mankyKitty has quit [Ping timeout: 255 seconds]
sspi has quit [Ping timeout: 255 seconds]
jkni has quit [Ping timeout: 255 seconds]
jkni_ is now known as jkni
Leonidas has quit [Ping timeout: 255 seconds]
zozozo has quit [Ping timeout: 255 seconds]
Leonidas has joined #ocaml
mankyKitty has joined #ocaml
sspi has joined #ocaml
parataxis has joined #ocaml
ygrek has joined #ocaml
xyh has quit [Remote host closed the connection]
ggherdov_ has joined #ocaml
divyanshu has quit [Quit: Textual IRC Client: www.textualapp.com]
darkf_ has joined #ocaml
darkf has quit [Disconnected by services]
darkf_ is now known as darkf
zozozo has joined #ocaml
srcerer has joined #ocaml
srcerer has quit [Client Quit]
srcerer has joined #ocaml
kakadu has joined #ocaml
ely-se has joined #ocaml
jhaberku has quit [Remote host closed the connection]
zpe has joined #ocaml
psy_ has quit [Ping timeout: 245 seconds]
_andre has quit [Quit: leaving]
psy_ has joined #ocaml
vishesh has quit [Quit: WeeChat 1.1.1]
psy_ has quit [Ping timeout: 256 seconds]
slash^ has quit [Read error: Connection reset by peer]
toolslive has joined #ocaml
psy_ has joined #ocaml
struk|desk2 has joined #ocaml
struk|desk has quit [Ping timeout: 260 seconds]
vishesh has joined #ocaml
<companion_cube> looks down, yeah
struk|desk2 is now known as struk|desk|away
accname has quit [Remote host closed the connection]
segmond has quit [Ping timeout: 260 seconds]
psy_ has quit [Ping timeout: 245 seconds]
psy_ has joined #ocaml
struk|desk|away is now known as struk|desk2
ohama has quit [Remote host closed the connection]
segmond has joined #ocaml
exm has left #ocaml [#ocaml]
lokien_ has joined #ocaml
jeffmo has quit [Quit: jeffmo]
xificurC has joined #ocaml
freehck has quit [Remote host closed the connection]
zpe has quit [Remote host closed the connection]
gallais has quit [Remote host closed the connection]
sz0 has quit [Quit: Bye.]
ohama has joined #ocaml
psy_ has quit [Ping timeout: 260 seconds]
larhat1 has joined #ocaml
BitPuffin has quit [Ping timeout: 276 seconds]
MercurialAlchemi has quit [Ping timeout: 256 seconds]
groovy2shoes has joined #ocaml
struk|desk2 is now known as struk|desk|away
sepp2k has quit [Quit: Leaving.]
tane has quit [Quit: Verlassend]
wagle has quit [Remote host closed the connection]
wagle has joined #ocaml
darkf has quit [Quit: Leaving]
ely-se has quit [Quit: Leaving...]
mac10688 has joined #ocaml
malc_ has quit [Quit: leaving]
d0nn1e has quit [Ping timeout: 240 seconds]
d0nn1e has joined #ocaml
pyon is now known as Guest11816
Guest11816 has quit [Killed (leguin.freenode.net (Nickname regained by services))]
gdrooid has quit [Quit: WeeChat 1.1.1]
xificurC has quit [Quit: WeeChat 1.3]
Simn has quit [Read error: Connection reset by peer]
exm has joined #ocaml
wolfcore has quit [Ping timeout: 276 seconds]
wolfcore has joined #ocaml
lokien_ has quit [Quit: Connection closed for inactivity]