https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92860

--- Comment #33 from David Binderman <dcb314 at hotmail dot com> ---
(In reply to Martin Liška from comment #32)
> Thank you very much. I'll wait for a test-case by you ;)

I have had a go, but I cannot generate an intermediate file.

I've tried various ways to get options-save.c to crash.
This is my most recent effort:

struct S {
    int a;
    int b;
};

void
cl_optimization_compare (gcc_options *ptr1, gcc_options *ptr2)
{
  if (ptr1->x_help_flag != ptr2->x_help_flag) {
    S * p = 0;
    fprintf( stderr, "%d\n", p->a);
    internal_error ("%<global_options%> are modified in local context");
  }

I also tried integer division by zero, which didn't seem to work.

If anyone has any better ideas on generating a crash, I would be glad 
to hear about them.

Reply via email to