[jit] Improvements to error-handling

2014-02-11 Thread David Malcolm
Committed to branch dmalcolm/jit: gcc/jit/ * internal-api.c (gcc::jit::recording::context::add_error_va): If GCC_JIT_STR_OPTION_PROGNAME is NULL, use "libgccjit.so", as per the comment in libgccjit.h (gcc::jit::recording::label::replay_into): When reporting on an

[jit] Improvements to error-handling

2013-10-18 Thread David Malcolm
Committed to dmalcolm/jit: Add defensive checks at the API boundary to gracefully reject various kinds of error. gcc/jit/ * internal-api.c (gcc::jit::context::get_type): Improve error message, and report the bogus value. (gcc::jit::context::new_binary_op): Likewise.