meaning of --enable-checking flags

2007-02-09 Thread Larry Evans
The doc on --enable-checking at: http://gcc.gnu.org/install/configure.html contains: --enable-checking=list and implies that list may either be a category (yes,all,release,no) or a sequence of flags (e.g. fold,gcac,gc,valgrind); however, it doesn't describe what the flags mean. Could so

Re: meaning of --enable-checking flags

2007-02-10 Thread Larry Evans
On 02/09/2007 12:18 PM, Larry Evans wrote: [snip] compiler. When just using --enable-checking=yes, I was able to use gdb to find that the value of __FILE__ was corrupted: (gdb) up #1 0x0809e6eb in tsubst (t=0x4034f8a0, args=0x40351ca8, complain=3, in_decl=0x4032eea0) at ../../gcc-4.1.1

how to dump tree in pt.c:tsubst?

2007-02-11 Thread Larry Evans
How does one dump the trees in pt.c:tsubst in some hunan readable format. I've tried: struct dump_info di; di.stream=stderr; cp_dump_tree(&di, args); cp_dump_tree(&di, arg); cp_dump_tree(&di, t); however, no ouput is produced because the TREE_CODE for each of the 2nd args doesn't mat

Re: meaning of --enable-checking flags

2007-02-11 Thread Larry Evans
On 02/11/2007 02:16 PM, Kaveh R. GHAZI wrote: On Fri, 9 Feb 2007, Larry Evans wrote: [snip] describe what the flags mean. Could someone do that or provide a link to the descriptions. The --enable-checking values are described briefly in gcc/config.in, here's a link for quick access:

Re: meaning of --enable-checking flags

2007-02-11 Thread Larry Evans
On 02/11/2007 04:28 PM, Larry Evans wrote: [snip] I think a patch adding descriptions to the docs would be an improvement. Would you like to submit one? Thanks, --Kaveh I could, but the only thing I would do would be something like: The meaning of these flags can be

Re: meaning of --enable-checking flags

2007-02-12 Thread Larry Evans
On 02/11/2007 05:59 PM, Gerald Pfeifer wrote: On Sun, 11 Feb 2007, Larry Evans wrote: [snip] I can't comment on the contents, but that HTML file is generated from our texinfo documentation; the master source for that is gcc/doc/install.texi in our SVN repository. Gerald THanks G

Re: Use Bohem's GC for compiler proper in 4.1?

2005-04-01 Thread Larry Evans
On 04/01/2005 07:35 AM, Andrew Haley wrote: [snip] To be fair to the Boehm gc, though: it isn't inherently a conservative collector, but will also do precise gc. Wouldn't this require a GC_descr as defined here: http://www.hpl.hp.com/personal/Hans_Boehm/gc/gc_source/gc_typedh.txt for each data st

Re: Use Bohem's GC for compiler proper in 4.1?

2005-04-01 Thread Larry Evans
On 04/01/2005 08:21 AM, Larry Evans wrote: On 04/01/2005 07:35 AM, Andrew Haley wrote: [snip] To be fair to the Boehm gc, though: it isn't inherently a conservative collector, but will also do precise gc. Wouldn't this require a GC_descr as defined here: http://www.hpl.hp.co

Re: Use Bohem's GC for compiler proper in 4.1?

2005-04-02 Thread Larry Evans
On 04/01/2005 11:23 AM, Daniel Jacobowitz wrote: [snip] There are other ways to solve this problem, including creating a generational collector using our existing accurate GC. I've been working on this on-and-off (mostly off at the moment, though). I briefly looked at: Type-Information.html from

Re: Template and dynamic dispatching

2005-04-16 Thread Larry Evans
On 04/15/2005 08:36 PM, Robert Dewar wrote: [snip] As I said, templates and Ada generics cause trouble with certification requirements in two respects. First, they have the potential to intefere with required traceability from source to object. Second, there are a number of formal techniques that a

Re: Template and dynamic dispatching

2005-04-16 Thread Larry Evans
On 04/16/2005 10:19 AM, Larry Evans wrote: [snip] I briefly looked at several papers from: http://www.praxis-his.com/publications/ [snip] principled_design_oo.pdf [snip] I should mention that this paper does mention dynamic dispatching but nothing about templates or generic types.

Re: cxx-reflection branch

2005-07-23 Thread Larry Evans
On 07/16/2005 03:14 PM, Maurizio Monge wrote: [snip] the informations i was looking for about the cxx reflection branch [snip] branch, as i was planning to try add to gcc some extension to allow things like: template serialize(const T& t) Isn't boost's serialization library: http://www.bo

Re: coding style: type* variable or type *varible

2005-09-14 Thread Larry Evans
On 09/14/2005 04:46 AM, Dave Korn wrote: [snip] IMO (and this is a _very_ IMO subject, so I acknowledge in advance that there is no one true way and that I may feel so but other people may feel differently), the argument for making the asterisk abut the variable name rather than the type is bec

Re: Adding the D programming language

2005-11-15 Thread Larry Evans
On 11/13/2005 02:13 PM, Brian Makin wrote: [snip] If some folks are interested we should talk to the D people and suggest an acceptable D frontend. I for one would be willing to pitch in. There's already one, IIUC: http://www.opend.org/

etags Makefile target useful?

2009-07-23 Thread Larry Evans
There's an etags target in the build/Makefile: etags tags: TAGS However, when invoking this target, I get: make etags make[1]: Entering directory `/home/evansl/download/gcc/4.4-20090630/build' Doing TAGS in gcc make[2]: Entering directory `/home/evansl/download/gcc/4.4-20090630/build/gcc' cd

Re: etags Makefile target useful?

2009-07-23 Thread Larry Evans
On 07/23/09 09:06, Tom Tromey wrote: "Larry" == Larry Evans writes: Larry> etags: Warning: "--language" option is obsolete; use "--language-force" instead Maybe you are not using the etags that comes with Emacs. Exhuberant Ctags comes with an "et

In pt.c, find_parameter_packs_r, should TYPE_P(t) assure TYPE_CONTEXT(t)?

2009-08-03 Thread Larry Evans
While trying to track down the cause of: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40092 I encountered what may be an error. In pt.c around line 2493, there's this: if (TYPE_P (t) ) cp_walk_tree (&TYPE_CONTEXT (t), &find_parameter_packs_r, ppd, ppd->visited); However, gdb sho

What's the 'Mail' program mentioned on http://gcc.gnu.org/install/test.html

2009-08-18 Thread Larry Evans
I don't have any program called Mail on my system: -*- mode: compilation; default-directory: "~/download/gcc/svn/trunk/contrib/" -*- Compilation started at Tue Aug 18 11:45:20 which Mail Compilation exited abnormally with code 1 at Tue Aug 18 11:45:20 So how do I get it? Using synaptic to s

[PING]confirm for bug 40092?

2009-09-21 Thread Larry Evans
The bug: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40092 has been around for a while (since May). A patch was submitted in a gcc-patches post about 1 month ago: http://gcc.gnu.org/ml/gcc-patches/2009-08/msg01217.html ; yet, no one has even confirmed that it's a bug. Would someone mind d

[g++-4.5]kudos on O(1) template lookup work

2009-10-05 Thread Larry Evans
The work in 4.5 on O(1) template instantiation lookup time is already showing benefits: http://article.gmane.org/gmane.comp.lib.boost.devel/194545 http://article.gmane.org/gmane.comp.lib.boost.devel/194538 http://www.boostpro.com/vault/index.php?&directory=variadic_templates in tuple.benchmark.

[c++]pt.c:most_specialized_class appears to substitute outer args for inner params

2009-11-02 Thread Larry Evans
The following code around trunk/gcc/cp/pt.c:15514: 15513 partial_spec_args = INNERMOST_TEMPLATE_ARGS (partial_spec_args); 15514 partial_spec_args = tsubst_template_args 15515 (partial_spec_args, outer_args, tf_none, NULL_TREE); as shown here: http://gcc.gnu.org/viewcvs/trunk/gcc/cp/pt.c

howto graphically view .cfg file produced by -fdump-tree-cfg

2009-11-08 Thread Larry Evans
http://gcc.gnu.org/onlinedocs/gcc/Debugging-Options.html#Debugging-Options describes -fdump-tree-SWITCH where SWITCH may be one of a number of "switches" including: cfg vcg I tried the vcg switch; however, it looks like that's just the control flow for basic block. The cfg switch looks si

Re: [c++]pt.c:most_specialized_class appears to substitute outer args for inner params

2009-11-11 Thread Larry Evans
On 11/02/09 22:39, Larry Evans wrote: The following code around trunk/gcc/cp/pt.c:15514: 15513 partial_spec_args = INNERMOST_TEMPLATE_ARGS (partial_spec_args); 15514 partial_spec_args = tsubst_template_args 15515 (partial_spec_args, outer_args, tf_none, NULL_TREE); as shown here

[variadic templates]feature request: n-th element of expansion

2009-11-17 Thread Larry Evans
As mentioned in a post of comp.std.c++: http://preview.tinyurl.com/yaqvnnq there's a need for some way to get the nth element of a pack expansion. For example, boost::mpl::arg: http://www.boost.org/doc/libs/1_40_0/libs/mpl/doc/refmanual/arg.html wouldn't need the preprocessor for its impl

Re: [variadic templates]feature request: n-th element of expansion

2009-11-19 Thread Larry Evans
On 11/19/09 17:23, Jason Merrill wrote: On 11/17/2009 09:36 AM, Larry Evans wrote: Could g++ provide this feature? How hard would it be to implement. It probably wouldn't be difficult to implement, but I'd want someone to champion the extension with the C++ committee as well. Have

Re: [variadic templates]feature request: n-th element of expansion

2009-11-25 Thread Larry Evans
On 11/19/09 18:28, Larry Evans wrote: On 11/19/09 17:23, Jason Merrill wrote: On 11/17/2009 09:36 AM, Larry Evans wrote: Could g++ provide this feature? How hard would it be to implement. It probably wouldn't be difficult to implement, but I'd want someone to champion the extensio

Is there a recursive debug_c_tree which decodes "variant tag"?

2009-05-28 Thread Larry Evans
While attempting to debug the compiler on: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40092 I'm having great difficulty understanding the output of debug_c_tree or debug_tree because the child tree's are not shown. The ddd debugger: http://www.gnu.org/software/ddd/ is some help; however, e

Re: Is there a recursive debug_c_tree which decodes "variant tag"?

2009-05-28 Thread Larry Evans
On 05/28/09 11:42, Ian Lance Taylor wrote: > Larry Evans writes: > >> While attempting to debug the compiler on: >> >> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40092 >> >> I'm having great difficulty understanding the output >> of debug_c_tree or

TEMPLATE_PARM_PARAMETER_PACK redundant check in find_parameter_packs_r

2009-06-23 Thread Larry Evans
At pt.c:2462 http://gcc.gnu.org/viewcvs/trunk/gcc/cp/pt.c?revision=148666&view=markup there's: switch (TREE_CODE (t)) { case TEMPLATE_PARM_INDEX: if (TEMPLATE_PARM_PARAMETER_PACK (t)) parameter_pack_p = true; break; In gdb, macro exp shows: (gdb) macro exp TEMPLA

howto configure so that CFLAGS='-g3 -O0' in gcc/Makefile?

2009-06-30 Thread Larry Evans
I'm trying to debug the compiler. I've gotten the gcc/Makefile to compile the programs with '-g3 -O0' so that no function called are rm'ed (the -O0 option) and so that I can see what macros to (the -g3 option). However, I had to trial-and-error edit the Makefile's to change what I thought was the

Re: howto configure so that CFLAGS='-g3 -O0' in gcc/Makefile?

2009-07-01 Thread Larry Evans
On 06/30/09 12:59, Jonathan Wakely wrote: 2009/6/30 Larry Evans: So... I read `man gcc` which claimed passing "CFLAGS=" on the command line is how to do this. Well, since in my case was '-g3 -O0' I had to pass it as CFLAGS='-g3 oO0'. http://gcc.gnu.org/install/

avoiding gdb cc1plus PACK_EXPANSION_PATTERN(result) gives 'No symbol "__extension__"', error msg

2009-07-08 Thread Larry Evans
I compiled gcc with -g3 -O0' compiler flags to enable invocation of macros during a gdb session; however, the macro, PACK_EXPANSION_PATTERN, apparently uses a symbol: __extension__ not understood by gdb. How can gdb be made to understand __extension__ or how can __extension__ be rm'ed from

[gdb]howto specify breakpoints with gdb convenience variables

2009-07-12 Thread Larry Evans
My */gcc/.gdbinit contains lines like: #cp_parser_template_parameter:./* ...we have a template type parameter. break parser.c:9730 condition $bpnum expand_location(input_location).line>(99) commands call expand_location(token->location) call cp_lexer_start_debugging(parser->lexer) end Now, there

Re: [gdb]howto specify breakpoints with gdb convenience variables

2009-07-12 Thread Larry Evans
On 07/12/09 10:44, Larry Evans wrote: [snip] I was wondering if there was some way to set a convenience variable: [snip] so that the breakpoints could conveniently be adjusted after changes to the source code. IOW, something like: set $lje_bp_line_correction = 5 set $lje_bp_line_next

Re: Using C++ in GCC is OK

2010-05-31 Thread Larry Evans
On 05/31/10 14:30, Basile Starynkevitch wrote: [snip] > I would believe that replacing a complex function like above (which > contains a switch) with a virtual function call could probably be a win > in performance, not a loose. > > But perhaps my intuition is wrong. Honestly, I don't have exact f

Re: Using C++ in GCC is OK

2010-06-04 Thread Larry Evans
On 06/03/10 14:39, Steinar Bang wrote: Larry Evans : claims that switch statements are faster than virtual function calls. That's not really interesting, is it? The overhead and downsides of virtual functions are well known. The upside is the possibility to use polymorphism to

Re: gengtype needs for C++?

2010-06-29 Thread Larry Evans
On 06/28/10 21:16, Tom Tromey wrote: [snip] > > I think we should be clear that the need to write a mark function for a > new type is a drawback of this approach. Perhaps gengtype could still > write the functions for ordinary types in GCC, just not (templatized) > containers. [snip] An alternat

Re: optimization question: mpl

2010-07-28 Thread Larry Evans
On 07/28/10 09:37, Hite, Christopher wrote: [snip] I'm tring to use the template compiler to generate equivalent code. I have a mpl::list of packet descriptions like this: struct Packet1{ static const int id=1; void decode(); }; I then use boost::

Re: optimization question: mpl

2010-07-28 Thread Larry Evans
On 07/28/10 10:53, Hite, Christopher wrote: [snip] struct DecodeContext; struct M1{ static const int id=1; static void decode(DecodeContext& ){} }; struct M2{ static const int id=2; static void decode(DecodeContext& ){} }; struct M3{ static const int id=

Re: optimization question: mpl

2010-07-28 Thread Larry Evans
On 07/28/10 13:16, Piotr Rak wrote: [snip] Or you could just initialize static array of pointers, like that (please note, that I never compiled code below): [snip] Piotr, something similar was proposed here: http://groups.google.com/group/comp.lang.c++.moderated/browse_thread/thread/364c0dd5

Re: optimization question: mpl

2010-07-29 Thread Larry Evans
On 07/28/10 10:26, Richard Guenther wrote: [snip] You can use the flatten attribute to tell the compiler to inline all calls in a given function, like void __attribute__((flatten)) foo(void) { ... decode1(); ... } and it will inline decode1() (and recursively all its callees). [snip] Will th

Re: How am I supposed to verify gcc-4.8.0 download when you provide no .sig file?...

2013-05-08 Thread Larry Evans
On 04/29/13 19:35, Scott Baldwin wrote: > I was able to verify it with the .sig from gnu.org ftp, along with the info > at http://ftp.gnu.org/ about where to obtain the gnu-keyring.gpg file. > > A suggestion... In addition to making sure the .sig is copied to your > mirrors, I recommend including

Re: compare gcc vs clang on HORIZONTAL tuple implementation

2012-09-22 Thread Larry Evans
On 09/22/12 06:51, Christopher Schmidt wrote: > Larry Evans writes: >> I thought you'd find the following interesting. >> >> The 2 attached tuple.benchmark.time.COMPILER files show >> clang compiles the HORIZONTAL implementation at about >> the sam

Re: Align a POD srtuct on the stack (aliasing issue with gcc 4.6+)‏

2013-01-06 Thread Larry Evans
On 01/05/13 21:00, pps . wrote: > Question: How can I allocate random amount of stack space (using char > arrays or alloca, and then align pointer to that stack space and > reinterpret this chunk of memory as some structure that has some well > defined layout that guarantees alignment of certain