Re: [swift-dev] Compiler crash when optimisation enabled

2017-04-08 Thread Mark Woollard via swift-dev
Hi Tried building our codebase with the 1st April master snapshot and get a compiler crash at an earlier stage of the build so can’t confirm. I’ll file a bug for this latest crash… Mark > On 8 Apr 2017, at 04:01, Slava Pestov wrote: > > Correction — the PR is for swift-3.1-branch, not master

Re: [swift-dev] Compiler crash when optimisation enabled

2017-04-07 Thread Slava Pestov via swift-dev
Correction — the PR is for swift-3.1-branch, not master. The fix went into master in February so the latest master snapshots (not 4.0 snapshots, which isn’t a thing that exists) should have it already. https://github.com/apple/swift/commit/2307145c0ef7daaefe4fe0ac20fedb17f0b22730

Re: [swift-dev] Compiler crash when optimisation enabled

2017-04-07 Thread Slava Pestov via swift-dev
There’s a chance this might already be fixed — https://github.com/apple/swift/pull/8588 . Do you mind trying a 4.0 snapshot when it rolls around (probably tomorrow)? Slava > On Apr 7, 2017, at 8:32 AM, Mark Woollard via swift-dev > wrote: > > https:

Re: [swift-dev] Compiler crash when optimisation enabled

2017-04-07 Thread Mark Woollard via swift-dev
https://bugs.swift.org/browse/SR-4528 > On 7 Apr 2017, at 16:22, Johannes Weiß wrote: > > fantastic, that's definitely a Swift/LLVM bug. From what I can see the most > relevant bit is > > --- SNIP --- >> "output": "PHI node operands are not the same typ

Re: [swift-dev] Compiler crash when optimisation enabled

2017-04-07 Thread Johannes Weiß via swift-dev
fantastic, that's definitely a Swift/LLVM bug. From what I can see the most relevant bit is --- SNIP --- > "output": "PHI node operands are not the same type as the result!\n %384 = > phi %CSo7UIColor* [ %395, %394 ], [ %377, %379 ], !dbg !469\nPHI node > operands are not the same type as th

Re: [swift-dev] Compiler crash when optimisation enabled

2017-04-07 Thread Mark Woollard via swift-dev
Looks like running in Terminal may give you a lot more of a clue, got the following output: 17227 { "kind": "began", "name": "compile", "command": "\/Applications\/Xcode.app\/Contents\/Developer\/Toolchains\/XcodeDefault.xctoolchain\/usr\/bin\/swift -frontend -emit-bc \/Users\/markw\/Urb

Re: [swift-dev] Compiler crash when optimisation enabled

2017-04-07 Thread Johannes Weiß via swift-dev
Hi, So as far as I know Xcode doesn't really discriminate between exit codes and signals. So it could be signal 1 (SIGHUP, unlikely) or exit code 1 (more likely). I guess the next step would be to open Terminal.app and just paste everything from the step that's failing in the Xcode build output

Re: [swift-dev] Compiler crash when optimisation enabled

2017-04-07 Thread Mark Woollard via swift-dev
Here’s the command and failure from Xcode log - exit 1 maybe not a crash I guess since no crash stack or logs but some other decision by the toolchain to fail without any detail :-) Mark CompileSwiftSources normal arm64 com.apple.xcode.tools.swift.compiler cd /Users/markw/UrbanThings/zt/chec

Re: [swift-dev] Compiler crash when optimisation enabled

2017-04-07 Thread Johannes Weiß via swift-dev
Ok, one more question: How do you know swiftc crashed, what exactly is printed? In Xcode for example, do you see something like Command /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swiftc failed with exit code 6 in the "Report navigator". Maybe you cou

Re: [swift-dev] Compiler crash when optimisation enabled

2017-04-07 Thread Mark Woollard via swift-dev
Nothing in the system wide logs (not even a diagnostics directory there) - I’ll wait and see what the West Coast guys have to say :-) Mark > On 7 Apr 2017, at 12:44, Johannes Weiß wrote: > > Hi Mark, > > >> Here’s the directory although these are all old and not related to the crash >> under

Re: [swift-dev] Compiler crash when optimisation enabled

2017-04-07 Thread Johannes Weiß via swift-dev
Hi Mark, > Here’s the directory although these are all old and not related to the crash > under discussion (the most recent crash is for swiftc 800.0.63, the Xcode 3.1 > toolchain appears to be 802.0.48). I was able to reproduce today with Xcode > 8.3.1 update but no log with today’s date. o

Re: [swift-dev] Compiler crash when optimisation enabled

2017-04-07 Thread Mark Woollard via swift-dev
Hi Here’s the directory although these are all old and not related to the crash under discussion (the most recent crash is for swiftc 800.0.63, the Xcode 3.1 toolchain appears to be 802.0.48). I was able to reproduce today with Xcode 8.3.1 update but no log with today’s date. I’ll file a bug

Re: [swift-dev] Compiler crash when optimisation enabled

2017-04-07 Thread Johannes Weiß via swift-dev
Hi Mark, That's unfortunate. Assuming you're on macOS, do you mind running ls ~/Library/Logs/DiagnosticReports/swift*.crash that might reveal some compiler crash reports. If yes I think the best would be to file a bug for these crashes on http://bugs.swift.org . What presumably would be most h

[swift-dev] Compiler crash when optimisation enabled

2017-04-06 Thread Mark Woollard via swift-dev
Following upgrade to Xcode 8.3 / Swift 3.1 I have a project where the compiler is crashing when Swift optimisation is enabled in release builds (whole module or single file). Project builds fine for earlier compiler releases. The crash gives no stack trace in console. The crash occurs for one fr