public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* checking for debug a plugin on a production compiler?
@ 2009-10-14 21:28 Basile STARYNKEVITCH
  2009-10-15 22:30 ` Rafael Espindola
  0 siblings, 1 reply; 2+ messages in thread
From: Basile STARYNKEVITCH @ 2009-10-14 21:28 UTC (permalink / raw)
  To: GCC Mailing List

Hello All

Is the following scenario possible:

gcc-4.5 is being released at Christmas 2009 [*]. Since it is a 
production compiler, it has been compiled without any checking (no 
ENABLE_CHECKING, etc...)

a plugin foo.c is compiled as foo.so for that gcc-4.5, but since the 
plugin is probably buggy, it is compiled with ENABLE_CHECKING.

This should probably work if ENABLE_CHECKING does not add extra fields 
in data structure, but only runs checks without "side-effects" - other 
than consume CPU resources (& memory)... In other words, if 
ENABLE_CHECKING only enables gcc_assert and similar stuff (that is, only 
add code but not "data" inside GCC, if you guess what I am thinking of).

If this is impossible (for instance because ENABLE_CHECKING modifies the 
  data structure inside GCC), we might consider documenting that.

Regards.

Note [*]: I don't pretend knowing when 4.5 will be released, and its 
release date is not the subject of that discussion!

-- 
Basile STARYNKEVITCH         http://starynkevitch.net/Basile/
email: basile<at>starynkevitch<dot>net mobile: +33 6 8501 2359
8, rue de la Faiencerie, 92340 Bourg La Reine, France
*** opinions {are only mines, sont seulement les miennes} ***

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: checking for debug a plugin on a production compiler?
  2009-10-14 21:28 checking for debug a plugin on a production compiler? Basile STARYNKEVITCH
@ 2009-10-15 22:30 ` Rafael Espindola
  0 siblings, 0 replies; 2+ messages in thread
From: Rafael Espindola @ 2009-10-15 22:30 UTC (permalink / raw)
  To: Basile STARYNKEVITCH; +Cc: GCC Mailing List

> a plugin foo.c is compiled as foo.so for that gcc-4.5, but since the plugin
> is probably buggy, it is compiled with ENABLE_CHECKING.

How would you do this? :-)

The plugin should get the ENABLE_CHECKING definition from the
auto-host.h used by the compiler, so they should always agree.

>
> Regards.
>
> Note [*]: I don't pretend knowing when 4.5 will be released, and its release
> date is not the subject of that discussion!
>
> --
> Basile STARYNKEVITCH         http://starynkevitch.net/Basile/
> email: basile<at>starynkevitch<dot>net mobile: +33 6 8501 2359
> 8, rue de la Faiencerie, 92340 Bourg La Reine, France
> *** opinions {are only mines, sont seulement les miennes} ***
>

Cheers,
-- 
Rafael Ávila de Espíndola

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-10-15 19:51 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-10-14 21:28 checking for debug a plugin on a production compiler? Basile STARYNKEVITCH
2009-10-15 22:30 ` Rafael Espindola

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).