public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* gcc_assert() and inhibit_libc
@ 2021-07-21 12:44 Sebastian Huber
  2021-07-22 12:15 ` Richard Biener
  2021-08-12 14:08 ` Martin Liška
  0 siblings, 2 replies; 15+ messages in thread
From: Sebastian Huber @ 2021-07-21 12:44 UTC (permalink / raw)
  To: GCC Development

Hello,

while testing this patch

https://www.google.com/search?client=firefox-b-e&q=gcc+enable_runtime_checking

I noticed that __gcov_info_to_gcda() uses abort(). This is due to (from 
tsystem.h):

#ifdef ENABLE_RUNTIME_CHECKING
#define gcc_assert(EXPR) ((void)(!(EXPR) ? abort (), 0 : 0))
#else
/* Include EXPR, so that unused variable warnings do not occur.  */
#define gcc_assert(EXPR) ((void)(0 && (EXPR)))
#endif

In tsystem.h there is this if inhibit_libc is defined:

#ifndef abort
extern void abort (void) __attribute__ ((__noreturn__));
#endif

Who is supposed to define abort here optionally? Can this be defined for 
example by a target configuration header like gcc/config/rtems.h?

-- 
embedded brains GmbH
Herr Sebastian HUBER
Dornierstr. 4
82178 Puchheim
Germany
email: sebastian.huber@embedded-brains.de
phone: +49-89-18 94 741 - 16
fax:   +49-89-18 94 741 - 08

Registergericht: Amtsgericht München
Registernummer: HRB 157899
Vertretungsberechtigte Geschäftsführer: Peter Rasmussen, Thomas Dörfler
Unsere Datenschutzerklärung finden Sie hier:
https://embedded-brains.de/datenschutzerklaerung/

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

end of thread, other threads:[~2021-08-17  8:41 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-21 12:44 gcc_assert() and inhibit_libc Sebastian Huber
2021-07-22 12:15 ` Richard Biener
2021-08-06 17:26   ` Sebastian Huber
2021-08-12 14:31   ` Jason Merrill
2021-08-12 14:08 ` Martin Liška
2021-08-12 14:12   ` Sebastian Huber
2021-08-12 14:29     ` Martin Liška
2021-08-12 14:31       ` Sebastian Huber
2021-08-16 12:33         ` Martin Liška
2021-08-16 13:50           ` Sebastian Huber
2021-08-16 16:50             ` Jason Merrill
2021-08-16 17:06               ` Jakub Jelinek
2021-08-16 18:57                 ` Jeff Law
2021-08-17  8:41               ` Sebastian Huber
2021-08-16 17:05             ` Joseph Myers

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).