Re: Would you trade 0.1% in performance for a better debugging experience?

2014-12-05 Thread Kagamin via Digitalmars-d
On Thursday, 4 December 2014 at 22:11:36 UTC, Martin Nowak wrote: If it were only 0.1% at maximum for any code, it wouldn't be a problem. But enabling stack traces would make a std.simd module which would only consists of tiny leaf functions basically unusable. Traditionally it doesn't

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-12-05 Thread Kagamin via Digitalmars-d
On Thursday, 4 December 2014 at 22:08:20 UTC, Martin Nowak wrote: -fasynchronous-unwind-tables Whoa! Are they big?

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-12-05 Thread Sean Kelly via Digitalmars-d
On Thursday, 4 December 2014 at 16:44:51 UTC, Temtaime wrote: Why when an DMD developer said « no » to you in ticket you go to the forum and troll there ? If one wants debug information he will use debug version of phobos. In fine-tune application there's no need for -gs flag. With stack info

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-12-04 Thread Dicebot via Digitalmars-d
I think it is a better default, at least in absence of multiple release flavors.

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-12-04 Thread Vladimir Panteleev via Digitalmars-d
On Thursday, 4 December 2014 at 14:28:47 UTC, Dicebot wrote: I think it is a better default, at least in absence of multiple release flavors. I don't think it's going to happen. The arguments would need to overrule Walter Bright and Martin Nowak (effectively Druntime's current maintainer).

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-12-04 Thread Dicebot via Digitalmars-d
On Thursday, 4 December 2014 at 14:39:07 UTC, Vladimir Panteleev wrote: On Thursday, 4 December 2014 at 14:28:47 UTC, Dicebot wrote: I think it is a better default, at least in absence of multiple release flavors. I don't think it's going to happen. The arguments would need to overrule

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-12-04 Thread Temtaime via Digitalmars-d
Why when an DMD developer said « no » to you in ticket you go to the forum and troll there ? If one wants debug information he will use debug version of phobos. In fine-tune application there's no need for -gs flag.

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-12-04 Thread Martin Nowak via Digitalmars-d
On 11/18/2014 07:49 PM, Steven Schveighoffer wrote: I refuse to let the fact that we package every platform's download into one zip to be some sort of argument :) DMD is the only distribution that I've ever seen do this. We're shifting away from this, there are per-platform zips and

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-12-04 Thread Martin Nowak via Digitalmars-d
On 11/19/2014 09:14 AM, Kagamin wrote: I'm afraid, DWARF is not designed to unwind segfaults, it works only with DWARF exceptions. -fasynchronous-unwind-tables

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-12-04 Thread Martin Nowak via Digitalmars-d
On 11/18/2014 06:15 PM, Vladimir Panteleev wrote: And indeed, for printing the stack trace for an unhandled exception, Druntime currently walks the stack frames: We're working on that to replace it with more enriched DWARF processing, e.g. to show line numbers.

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-12-04 Thread Martin Nowak via Digitalmars-d
On 11/18/2014 12:14 AM, Vladimir Panteleev wrote: Personally, I think the 0.1% is practically negligible considering the advantages. My proposal was rejected, so I'd like to hear more opinions about this. What do you think? If it were only 0.1% at maximum for any code, it wouldn't be a

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-12-04 Thread Martin Nowak via Digitalmars-d
On 11/18/2014 06:00 PM, Marco Leise wrote: Without fully understanding the issue, omitting the frame pointer on GNU amd64 systems is the default and is supposed to work using DWARF debug information. So there should be no need for a stack frame pointer, right? Are you mostly concerned with

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-21 Thread Marco Leise via Digitalmars-d
Am Wed, 19 Nov 2014 08:14:44 + schrieb Kagamin s...@here.lot: On Tuesday, 18 November 2014 at 18:55:43 UTC, Marco Leise wrote: Is it fair if I argue that fixing DWARF info generation is a better solution then? I'm afraid, DWARF is not designed to unwind segfaults, it works only with

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-19 Thread Kagamin via Digitalmars-d
On Tuesday, 18 November 2014 at 18:55:43 UTC, Marco Leise wrote: Is it fair if I argue that fixing DWARF info generation is a better solution then? I'm afraid, DWARF is not designed to unwind segfaults, it works only with DWARF exceptions.

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-19 Thread Kagamin via Digitalmars-d
On Tuesday, 18 November 2014 at 17:15:13 UTC, Vladimir Panteleev wrote: Second, there's still the argument that not every debugger and profiler can take advantage of the DWARF debug information. It's certainly nowhere as easy: from the technical point of view, but also from a legal one,

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-19 Thread w0rp via Digitalmars-d
I am personally willing to pay the small performance cost for better debugging information.

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-19 Thread Rainer Schuetze via Digitalmars-d
On 18.11.2014 00:14, Vladimir Panteleev wrote: I proposed to build Phobos and Druntime with stack frames enabled: [...] Personally, I think the 0.1% is practically negligible considering the advantages. My proposal was rejected, so I'd like to hear more opinions about this. What do you

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-18 Thread deadalnix via Digitalmars-d
On Tuesday, 18 November 2014 at 07:33:15 UTC, Daniel Kozak via Digitalmars-d wrote: Short answer: NO. Long answer: If I neeed this, I will build version of phobos and druntime myself with this enabled. Or we could distribute both versions and select one by some switch. But I am against

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-18 Thread ponce via Digitalmars-d
On Monday, 17 November 2014 at 23:14:32 UTC, Vladimir Panteleev wrote: Would you trade 0.1% in performance for a better debugging experience? Yes, of course. In most programs, a day of work can give = 1% speed-up, and debugging can take many more.

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-18 Thread Kagamin via Digitalmars-d
I'm thinking about 3 configurations: 1. debug 2. release/conservative: assert=off, bounds checks=on, stack frames 3. release/optimized: bounds checks=off, no stack frames; can also apply additional optimizations for more speed like turning assert into assume.

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-18 Thread Steven Schveighoffer via Digitalmars-d
On 11/17/14 6:14 PM, Vladimir Panteleev wrote: I proposed to build Phobos and Druntime with stack frames enabled: Sure, why not 3 versions of phobos/runtime in installation? Space is cheap. -Steve

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-18 Thread Logan Capaldo via Digitalmars-d
On Monday, 17 November 2014 at 23:14:32 UTC, Vladimir Panteleev wrote: I proposed to build Phobos and Druntime with stack frames enabled: This is very much worth it in my opinion. Not just for debugging but being able to profile (sometimes in production, without needing to recompile with

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-18 Thread Marco Leise via Digitalmars-d
Am Mon, 17 Nov 2014 23:14:31 + schrieb Vladimir Panteleev vladi...@thecybershadow.net: […] From http://eli.thegreenplace.net/2011/09/06/stack-frame-layout-on-x86-64/ - Preserving the base pointer The base pointer rbp (and its

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-18 Thread Vladimir Panteleev via Digitalmars-d
On Tuesday, 18 November 2014 at 13:18:10 UTC, Steven Schveighoffer wrote: On 11/17/14 6:14 PM, Vladimir Panteleev wrote: I proposed to build Phobos and Druntime with stack frames enabled: Sure, why not 3 versions of phobos/runtime in installation? Space is cheap. You have to consider the

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-18 Thread Vladimir Panteleev via Digitalmars-d
On Tuesday, 18 November 2014 at 16:49:55 UTC, Marco Leise wrote: Without fully understanding the issue, omitting the frame pointer on GNU amd64 systems is the default and is supposed to work using DWARF debug information. So there should be no need for a stack frame pointer, right? Firstly,

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-18 Thread Steven Schveighoffer via Digitalmars-d
On 11/18/14 12:03 PM, Vladimir Panteleev wrote: On Tuesday, 18 November 2014 at 13:18:10 UTC, Steven Schveighoffer wrote: On 11/17/14 6:14 PM, Vladimir Panteleev wrote: I proposed to build Phobos and Druntime with stack frames enabled: Sure, why not 3 versions of phobos/runtime in

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-18 Thread Marco Leise via Digitalmars-d
Am Tue, 18 Nov 2014 17:15:12 + schrieb Vladimir Panteleev vladi...@thecybershadow.net: On Tuesday, 18 November 2014 at 16:49:55 UTC, Marco Leise wrote: Without fully understanding the issue, omitting the frame pointer on GNU amd64 systems is the default and is supposed to work using

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-18 Thread Joakim via Digitalmars-d
On Monday, 17 November 2014 at 23:14:32 UTC, Vladimir Panteleev wrote: I proposed to build Phobos and Druntime with stack frames enabled: https://issues.dlang.org/show_bug.cgi?id=13726 Stack frames add three CPU instructions to each function (two in the prolog, and one in the epilog). This

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-18 Thread Steven Schveighoffer via Digitalmars-d
On 11/18/14 1:49 PM, Steven Schveighoffer wrote: I refuse to let the fact that we package every platform's download into one zip to be some sort of argument :) DMD is the only distribution that I've ever seen do this. Note: I can't imagine the build process for this is simple either. -Steve

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-18 Thread Vladimir Panteleev via Digitalmars-d
On Tuesday, 18 November 2014 at 18:55:43 UTC, Marco Leise wrote: Is it fair if I argue that fixing DWARF info generation is a better solution then? I don't know. Probably. Not all tools may read DWARF info. Also, I'm not sure if this is related but Phobos/Druntime are currently built without

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-18 Thread Marco Leise via Digitalmars-d
Am Tue, 18 Nov 2014 19:35:06 + schrieb Vladimir Panteleev vladi...@thecybershadow.net: On Tuesday, 18 November 2014 at 18:55:43 UTC, Marco Leise wrote: Is it fair if I argue that fixing DWARF info generation is a better solution then? I don't know. Probably. Not all tools may read

Would you trade 0.1% in performance for a better debugging experience?

2014-11-17 Thread Vladimir Panteleev via Digitalmars-d
I proposed to build Phobos and Druntime with stack frames enabled: https://issues.dlang.org/show_bug.cgi?id=13726 Stack frames add three CPU instructions to each function (two in the prolog, and one in the epilog). This creates a linked list which debuggers, profilers, etc. can easily walk to

Re: Would you trade 0.1% in performance for a better debugging experience?

2014-11-17 Thread Daniel Kozak via Digitalmars-d
Vladimir Panteleev via Digitalmars-d píše v Po 17. 11. 2014 v 23:14 +: I proposed to build Phobos and Druntime with stack frames enabled: https://issues.dlang.org/show_bug.cgi?id=13726 Stack frames add three CPU instructions to each function (two in the prolog, and one in the epilog).