/* Generated by Frama-C */
#include "pthread.h"
#include "sched.h"
#include "signal.h"
#include "stddef.h"
#include "stdint.h"
#include "stdio.h"
#include "time.h"
char *__gen_e_acsl_literal_string_6;
char *__gen_e_acsl_literal_string_5;
char *__gen_e_acsl_literal_string;
char *__gen_e_acsl_literal_string_4;
char *__gen_e_acsl_literal_string_3;
char *__gen_e_acsl_literal_string_2;
extern  __attribute__((__FC_BUILTIN__)) int __e_acsl_sound_verdict;

int main(void);

char *T = (char *)"bar";
int G = 0;
void f(void)
{
  {
    int __gen_e_acsl_valid_read;
    __e_acsl_assert_data_t __gen_e_acsl_assert_data = {.values = (void *)0};
    __e_acsl_assert_register_char(& __gen_e_acsl_assert_data,"*(T + G)",0,
                                  *(T + G));
    __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,"T",(void *)T);
    __e_acsl_assert_register_int(& __gen_e_acsl_assert_data_2,"G",0,G);
    __e_acsl_assert_register_ulong(& __gen_e_acsl_assert_data_2,
                                   "sizeof(char)",0,sizeof(char));
    __gen_e_acsl_valid_read = __e_acsl_valid_read((void *)(T + G),
                                                  sizeof(char),(void *)T,
                                                  (void *)(& T));
    __gen_e_acsl_assert_data_2.blocking = 1;
    __gen_e_acsl_assert_data_2.kind = "RTE";
    __gen_e_acsl_assert_data_2.pred_txt = "\\valid_read(T + G)";
    __gen_e_acsl_assert_data_2.file = "literal_string.i";
    __gen_e_acsl_assert_data_2.fct = "f";
    __gen_e_acsl_assert_data_2.line = 11;
    __gen_e_acsl_assert_data_2.name = "mem_access";
    __e_acsl_assert(__gen_e_acsl_valid_read,& __gen_e_acsl_assert_data_2);
    __e_acsl_assert_clean(& __gen_e_acsl_assert_data_2);
    __gen_e_acsl_assert_data.blocking = 1;
    __gen_e_acsl_assert_data.kind = "Assertion";
    __gen_e_acsl_assert_data.pred_txt = "*(T + G) == \'b\'";
    __gen_e_acsl_assert_data.file = "literal_string.i";
    __gen_e_acsl_assert_data.fct = "f";
    __gen_e_acsl_assert_data.line = 11;
    __e_acsl_assert((int)*(T + G) == 98,& __gen_e_acsl_assert_data);
    __e_acsl_assert_clean(& __gen_e_acsl_assert_data);
  }
  /*@ assert *(T + G) == 'b'; */ ;
  G ++;
  return;
}

char *S = (char *)"foo";
char *S2 = (char *)"foo2";
int IDX = 1;
int G2 = 2;
char const *s_str = "the cat";
char const *l_str = "the dog and the cat";
char *U = (char *)"baz";
void __e_acsl_globals_init(void)
{
  static char __e_acsl_already_run = 0;
  if (! __e_acsl_already_run) {
    __e_acsl_already_run = 1;
    __gen_e_acsl_literal_string_6 = "the dog and the cat";
    __e_acsl_store_block((void *)__gen_e_acsl_literal_string_6,
                         sizeof("the dog and the cat"));
    __e_acsl_full_init((void *)__gen_e_acsl_literal_string_6);
    __e_acsl_mark_readonly((void *)__gen_e_acsl_literal_string_6);
    __gen_e_acsl_literal_string_5 = "the cat";
    __e_acsl_store_block((void *)__gen_e_acsl_literal_string_5,
                         sizeof("the cat"));
    __e_acsl_full_init((void *)__gen_e_acsl_literal_string_5);
    __e_acsl_mark_readonly((void *)__gen_e_acsl_literal_string_5);
    __gen_e_acsl_literal_string = "ss";
    __e_acsl_store_block((void *)__gen_e_acsl_literal_string,sizeof("ss"));
    __e_acsl_full_init((void *)__gen_e_acsl_literal_string);
    __e_acsl_mark_readonly((void *)__gen_e_acsl_literal_string);
    __gen_e_acsl_literal_string_4 = "foo2";
    __e_acsl_store_block((void *)__gen_e_acsl_literal_string_4,
                         sizeof("foo2"));
    __e_acsl_full_init((void *)__gen_e_acsl_literal_string_4);
    __e_acsl_mark_readonly((void *)__gen_e_acsl_literal_string_4);
    __gen_e_acsl_literal_string_3 = "foo";
    __e_acsl_store_block((void *)__gen_e_acsl_literal_string_3,sizeof("foo"));
    __e_acsl_full_init((void *)__gen_e_acsl_literal_string_3);
    __e_acsl_mark_readonly((void *)__gen_e_acsl_literal_string_3);
    __gen_e_acsl_literal_string_2 = "bar";
    __e_acsl_store_block((void *)__gen_e_acsl_literal_string_2,sizeof("bar"));
    __e_acsl_full_init((void *)__gen_e_acsl_literal_string_2);
    __e_acsl_mark_readonly((void *)__gen_e_acsl_literal_string_2);
    __e_acsl_store_block((void *)(& l_str),8UL);
    __e_acsl_full_init((void *)(& l_str));
    __e_acsl_store_block((void *)(& s_str),8UL);
    __e_acsl_full_init((void *)(& s_str));
    __e_acsl_store_block((void *)(& S2),8UL);
    __e_acsl_full_init((void *)(& S2));
    __e_acsl_store_block((void *)(& S),8UL);
    __e_acsl_full_init((void *)(& S));
    __e_acsl_store_block((void *)(& T),8UL);
    __e_acsl_full_init((void *)(& T));
  }
  return;
}

void __e_acsl_globals_clean(void)
{
  __e_acsl_delete_block((void *)(& l_str));
  __e_acsl_delete_block((void *)(& s_str));
  __e_acsl_delete_block((void *)(& S2));
  __e_acsl_delete_block((void *)(& S));
  __e_acsl_delete_block((void *)(& T));
  return;
}

int main(void)
{
  int __retres;
  __e_acsl_memory_init((int *)0,(char ***)0,8UL);
  __e_acsl_globals_init();
  char *SS = (char *)__gen_e_acsl_literal_string;
  __e_acsl_store_block((void *)(& SS),8UL);
  __e_acsl_full_init((void *)(& SS));
  {
    int __gen_e_acsl_valid_read;
    __e_acsl_assert_data_t __gen_e_acsl_assert_data = {.values = (void *)0};
    __e_acsl_assert_register_char(& __gen_e_acsl_assert_data,"*(S + G2)",0,
                                  *(S + G2));
    __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,"S",(void *)S);
    __e_acsl_assert_register_int(& __gen_e_acsl_assert_data_2,"G2",0,G2);
    __e_acsl_assert_register_ulong(& __gen_e_acsl_assert_data_2,
                                   "sizeof(char)",0,sizeof(char));
    __gen_e_acsl_valid_read = __e_acsl_valid_read((void *)(S + G2),
                                                  sizeof(char),(void *)S,
                                                  (void *)(& S));
    __gen_e_acsl_assert_data_2.blocking = 1;
    __gen_e_acsl_assert_data_2.kind = "RTE";
    __gen_e_acsl_assert_data_2.pred_txt = "\\valid_read(S + G2)";
    __gen_e_acsl_assert_data_2.file = "literal_string.i";
    __gen_e_acsl_assert_data_2.fct = "main";
    __gen_e_acsl_assert_data_2.line = 25;
    __gen_e_acsl_assert_data_2.name = "mem_access";
    __e_acsl_assert(__gen_e_acsl_valid_read,& __gen_e_acsl_assert_data_2);
    __e_acsl_assert_clean(& __gen_e_acsl_assert_data_2);
    __gen_e_acsl_assert_data.blocking = 1;
    __gen_e_acsl_assert_data.kind = "Assertion";
    __gen_e_acsl_assert_data.pred_txt = "*(S + G2) == \'o\'";
    __gen_e_acsl_assert_data.file = "literal_string.i";
    __gen_e_acsl_assert_data.fct = "main";
    __gen_e_acsl_assert_data.line = 25;
    __e_acsl_assert((int)*(S + G2) == 111,& __gen_e_acsl_assert_data);
    __e_acsl_assert_clean(& __gen_e_acsl_assert_data);
  }
  /*@ assert *(S + G2) == 'o'; */ ;
  {
    int __gen_e_acsl_initialized;
    __e_acsl_assert_data_t __gen_e_acsl_assert_data_3 =
      {.values = (void *)0};
    __e_acsl_assert_register_ptr(& __gen_e_acsl_assert_data_3,"S",(void *)S);
    __e_acsl_assert_register_ulong(& __gen_e_acsl_assert_data_3,
                                   "sizeof(char)",0,sizeof(char));
    __gen_e_acsl_initialized = __e_acsl_initialized((void *)S,sizeof(char));
    __e_acsl_assert_register_int(& __gen_e_acsl_assert_data_3,
                                 "\\initialized(S)",0,
                                 __gen_e_acsl_initialized);
    __gen_e_acsl_assert_data_3.blocking = 1;
    __gen_e_acsl_assert_data_3.kind = "Assertion";
    __gen_e_acsl_assert_data_3.pred_txt = "\\initialized(S)";
    __gen_e_acsl_assert_data_3.file = "literal_string.i";
    __gen_e_acsl_assert_data_3.fct = "main";
    __gen_e_acsl_assert_data_3.line = 26;
    __e_acsl_assert(__gen_e_acsl_initialized,& __gen_e_acsl_assert_data_3);
    __e_acsl_assert_clean(& __gen_e_acsl_assert_data_3);
  }
  /*@ assert \initialized(S); */ ;
  {
    int __gen_e_acsl_valid_read_2;
    __e_acsl_assert_data_t __gen_e_acsl_assert_data_4 =
      {.values = (void *)0};
    __e_acsl_assert_register_ptr(& __gen_e_acsl_assert_data_4,"S2",
                                 (void *)S2);
    __e_acsl_assert_register_ulong(& __gen_e_acsl_assert_data_4,
                                   "sizeof(char)",0,sizeof(char));
    __gen_e_acsl_valid_read_2 = __e_acsl_valid_read((void *)S2,sizeof(char),
                                                    (void *)S2,
                                                    (void *)(& S2));
    __e_acsl_assert_register_int(& __gen_e_acsl_assert_data_4,
                                 "\\valid_read(S2)",0,
                                 __gen_e_acsl_valid_read_2);
    __gen_e_acsl_assert_data_4.blocking = 1;
    __gen_e_acsl_assert_data_4.kind = "Assertion";
    __gen_e_acsl_assert_data_4.pred_txt = "\\valid_read(S2)";
    __gen_e_acsl_assert_data_4.file = "literal_string.i";
    __gen_e_acsl_assert_data_4.fct = "main";
    __gen_e_acsl_assert_data_4.line = 27;
    __e_acsl_assert(__gen_e_acsl_valid_read_2,& __gen_e_acsl_assert_data_4);
    __e_acsl_assert_clean(& __gen_e_acsl_assert_data_4);
  }
  /*@ assert \valid_read(S2); */ ;
  {
    int __gen_e_acsl_initialized_2;
    int __gen_e_acsl_and;
    __e_acsl_assert_data_t __gen_e_acsl_assert_data_5 =
      {.values = (void *)0};
    __e_acsl_assert_register_ptr(& __gen_e_acsl_assert_data_5,"&SS",
                                 (void *)(& SS));
    __e_acsl_assert_register_ulong(& __gen_e_acsl_assert_data_5,
                                   "sizeof(char *)",0,sizeof(char *));
    __gen_e_acsl_initialized_2 = __e_acsl_initialized((void *)(& SS),
                                                      sizeof(char *));
    __e_acsl_assert_register_int(& __gen_e_acsl_assert_data_5,
                                 "\\initialized(&SS)",0,
                                 __gen_e_acsl_initialized_2);
    if (__gen_e_acsl_initialized_2) {
      int __gen_e_acsl_valid;
      __e_acsl_assert_register_ptr(& __gen_e_acsl_assert_data_5,"SS",
                                   (void *)SS);
      __e_acsl_assert_register_ulong(& __gen_e_acsl_assert_data_5,
                                     "sizeof(char)",0,sizeof(char));
      __gen_e_acsl_valid = __e_acsl_valid((void *)SS,sizeof(char),(void *)SS,
                                          (void *)(& SS));
      __e_acsl_assert_register_int(& __gen_e_acsl_assert_data_5,
                                   "\\valid(SS)",0,__gen_e_acsl_valid);
      __gen_e_acsl_and = __gen_e_acsl_valid;
    }
    else __gen_e_acsl_and = 0;
    __gen_e_acsl_assert_data_5.blocking = 1;
    __gen_e_acsl_assert_data_5.kind = "Assertion";
    __gen_e_acsl_assert_data_5.pred_txt = "!\\valid(SS)";
    __gen_e_acsl_assert_data_5.file = "literal_string.i";
    __gen_e_acsl_assert_data_5.fct = "main";
    __gen_e_acsl_assert_data_5.line = 28;
    __e_acsl_assert(! __gen_e_acsl_and,& __gen_e_acsl_assert_data_5);
    __e_acsl_assert_clean(& __gen_e_acsl_assert_data_5);
  }
  /*@ assert !\valid(SS); */ ;
  f();
  s_str ++;
  l_str ++;
  __retres = 0;
  __e_acsl_delete_block((void *)(& SS));
  __e_acsl_globals_clean();
  __e_acsl_memory_clean();
  return __retres;
}


