ve changed since then. I might have another look this weekend...
Thanks,
Brendon.
rder to allow
users to provide indications of code segments that require different types of
exception guarantees, which is then enforced at a later time.
Any thoughts or ideas are welcome.
Thanks,
Brendon.
and if so what types that
are skipped by gimplify_function_tree defined in gimplify.c?
Thanks,
Brendon.
en it allows all exceptions to pass through). I don't think
this is correct though. Is it? I then use EH_FILTER_MUST_NOT_THROW()
and EH_FILTER_TYPES() to gather my information from this node.
Is there a better way of achieving this?
Thanks,
Brendon.
al functions as they pass through:
gimplify.c: gimplify_function_tree()
It sped my code up by over 100x. I guess it really depends on what you
wish to do and I am sure someone else on this list can help a lot more
than i can.
Brendon.
expected. I was not sure if I could just add an additional operand to
the THROW_EXPR node. I figured that all other commands would just use
operand 0 and ignore the new operand but it seems to fail with an ICE,
so i gave up that line of thinking...
Thanks for any help/info on this.
Brendon.
Richard Guenther wrote:
> On 10/14/06, Brendon Costa <[EMAIL PROTECTED]> wrote:
>> Hi all,
>>
>> I have yet another question that has arisen as i have started testing my
>> code. Basically I am trying to get the type that is being used in
>> throwing an exce
doing this?
Thanks,
Brendon.
Bob Rossi wrote:
>
> Thanks Brendon, that was really helpful. I'm very new at this, and may
> have some seemingly rather odd questions. I see that global_namespace is
> of type 'union tree_node'. Is this the C++ language dependent AST?
Yes, this is the C++ AST. I
Ian Lance Taylor wrote:
> Brendon Costa <[EMAIL PROTECTED]> writes:
>
>> For each FUNCTION_DECL node I find, I want to determine what its
>> exception specification list is. I.e. the throws() statement in its
>> prototype.
>
> Look at TYPE_RAISES_EXCEPTIONS
Brendon Costa wrote:
> Ian Lance Taylor wrote:
>> Brendon Costa <[EMAIL PROTECTED]> writes:
>>
>>> For each FUNCTION_DECL node I find, I want to determine what its
>>> exception specification list is. I.e. the throws() statement in its
>>> prot
t
is there somewhere I can get some more definitive information on these
functions?
Thanks,
Brendon.
Some examples of the sort of data I see are shown below
Attribute::Attribute()
Calls: None
Attribute::Attribute(Attribute const&)
Calls: None
Attribute::__comp_ctor(A
Hi all,
How can I find a FUNCTION_DECL node from a CALL_EXPR node for virtual
function calls?
Note: I am not after the node for the function that will be executed
at runtime as I know this is not possible to determine in most
situations.
Thanks for any help in advance,
Brendon
Brendon Costa wrote:
> Hi all,
>
> How can I find a FUNCTION_DECL node from a CALL_EXPR node for virtual
> function calls?
>
Well I have managed to achieve this, though I don't know if it is the
best way to do so. For the sake of people that may find this question in
the
L node that would be called by it
in order to perform the initialisation of the class data?
Thanks,
Brendon.
Brendon Costa wrote:
basic_ofstream::basic_ofstream(int __in_chrg, void* __vtt_parm)
Can someone please help me understand why this happens?
Well looking more in the source I have found that this happens when
virtual inheritance is in play. It is used to determine which
constructor will
e __comp_ctor sometimes differ from the "User
Constructor" that it is associated with?
3) Again, is there a simple way of finding the constructor method that
would be called given a corresponding __comp_ctor () method?
Thanks,
Brendon.
Sorry that my previous email was unclear. I have tried to clarify what i
meant in this email by answering your questions.
Andrew Pinski wrote:
On Tue, 2006-10-24 at 02:30 +, Brendon Costa wrote:
I am trying to find the corresponding constructor from the basic_string
class that should
s i have left to iron out.
Thanks,
Brendon.
nt like
this code as it currently uses a strcmp in order to findwhat it is after
and it also does not work completely. I have also placed some code at
the very end of this email which is a small test case of code that this
fails for.
Thanks,
Brendon
I call the function: GetCtorEquivilent(tre
on_tree() method.
Is this a bug or am I doing/expecting something that is incorrect?
Thanks,
Brendon.
template
class MyClassT
{
public:
template
MyClassT(_InputIterator __beg) {}
};
typedef MyClassT MyClass;
int main()
{
const char* str1 = "Hello1";
MyClass mc(str1);
return 0;
}
plate constructor does not get
added to the methods vector.
Thanks for any information in advance.
Brendon.
The appropiate few lines of code in the pt.c:
check_explicit_specialization() file look as shown below:
else if (DECL_CONSTRUCTOR_P (decl) || DECL_DESTRUCTOR_P (decl))
/* T
nd confusing is that there are "deleting"
destructors, which made me think that there was some extra code as part
of this __deleting_dtor () that woud free the memory or something like
that. Maybe this is the case, but I do not need to know that for my
situation.
Hope this can help someone else.
Thanks,
Brendon.
information.
but each time i try to call it with a TYPE_DECL it segfaults.
Thanks,
Brendon.
that has complex construction like std::string. E.g. Change
GrandChild class to look like:
class GrandChild : public Child1, public Child2
{
public:
std::string s;
};
Thanks,
Brendon.
class Parent
{
public:
int data;
};
class Child1 : public virtual Parent
{
};
class Child2 : public
How can I get a full list of all GCC C++ built-in functions that may be
used on a given platform or GCC build?
For example, __cxa_begin_catch(), __cxa_end_catch(), __builtin_memset ...
I am currently working with GCC 4.0.1 source base.
Thanks,
Brendon.
functions.
As for the libsupc++.a and libgcc*.* libraries. Are they compiled with
the newly generated gcc/g++ compilers or are they compiled with the
compiler used to build gcc and g++?
Thanks,
Brendon.
Well, there is the documentation, e.g.:
http://gcc.gnu.org/onlinedocs/gcc-4.0.3/gcc/Other
How do i determine if two type nodes in the C front end are equivilent?
In C++ i use same_type_p() but do not see an equivilant for the C front end.
Thanks,
Brendon.
The function you want is comptypes.
Thanks. That is working well.
Hi Brendon,
Wouldn't the C++ one (mostly) be a superset of the C?
Types are reasonably different between the C and C++ front ends though you do
have the common ones because as you said, C++ is a superset of C.
is 32 bit.
How can i get the "char" string when a user uses char types instead of
"int" strings?
Thanks,
Brendon.
the type I was obtaining the
name of. I was using DECL_ARG_TYPE() to obtain it and not TREE_TYPE() on
the function parameter node. This was giving me a wider integer type
parameter instead of the type that the user declared.
Brendon.
structure like:
struct TypeInfoStruct
{
GTY(()) tree node;
my data
};
I dont think this will work from what I have read it seems the garbage
collection only seems to work for single globals. How can i achieve this?
Thanks,
Brendon.
match that with a reference that i see the GC
deleting at least I can determine if this problem even is related to GC.
Thanks,
Brendon.
Mike Stump wrote:
On Nov 12, 2006, at 10:47 PM, Brendon Costa wrote:
I think i am having trouble with the garbage collector deleting
the memory for tree nodes that i am still using.
You must have a reference to that data from gc managed memory. If
you don't use use gc to all
re is little speed advantage gained in precompiling these headers
from what I understand. At most there is about 40 lines of code in each
of them.
Thanks,
Brendon.
required data but that never seems to occur.
Is there something i should be doing before using EXPR_HAS_LOCATION() ?
Thanks,
Brendon.
Steven Bosscher wrote:
On 11/17/06, Brendon Costa <[EMAIL PROTECTED]> wrote:
Is there something i should be doing before using EXPR_HAS_LOCATION() ?
Compile with -g, perhaps?
I tried that and it didnt seem to make any difference.
Brendon Costa wrote:
Hi all,
I am trying to obtain location information (file, line) for a number
of expr nodes (CALL_EXPR, THROW_EXPR and ADDR_EXPR) and it seems that
every expression node i call EXPR_HAS_LOCATION on returns false.
If it returns true i then use: EXPR_LINENO
I was thinking of looking at the first TYPE_NEXT_VARIANT of the
anonymous RECORD_TYPE node which may give me "Blah", but I am not
certain it will do so all the time... Does anyone know if this will work
or if there is a better way?
Thanks,
Brendon.
PE_MAIN_VARIENT for the various
parts of the FUNCTION_TYPE node (return type, and parameters). Does
anyone have ANY idea of a way I could do something similar in the C
front end?
Thanks,
Brendon.
as different types. I might just go for the
pessimistic match first and look at improving things later on once the
rest of it is all up and going.
Thanks for the input,
Brendon.
in the assembler?
extern "C"
{
void Function(void) {}
}
namespace NS
{
extern "C"
{
void Function(void) {}
}
}
Thanks,
Brendon.
Andrew Pinski wrote:
On Thu, 2006-11-30 at 16:08 +1100, Brendon Costa wrote:
Hi again,
Is it safe to assume in the C++ front end that two functions declared in
such a manner will always share the same implementation in which case it
is kind-of like a "using" statement?
doing this at least until i have
made a first release of my project (Hopefully within the next month),
but I think i might start taking notes now of some things i would like
to add.
Thanks,
Brendon.
according to
the vague linkage GCC page)?
Thanks,
Brendon.
Brendon Costa wrote:
> Hi all,
>
> I understand that all template functions in GCC should have vague
> linkage and thus may be exported into numerous translation units where
> they are used. I have been attempting to use a few different macros on
> both an instanciated
ter allows NO exceptions and if false then allows only
exceptions of type that are in this list? Is it possible for the
EH_FILTER_TYPES list to be empty and EH_FILTER_MUST_NOT_THROW() to
return false?
Thanks for any information on these questions. It will help me a great deal.
Brendon.
well.
For the C++ code shown above try { ... } catch(...) {}
From memory I get a TRY_BLOCK node and not a TRY_CATCH_EXPR.
Also is the implicit rethrow just for the TRY_FINALLY_EXPR and not for
the TRY_CATCH_EXPR or is it for both of them?
Thanks,
Brendon.
on
of data by the PCH engine? I assumed it would re-construct a full tree
hierarchy if i rooted a tree node.
Thanks,
Brendon.
that the way i
was going about it was going to fail.
Mike Stump wrote:
> On Feb 11, 2007, at 1:17 PM, Brendon Costa wrote:
>> I am coding an extension for GCC and am having some difficulty with
>> pre-compiled headers. I dont know if my understanding of how they work
>> is comp
g the explicit free and i can then
later just simply define out calls to ggc_free if i decide to do so at
a later date.
Anyhow, I guess it is time to get my hands dirty with the GCC Garbage
Collector...
Thanks for the advice,
Brendon.
Mike Stump wrote:
> On Feb 13, 2007, at 3:16 PM, Brendon Costa wrote:
>> There is no "additional" pain in doing this as I have already
>> developed my code using manual malloc/free in such a way that i am
>> reasonably sure there are no leaks, or double free calls
specified. I.e. without the optimizations applied or this parameter
added or typedefs substituted etc.
Is this possible? And if so where is the best place to look?
By the way i am using the source for GCC 4.0.1 in case that makes a
difference.
Thanks,
Brendon.
the maintainer
first). I am interested in feedback on how it can be improved, but this
thread came up and i just could not pass the opportunity...
Brendon.
Sergio Giro wrote:
> Maybe that the option you suggest
>
>> This is best
>> done with something like -fstatic-except
ly similar result. I might look into this at a later time.
Brendon.
Sergio Giro wrote:
> On Apr 2, 2007, at 2:32 AM, Brendon Costa wrote:
>> I have for a while been working on a tool that performs static
>> analysis
> I agree that Brendon's project is a very good ide
evel
"enable/disable of static checking". I.e. It will check for all
functions whose implementation you find in the given translation unit.
Brendon.
Mike Stump wrote:
> On Apr 10, 2007, at 2:06 PM, Sergio Giro wrote:
>> Maybe I missed some point: why everything should be rewritten?
his well
i think. I do also think however that it is worth the effort (Which is
why i have been working on EDoc++) and that such a feature would be
valuable within gcc itself.
Anyhow, i think i have been rambling again... I am curios to see where
this thread leads.
Brendon.
file(s)?
Thanks for any help,
Brendon.
documentation, but that is another topic.
Thanks,
Brendon.
I have notes inline below, following is my summary of libplugin from
what i understand of your posts:
* It exists as a fraemwork that works with GCC now
* It uses xml files to define plugins (Allows making new plugins as
combinations of others without making a new shared library, i.e. just
create a
> I believe we should first focus (when the runtime license will permit
> that) on making whatever plugin machinery available and merged into
> the trunk (when it comes back to stage one). This is not an easy task.
Isn't the point of this discussion to decide what features to put into a
plugin fra
tc which just call the real gcc/g++... adding the necessary
command line args. These can then just be put earlier in the search path.
I currently use the env var method in my project, but I think the
wrapper script idea is a bit nicer than using env vars personally, so i
will likely change to that soon.
Brendon.
me framework
assuming that each pass is given a unique identifier?
Thanks,
Brendon.
#include
#include
/* GCC : Code */
struct Hooks
{
/* Define the blah signal. */
struct BlahFPWrap
{
const char* name;
int (*fp)(struct BlahFPWrap* self, int i, char c, float f);
vo
parameter
* modifies the object state (this is an extension of the function
parameter on the "this" parameter)
The reason for posting this is to ask. Is there code in GCC that
already does something "similar" in say one of the optimisation passes
so i can get a look at how to get started on this?
Thanks,
Brendon.
Forgot to reply all...
-- Forwarded message --
From: Brendon Costa <[EMAIL PROTECTED]>
Date: 2008/11/30
Subject: Re: Functional Purity
To: David Fang <[EMAIL PROTECTED]>
>Sounds like you want to (at least):
>
> 1) automatically qualify every d
ikely to spend a
large chunk of time reading/responding to when that they could spend
the same time doing their own important work.
Brendon.
like:
gcc -fedoc-file=blah.edc -fedoc-embed
which is just the same as it was before, but the -fplugin=edoc was omitted.
Brendon.
t files to process for my
.edc files and how to combine them.
I am currently working with a gcc-4.0.1 source base. If someone can
point me as to where GCC links these files together I would greatly
appreciate it.
Thanks,
Brendon Costa.
Ian Lance Taylor wrote:
> Brendon Costa <[EMAIL PROTECTED]> writes:
>
>> Then GCC (SOMEWHERE I CANT SEEM TO FIND THIS PART OF THE CODE) links
>> these objects by calling ld with /tmp/foo1.o and /tmp/foo2.o combining
>> these into: blah
>
> It
sume this can be done by adding certain directives to the
assembler source file (.s), since the assembler generates the .o files.
Anyhow, I will continue to look further into this and may get back
with more questions :-) later. Thanks for the idea.
Thanks,
Brendon.
Brendon Costa wrote:
> Mike Stump wrote:
>> Hum, on second thought, why not just encode the information you want
>> into the .o file. Just put it into a special section, in whatever
>> format you like, the linker will combine them, no additional files, .a
>> files work,
e way
of separating my data from the other inserted data which starts to get
more complex. By using my own section I don't think I need to define
any symbols or sync headers for my data or anything like that.
Thanks again for the help. I now have somethings I can try.
Brendon.
so this is really a first for me.
Any ideas what I am doing wrong?
Thanks for any help.
Brendon.
Brendon Costa wrote:
> Hi all,
>
> I have been trying to place some data into a named section of a .o
> file. I can do it currently by hooking into various of the RTL to
> assembly routines and emitting the asm code directly, however I am now
> trying to do it from within th
doing so as that
has been covered previously, just wondering if an official decision
has been made?
Thanks,
Brendon.
release, then i will use it for my open source project: EDoc++
If enough people end up using it, it might give some weight to the
argument of merging it into the GCC main-line sometime in the future.
Thanks,
Brendon.
information on how to do this let me
know and i will pull out the relevant code. But as Andrew said,
usually this is only known at runtime and most applications have no
use knowing this information.
Brendon.
sure who created it) is a decent summary of
the past discussion on this issue:
http://gcc.gnu.org/wiki/GCC_Plugins
Thanks,
Brendon.
comes the issue of thinking about how does an external project
locate that directory? Do we add an option to the command line of GCC to
obtain this directory name?
--
How/where do we install headers and the library for external plugin
projects to use?
Thanks,
Brendon.
h reason to
out-weight the costs associated with automatically loading plugins (I.e.
Predictability). I did however think it worth bringing up as an option.
I hope that describes the problem sufficiently. If you can think of any
other solutions to this problem, i would love to hear them.
Thanks,
Brendon.
her way of achieving
"automatically loaded" plugins. I think i will follow up the script idea.
Thanks,
Brendon.
ros and library and support the windows
platform from the beginning (Are there any other platforms with quirks
not covered here)?
I may not be able to work on the wiki page or reply to any messages for
about 3 days as it seems my phone line at home has gone down and thus so
has the internet. I will check back sometime after that and see how best
to summarise peoples responses on the wiki.
Thanks,
Brendon.
odified GCC to do the LOT-like analysis. I
have brought that out into a separate post compilation tool as it was
just easier to code that way.
To be honest the idea of embedding the data into the binary came from
someone else on this list.
Brendon.
the time now to
look at implementing it. It will likely require changes to the C++
parser and front end to insert extra nodes into the tree for this
markup. I am also not sure if others would accept such a modification
into the official GCC release unless it was generic enough to be used
for other purposes (maybe such as providing optimization hints for
certain segments of code or other forms of markup).
Thanks,
Brendon.
Simon Hill wrote:
> Brendon Costa said:
>> The author of the template class or container can't know
>> what types of exceptions will be thrown from them, so you must define
>> them as being able to throw all exceptions (which is how they are
>> currently).
> O
the
issues inherent in the C++ language definition of how exception
specifiers work. I do however think as i mentioned before that it would
make a great project to learn more about GCC internals and would
encourage giving it a try on those grounds.
Brendon.
ot; in order to be included in the official GCC distribution?
Is it a long shot to even think that such a framework would ever be
included in GCC?
Thanks,
Brendon.
IMPLE). The paper mentioned that
this is not yet done but may be added as a future improvement.
I might look a bit more into this branch. It looks great. Does anyone
know if this is the best place to direct any questions or thoughts if
i have any or should i email Sean directly?
Thanks for the response.
Brendon.
,
Brendon.
n has a few
plugins but they are not public yet as they want to work on them a bit
first.
I am on holidays for a month as of tomorrow, so i wont get a chance to
look at it until i return anyway. Thanks for the info.
Brendon.
f the plugin framework is not going to stop me doing it
whatever way i can.
Brendon.
Robert Dewar wrote:
> Brendon Costa wrote:
>>>> The concern is the many forms of shim layers that possibly could
>>>> be written more easily with a plug-in framework.
>>> there is also a difference in these two scenarios:
>>>
>>> 1. a) Comp
Robert Dewar wrote:
> Brendon Costa wrote:
>
>> The patch against GCC is GPL, the main library that is capable of
>> manipulating the data exported by the patched GCC is LGPL and could
>> theoretically be under any license.
>
> Whose theory? You don't know tha
David Edelsohn wrote:
> If you want to have a legal discussion, please take this
> conversation somewhere else.
>
> Thanks, David
>
Sorry. I just posted another email before i got this. Is there a
suitable place to move this discussion besides private emails?
Thanks,
Brendon.
eeing this in a future release :-)
Thanks,
Brendon.
is just shooting ourselves in the foot in order to do the same to
others. It makes no sense as we are restricting our own progress for a
possible misuse of the feature by others (That is already occurring
anyway).
Brendon.
96 matches
Mail list logo