On Wed, Apr 4, 2012 at 7:53 PM, Lawrence Crowl <cr...@google.com> wrote: > On 4/4/12, Richard Guenther <richard.guent...@gmail.com> wrote: >> On Apr 4, 2012 Bernd Schmidt <ber...@codesourcery.com> wrote: >> > On 04/04/2012 11:06 AM, Richard Guenther wrote: >> > > So - I'll veto the switch unless I see 1) and 2). 1) and 2) >> > > can be combined by transitioning vec.h to a C++ template class, >> > > with proper GC support. (not sure that I can veto anything >> > > - heh) >> > >> > I don't think I can veto anything, but I'll go on the record >> > again saying that I don't think this entire plan is a good >> > idea. Write a new project in C++? Absolutely. Convert a large >> > existing one to a different language? A huge waste of time that >> > will distract us for years from actual user-visible changes. >> >> I agree for the idea of converting all of GCC to C++ (whatever >> that means). I disagree for the part making the internal >> infrastructure easier to use, understand and maintain. Which >> means targeting mostly isolated sub-systems, like vec.h (and >> other various containers), double-int.[ch] (and other various >> way of representing and working with constants). Making tree >> or gimple a C++ class with inheritance and whatever is indeed >> a huge waste of time and existing developer ressources (that, >> if only because they have to adapt and maintain two completely >> different code-bases over some time). > > Trees are presently a significant problem in that many static errors > become dynamic errors, which entails more debugging.
How do you expect tree errors to become static? By using derived types everywhere? Note that this would only be possible in a _very_ limited sub-set of places. >> I expect the GCC core to maintain written in C, compiled by C++. > > Converting VECs to C++ vectors vector would provide significant code > clarity benefits. The files in which that is done would necessarily > be C++ only. I already had VECs as the very first and best example why C++ might be good. >> > I also find debugging C++ in gdb somewhat more annoying than >> > debugging plain C, and at the moment I always go back to a >> > stage1 compiler. >> >> Indeed - I'd be worried if my debugging efficiency decreases by >> more than 5%. > > If the number of debugging sessions was reduced by the same amount, > the result would be a net wash. I have no expectation that the number of debug sessions will be reduced. Richard. > -- > Lawrence Crowl