public inbox for jit@gcc.gnu.org
 help / color / mirror / Atom feed
* error handling in GCCJIT?
@ 2015-01-01  0:00 Basile Starynkevitch
  2015-01-01  0:00 ` David Malcolm
  0 siblings, 1 reply; 3+ messages in thread
From: Basile Starynkevitch @ 2015-01-01  0:00 UTC (permalink / raw)
  To: jit

Hello all,

What is the design philosophy of GCCJIT w.r.t. errors? Is the calling
application supposed to avoid as much as possible any errors, or on
the contrary can it rely on GCCJIT error checking and not do the
checking itself?

For examples:

   should the caller check that every case in a switch statement 
is unique and non-overlapping for case ranges, or should it leave that to GCCJIT?

   should the caller check that arithmetic operations are only done on
numeric variables I guess that gcc_jit_context_new_binary_op with
GCC_JIT_BINARY_OP_PLUS of two pointer variables is a non-sense, as it
is in C. Or is that checked (and does gcc_jit_context_new_binary_op
returns NULL in that case)?

   what happens (and when?) if gcc_jit_block_end_with_conditional is
   given a non-boolean boolval?

etc....

PS. Perhaps the documentation might tell more about this...

Regards.
-- 
Basile Starynkevitch         http://starynkevitch.net/Basile/
France

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

end of thread, other threads:[~2015-07-09 21:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-01  0:00 error handling in GCCJIT? Basile Starynkevitch
2015-01-01  0:00 ` David Malcolm
2015-01-01  0:00   ` Basile Starynkevitch

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