/*
 * Compile and disassemble this program with objdump. Step through it to
 * see how different kinds of variables are represented in binary code.
 * Try it with without -O, and with -O1, -O2, -O3. 
 */


#include <stdio.h>

struct foo {
  int x;
  int y;
  char s[10];
};


int get_y(struct foo*);
int add1(int x);

int main()
{
  struct foo a_foo;

  a_foo.x = 1;
  a_foo.y = 200;

  printf("%d\n", get_y(&a_foo));

  return add1(5);
}

int get_y(struct foo* p)
{
  return p->s[3];
}

int add1(int x)
{
  long zzz;
  zzz++;
  return x+1;
}

