smimou has quit [Read error: 110 (Connection timed out)]
jeremiah has quit [Read error: 104 (Connection reset by peer)]
filp has joined #ocaml
Linktim has joined #ocaml
guillem has joined #ocaml
jeremiah has joined #ocaml
hkBst has joined #ocaml
jonas_e has joined #ocaml
johnnowak has joined #ocaml
asmanur has joined #ocaml
coucou747 has joined #ocaml
jonafan_ has joined #ocaml
jonafan has quit [Read error: 110 (Connection timed out)]
det has quit [Read error: 104 (Connection reset by peer)]
struk_atwork has quit [Read error: 104 (Connection reset by peer)]
struk_atwork has joined #ocaml
ijcd_____ has joined #ocaml
ijcd___ has joined #ocaml
oavdeev has joined #ocaml
Associat0r has quit []
Associat0r has joined #ocaml
ijcd__ has quit [Read error: 110 (Connection timed out)]
ijcd_ has quit [Read error: 110 (Connection timed out)]
pizza_turtle has quit [Client Quit]
pizza_turtle has joined #ocaml
pizza_turtle has quit [Read error: 113 (No route to host)]
sporkmonger has joined #ocaml
m3ga has joined #ocaml
Mr_Awesome has quit ["aunt jemima is the devil!"]
m3ga has quit ["disappearing into the sunset"]
vixey has quit ["* I'm too lame to read BitchX.doc *"]
coucou747 has quit ["bye ca veut dire tchao en anglais"]
RobertFischer has joined #ocaml
yziquel has joined #ocaml
yziquel has quit [SendQ exceeded]
yziquel has joined #ocaml
coucou747 has joined #ocaml
det has joined #ocaml
<det>
If ocaml inlines a function that returns an 'a option into a function with matches against it, is there any chance ocaml will not allocate the tuple?
<RobertFischer>
Almost certainly not. Why do you care?
<det>
iterating a 1 million byte char array without going to main memory for each char
<thelema>
det: ocaml doesn't do much non-local optimization. In fact, in general, it does exactly what you tell it to do, and if that means allocating a tuple just to match on it, it'll do that.
<det>
problem is returning multiple values from a function
<flux>
thelema, after inlining, wouldn't it turn into a local optimization..
<flux>
maybe ocaml could do a bit of that kind of optimization, so optimized code wouldn't need to look horrible :)
<thelema>
det: can an exception solve your problem? ocaml exceptions are fast++
<thelema>
flux: yes, with sufficient inlining almost all optimizations are local.
<det>
Yeah, using an exception instead of option can solve it
<det>
but it is a small function that will certainly be inlined
<det>
and option style is much nicer code
<det>
for this
<thelema>
function calls are cheap.
<det>
function call isnt the issue
<det>
it is allocating 1 million tuples :-)
<flux>
allocation is not that expensive either
<det>
premature optimization at this point, but i am trying to get a feel for ocaml compiler
<flux>
only a few machine operations
<det>
but the GC cant be free
<flux>
true
<thelema>
yes, I'm saying that ocaml doesn't inline as much as people thing because function calls are cheap and codesize is important with regards to caches.
<thelema>
*think
<det>
a function that does only 3 bitwise operation would certainly be inlined, I think :-)
<thelema>
det: if it's that simple, inline it yourself.
<det>
ugly code
<det>
inlining that across X functions
<thelema>
ocaml isn't mlton - you ccan get performance increases by moving code around.
<det>
code is a liability, functionality is an asset, less, more clear code with same functionality = better
<det>
oh well, not a big deal
struk_atwork has quit [Read error: 110 (Connection timed out)]
AxleLonghorn has joined #ocaml
AxleLonghorn has left #ocaml []
Yoric[DT] has joined #ocaml
bluestorm has joined #ocaml
marmotine has joined #ocaml
bluestorm has quit [Read error: 104 (Connection reset by peer)]
Linktim is now known as Linktimaw
johnnowak has quit []
pizza_ has left #ocaml []
pango has quit [Remote closed the connection]
bluestorm has joined #ocaml
pango has joined #ocaml
Jedai has quit [Read error: 113 (No route to host)]
ijcd_ has joined #ocaml
ijcd__ has joined #ocaml
ijcd___ has quit [Read error: 60 (Operation timed out)]
ijcd_____ has quit [Read error: 60 (Operation timed out)]
Jedai has joined #ocaml
filp has quit ["Bye"]
munga has quit ["Leaving"]
guillem has quit [Remote closed the connection]
Associat0r has quit []
Associat0r has joined #ocaml
ijcd__ has quit []
ijcd_ has quit []
jlouis has quit ["Leaving"]
jlouis has joined #ocaml
tomh has joined #ocaml
oavdeev has quit ["Leaving"]
jonas_e has quit [Read error: 113 (No route to host)]
Demitar has quit [Read error: 110 (Connection timed out)]
ijcd_ has joined #ocaml
ijcd__ has joined #ocaml
Linktimaw is now known as Linktim
filp has joined #ocaml
Ched- has quit [Connection reset by peer]
ijcd__ has quit [Read error: 110 (Connection timed out)]
ijcd_ has quit [Read error: 110 (Connection timed out)]
Ched- has joined #ocaml
kotarak has joined #ocaml
Ched- has left #ocaml []
Linktim has quit [Read error: 113 (No route to host)]
Linktim has joined #ocaml
guillem has joined #ocaml
Ched- has joined #ocaml
ijcd__ has joined #ocaml
ijcd__ has quit [Read error: 104 (Connection reset by peer)]
ijcd_ has joined #ocaml
ijcd__ has joined #ocaml
coucou747 has quit [Read error: 110 (Connection timed out)]
ygrek has joined #ocaml
Axioplase has joined #ocaml
flux has quit [clarke.freenode.net irc.freenode.net]
Naked has quit [clarke.freenode.net irc.freenode.net]
Axioplase has quit ["testage radeonhd"]
netx has quit [Remote closed the connection]
flux has joined #ocaml
jonafan_ is now known as jonafan
Axioplase has joined #ocaml
Flice has joined #ocaml
<Flice>
hi
<Flice>
how can I use the unsigned '>>' integer operation
<Flice>
?
Naked has joined #ocaml
ygrek has quit [Remote closed the connection]
<bluestorm>
Flice: lsl
<pango>
I don't think there's such operator in standard library...
<bluestorm>
or lsr maybe
<bluestorm>
lsr probably :p
<Flice>
bluestorm: thanks
<bluestorm>
pango: '>>' would be a bad operator choice anyway, as it conflicts with camlp4 quotation syntax
<pango>
that's no proof that nobody defined it in a library
filp has quit ["Bye"]
Snark has quit ["Ex-Chat"]
filp has joined #ocaml
asmanur has quit [Remote closed the connection]
filp has quit ["Bye"]
LordMetroid has joined #ocaml
bluestorm has quit ["Konversation terminated!"]
<Flice>
what is the function to reverse a list?
<orbitz>
List.rev probably
<Yoric[DT]>
Gasp.
<Yoric[DT]>
Someone just published results *very* similar to the paper I'm working on.
<Yoric[DT]>
I've been working on that for 6 months...
<Associat0r>
does anyone know if operatot overloading will be added some time?
<Yoric[DT]>
Associat0r: not planned.
<Yoric[DT]>
But creation of new operators has been there forever.
<orbitz>
Yoric[DT]: ouch!
<orbitz>
typeclasses seem liek they'd be a fairly large change to teh type system
<hcarty>
Associat0r: g'caml has some sort of operator overloading support. I don't know its current state though. let first = intersection_indices.(0) in
<flux>
has it been researched? maybe some duality with the module system could be found.. (just thinking of the white paper that researchs the connection between them)
<orbitz>
people are tryign to do camlp4 trick, like the math one in teh SOC
<Yoric[DT]>
We have something without Camlp4 in Batteries Included, for the usual types.
<flux>
well, overloading or type classes will never happen with camlp4 magic
<Yoric[DT]>
(numeric types, that is)
<flux>
I suppose numeric types handled with shared operators kill performance?
<orbitz>
Yoric[DT]: is that done? i thoguht it was just a SOC thign
<flux>
say, if one were to implement fft with them..
<Yoric[DT]>
orbitz: it's in the repository
<orbitz>
in one sense I do liek haskelsl type overlaoding, but in another i rarely seem to find it to be the bottleneck in writing cod ein Ocaml
<Yoric[DT]>
[open Int32.Operators] give you *., +., etc. working on int32
<Yoric[DT]>
[open Int64.Operators] give you *., +., etc. working on int64
<Yoric[DT]>
etc.
Axioplase has quit ["++"]
<flux>
yoric[dt], oh, that should be normal speed then?
<Yoric[DT]>
flux: indeed.
<flux>
I was thinking it would provide (+) : 'a numeric -> 'a numeric -> 'a numeric or something
bzzbzz has quit ["leaving"]
<Yoric[DT]>
That's probably going to happen some day, too.
<Yoric[DT]>
With a different module.
<orbitz>
Yoric[DT]: the summer of code one you would do soemthign like Int64.(3 * 5 / 6)
<Yoric[DT]>
Two different techniques.
Linktim has quit [Read error: 54 (Connection reset by peer)]
<Yoric[DT]>
With ours (and open_in), it's more [open Int64 in 3 *. 5 /. 6]
<Yoric[DT]>
sorry,
<Associat0r>
is gcaml recommended for production use? I guess not
<Yoric[DT]>
it's actually a bit more complex
<Yoric[DT]>
Associat0r: I don't think it's maintained.
Linktim has joined #ocaml
Linktim has quit [Remote closed the connection]
<pango>
it's experimental, and doesn't support all the features of OCaml
<hcarty>
orbitz: There is something like that already, though not to the extent of the SoC project
<hcarty>
I wrote a simple camlp4 extension to do it, and Zheng Li did as well
<orbitz>
yeah teh SoC is going balls-to-the-walls
<hcarty>
I'm hoping that they pull it off - if so it could be very handy
<orbitz>
yeah
<orbitz>
it seemed to go alittle too far IMO, but if they get it all i nthere, all the better
Naked has quit [Read error: 60 (Operation timed out)]
Naked has joined #ocaml
AxleLonghorn has joined #ocaml
Yoric[DT] has quit ["Ex-Chat"]
AxleLonghorn has left #ocaml []
Ched- has quit [Remote closed the connection]
Linktim has joined #ocaml
lordmetroid_ has joined #ocaml
lordmetroid_ has quit [Read error: 104 (Connection reset by peer)]
kotarak has quit ["Xaide, 4ao."]
struktured has joined #ocaml
<Jeff_123>
what is this SOC thing you guys were talking about?
tetha has quit [Read error: 110 (Connection timed out)]
LordMetroid has quit [Read error: 110 (Connection timed out)]
<hcarty>
Jeff_123: The Jane St. OCaml Summer Project
<Jeff_123>
oh yup, there's some cool projects there
<hcarty>
Yes, it's a pretty exciting and ambitious group of projects
<Jeff_123>
some of them VERY ambitious! I wonder how far along eg the multicore and qt ones will be by the end of summer.
<Jeff_123>
If anyone wants to help get my uint64lib (unsigned 64 bit integers) library linking to ocaml native code executables lemme know. I still don't know what the problem is (works fine with bytecode toplevel and executables).
Ched- has joined #ocaml
Jedai has quit [Read error: 113 (No route to host)]