<asterite>
It crashes on my machine too with LLVM 3.5.1
<asterite>
but with LLVM HEAD (3.7-svn) it works well
<asterite>
There are some LLVM bugs related to exception handling… I think in HEAD they are fixed. I thought in LLVM 3.5.1 they were fixed, but apparently not
<asterite>
And only in Mac, I think
<asterite>
jhass: can you try to `make clean crystal spec` on your side, see if it segfaults too?
<jhass>
fyi, make clean crystal spec runs fine on my machine too on master
<asterite>
Yes… And remember that IO.select thing that would segfault on my machine but not yours? That’s the same llvm bug :(
<asterite>
Maybe we should just generate assembly code ourself :-P
<jhass>
hehe
<jhass>
I fear llvm needs its code for the optimizer run though, right? ;)
<asterite>
To be honest, I’m not quite sure why crystal is so fast. LLVM is really amazing :)
<jhass>
yeah
<asterite>
Yes, llvm does all the optimizations for us
<asterite>
It’s really smart
<jhass>
and things like that ARM support is figuring out a few constants away basically
<asterite>
Of course, we try to give it things it can nicely optimize
<asterite>
Yes, exactly. The other thing would be to use gcc, but I guess it would have its cons too
<jhass>
Ruby is thinking about doing an LLVM JIT for 3.0, so...
<asterite>
And ldc (d + llvm) is much faster than regular D… I think llvm is the way to go :)
<jhass>
definitely
<jhass>
I think you just need to dispose your mac :P
<asterite>
Well, that’s going to be hard… the mac I have is the one they give me for work :-P
<asterite>
And I really like mac by now… I used ubuntu and other linuxes for a while, but there were always problems and manual command line things I had to do all the time, it was kind of annoying
<asterite>
and mac is pretty fast, actually
<jhass>
btw. I "found" an xcode dmg and extracted some stuff and throw lxr at it... so if you need to find something in the future :P
<jhass>
>> class Foo; def self.[](x]; yield x; end; end; Foo["hi"] {|x| puts x }
<CeBot>
jhass: Syntax error in eval:3: unexpected token: ] (expected ',' or ')')
<jhass>
>> class Foo; def self.[](x); yield x; end; end; Foo["hi"] {|x| puts x }
<CeBot>
jhass: Syntax error in eval:3: unexpected token: {
<jhass>
:/
<asterite>
:-P
<jhass>
>> class Foo; def self.[](x); yield x; end; end; Foo["hi"] do |x| puts x; end
<CeBot>
jhass: Syntax error in eval:3: expecting identifier 'end', not 'do'
<asterite>
That doesn’t work in Ruby either, I think
<jhass>
yeah
<jhass>
but would be funny :P
<asterite>
I think it could work, I don’t know why it doesn’t (in ruby)
<jhass>
because.. did you ever look at parse.y? :P
<asterite>
Not for too long, I want to keep my eyes healthy
<asterite>
Probably my mental health too :-P
<asterite>
I don’t like parser generators much
<jhass>
;)
<asterite>
It all starts nice, but when you need to do some little tweaks then you are in for a long war against those tools
zamith_ has joined #crystal-lang
zamith has quit [Ping timeout: 245 seconds]
asterite_ has joined #crystal-lang
asterite has quit [Ping timeout: 252 seconds]
asterite_ is now known as asterite
CeBot has quit [Quit: Crystal]
DeBot has joined #crystal-lang
asterite has quit [Quit: asterite]
bcardiff has joined #crystal-lang
asterite has joined #crystal-lang
shama has joined #crystal-lang
<zamith_>
asterite: hey
<zamith_>
I get a segfault when running the tests
<zamith_>
and it's not on the compiler
<zamith_>
the compiler is ok
zamith_ is now known as zamith
crystal-gh has joined #crystal-lang
<crystal-gh>
[crystal] zamith opened pull request #385: Allows divisions with the num1/(num2) syntax (master...master) http://git.io/bYrW
crystal-gh has left #crystal-lang [#crystal-lang]
<asterite>
zamith: you are on mac, right?
crystal-gh has joined #crystal-lang
<crystal-gh>
[crystal] asterite pushed 1 new commit to master: http://git.io/bY6C
<crystal-gh>
crystal/master ff1e13f Ary Borenszweig: [CLI] Added -D option to add compile-time flags to use for ifdef
crystal-gh has left #crystal-lang [#crystal-lang]
<zamith>
yes
<zamith>
I'm trying to find the file where it happens
<asterite>
What llvm you have?
<asterite>
If you have 3.5 or 3.5.1, can you try this: brew update; brew rm llvm; brew install llvm —HEAD; brew link llvm —force
<asterite>
And then try to compile the specs with `make clean crystal spec` again
<asterite>
At least in my case it works… We strongly believe it’s a bug in llvm
<zamith>
it may well be
<asterite>
More because it doesn’t happen on mac, and it happens randomly
<zamith>
have you had this happen to you as well?
<asterite>
Yes. I’m now checking with @waj if it happens to him too
<zamith>
I'm re installing llvm head
<asterite>
Yes, it takes a lot of time. Then… we don’t know if the bug is because llvm is compiled generically… if you install HEAD it will compile it on your machine
<zamith>
oh ok
<zamith>
but it only effects the running of tests, right?
<zamith>
it has no impact on the regular user
travis-ci has joined #crystal-lang
<travis-ci>
manastech/crystal#1909 (master - ff1e13f : Ary Borenszweig): The build is still failing.
<asterite>
and run the specs again, with llvm 3.5, and see that it all compiles and runs nicely… but that code is almost the same as the above one, so that’s the llvm bug… it happens randomly depending on the code you compile :(
<asterite>
which makes it pretty obsucre
<asterite>
Unless we are not seeing something… but on linux it never, ever segfaults like that
<zamith>
asterite: while I run the tests, would you be available for a skype call or something like that, today or tomorrow?
<zamith>
I'd like to review my talk with you, if you have the time
<zamith>
I'm giving it tomorrow
<zamith>
all the tests are ok, now
<asterite>
zamith: Sure! I’d love to review it with you :)
<zamith>
what's the best time for you?
<asterite>
I have a meeting right now, for one or two hours, but after that, if it’s not too late there, we can do it
<zamith>
let me check the time difference
<zamith>
:P
<zamith>
it's only 3 hours difference, can you do 6PM?