/* Generated by Frama-C */
#include "pthread.h"
#include "sched.h"
#include "signal.h"
#include "stddef.h"
#include "stdint.h"
#include "stdio.h"
#include "stdlib.h"
#include "time.h"
extern  __attribute__((__FC_BUILTIN__)) int __e_acsl_sound_verdict;

int *A;
int *B;
void f(void)
{
  A = B;
  return;
}

void g(int *C, int *D)
{
  {
    __e_acsl_store_block((void *)(& C),8UL);
    __e_acsl_assert_data_t __gen_e_acsl_assert_data = {.values = (void *)0};
    __gen_e_acsl_assert_data.blocking = 1;
    __gen_e_acsl_assert_data.kind = "Assertion";
    __gen_e_acsl_assert_data.pred_txt = "\\initialized(&C)";
    __gen_e_acsl_assert_data.file = "ptr_init.c";
    __gen_e_acsl_assert_data.fct = "g";
    __gen_e_acsl_assert_data.line = 16;
    __e_acsl_assert(1,& __gen_e_acsl_assert_data);
  }
  /*@ assert \initialized(&C); */ ;
  __e_acsl_delete_block((void *)(& C));
  return;
}

void __e_acsl_globals_init(void)
{
  static char __e_acsl_already_run = 0;
  if (! __e_acsl_already_run) {
    __e_acsl_already_run = 1;
    __e_acsl_store_block((void *)(& B),8UL);
    __e_acsl_full_init((void *)(& B));
    __e_acsl_store_block((void *)(& A),8UL);
    __e_acsl_full_init((void *)(& A));
  }
  return;
}

void __e_acsl_globals_clean(void)
{
  __e_acsl_delete_block((void *)(& B));
  __e_acsl_delete_block((void *)(& A));
  return;
}

int main(void)
{
  int __retres;
  int *x;
  int *y;
  __e_acsl_memory_init((int *)0,(char ***)0,8UL);
  __e_acsl_globals_init();
  __e_acsl_store_block((void *)(& y),8UL);
  __e_acsl_store_block((void *)(& x),8UL);
  B = (int *)malloc(sizeof(int));
  __e_acsl_full_init((void *)(& y));
  y = (int *)malloc(sizeof(int));
  __e_acsl_full_init((void *)(& x));
  x = y;
  f();
  {
    __e_acsl_assert_data_t __gen_e_acsl_assert_data = {.values = (void *)0};
    __gen_e_acsl_assert_data.blocking = 1;
    __gen_e_acsl_assert_data.kind = "Assertion";
    __gen_e_acsl_assert_data.pred_txt = "\\initialized(&A)";
    __gen_e_acsl_assert_data.file = "ptr_init.c";
    __gen_e_acsl_assert_data.fct = "main";
    __gen_e_acsl_assert_data.line = 25;
    __e_acsl_assert(1,& __gen_e_acsl_assert_data);
  }
  /*@ assert \initialized(&A); */ ;
  {
    int __gen_e_acsl_initialized;
    __e_acsl_assert_data_t __gen_e_acsl_assert_data_2 =
      {.values = (void *)0};
    __e_acsl_assert_register_ptr(& __gen_e_acsl_assert_data_2,"&x",
                                 (void *)(& x));
    __e_acsl_assert_register_ulong(& __gen_e_acsl_assert_data_2,
                                   "sizeof(int *)",0,sizeof(int *));
    __gen_e_acsl_initialized = __e_acsl_initialized((void *)(& x),
                                                    sizeof(int *));
    __e_acsl_assert_register_int(& __gen_e_acsl_assert_data_2,
                                 "\\initialized(&x)",0,
                                 __gen_e_acsl_initialized);
    __gen_e_acsl_assert_data_2.blocking = 1;
    __gen_e_acsl_assert_data_2.kind = "Assertion";
    __gen_e_acsl_assert_data_2.pred_txt = "\\initialized(&x)";
    __gen_e_acsl_assert_data_2.file = "ptr_init.c";
    __gen_e_acsl_assert_data_2.fct = "main";
    __gen_e_acsl_assert_data_2.line = 26;
    __e_acsl_assert(__gen_e_acsl_initialized,& __gen_e_acsl_assert_data_2);
    __e_acsl_assert_clean(& __gen_e_acsl_assert_data_2);
  }
  /*@ assert \initialized(&x); */ ;
  g(x,y);
  __retres = 0;
  __e_acsl_delete_block((void *)(& y));
  __e_acsl_delete_block((void *)(& x));
  __e_acsl_globals_clean();
  __e_acsl_memory_clean();
  return __retres;
}


