// File: /workspace/github_c_makefile_star2_O2/GregorR[P]lstg/ImageBuilder/imageBuilder.c
// Function: bigBang
void bigBang(void)
{
  struct object  *ObjectClass,
                 *MetaObjectClass,
                 *ClassClass,
                 *NilClass,
                 *TrueClass,
                 *FalseClass,
                 *TreeClass,
                 *DictionaryClass,
                 *OrderedArrayClass,
                 *MetaClassClass,
                 *ByteArrayClass;

  /*
   * First, make the nil (undefined) object;
   * notice its class is wrong
   */
  nilObject = gcalloc(0);

  /*
   * Second, make class for Symbol;
   * this will allow newClass to work correctly
   */
  SymbolClass = gcalloc(MetaSymbolSize);
  addGlobalName("Symbol", SymbolClass);
  SymbolClass->data[nameInClass] = newSymbol("Symbol");

  /*
     now we can fix up nil's class 
   */
  NilClass = newClass("Undefined");
  addGlobalName("Undefined", NilClass);
  nilObject->class = NilClass;
  addGlobalName("nil", nilObject);

  /*
     make up the object / metaobject mess 
   */
  ObjectClass = newClass("Object");
  addGlobalName("Object", ObjectClass);
  MetaObjectClass = newClass("MetaObject");
  addGlobalName("MetaObject", MetaObjectClass);
  ObjectClass->class = MetaObjectClass;
  ObjectClass->data[parentClassInClass] = nilObject;

  /*
     And the Class/MetaClass mess 
   */
  ClassClass = newClass("Class");
  addGlobalName("Class", ClassClass);
  MetaClassClass = newClass("MetaClass");
  addGlobalName("MetaClass", MetaClassClass);
  ClassClass->class = MetaClassClass;

  /*
     now make up a bunch of other classes 
   */
  BlockClass = newClass("Block");
  addGlobalName("Block", BlockClass);

  /*
     create Char with extra slot for instance var 
   */
  CharClass = gcalloc(MetaCharSize);
  addGlobalName("Char", CharClass);
  CharClass->data[nameInClass] = newSymbol("Char");

  /*
     SmallInt has an extra class variable, just like Symbol and Char 
   */
  SmallIntClass = gcalloc(MetaSmallIntSize);
  addGlobalName("SmallInt", SmallIntClass);
  SmallIntClass->data[nameInClass] = newSymbol("SmallInt");

  IntegerClass = newClass("Integer");
  addGlobalName("Integer", IntegerClass);

  TrueClass = newClass("True");
  addGlobalName("True", TrueClass);
  trueObject = gcalloc(0);
  trueObject->class = TrueClass;
  addGlobalName("true", trueObject);

  FalseClass = newClass("False");
  addGlobalName("False", FalseClass);
  falseObject = gcalloc(0);
  falseObject->class = FalseClass;
  addGlobalName("false", falseObject);

  ArrayClass = newClass("Array");
  addGlobalName("Array", ArrayClass);
  ByteArrayClass = newClass("ByteArray");
  addGlobalName("ByteArray", ByteArrayClass);

  OrderedArrayClass = newClass("OrderedArray");
  addGlobalName("OrderedArray", OrderedArrayClass);

  StringClass = newClass("String");
  addGlobalName("String", StringClass);

  TreeClass = newClass("Tree");
  addGlobalName("Tree", TreeClass);

  DictionaryClass = newClass("Dictionary");
  addGlobalName("Dictionary", DictionaryClass);

  /*
     finally, we can fill in the fields in class Object 
   */
  ObjectClass->data[methodsInClass] = newDictionary();
  ObjectClass->data[instanceSizeInClass] = newInteger(0);
  ClassClass->data[instanceSizeInClass] = newInteger(0);

  /*
     can make global name, but can't fill it in 
   */
  globalValues = gcalloc(2);
  addGlobalName("globals", globalValues);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
xorl %edi, %edi
callq 0x1289
movq %rax, 0x568c(%rip)      # 0x7140
pushq $0x7
popq %rbp
movl %ebp, %edi
callq 0x1289
movq %rax, 0x38a23(%rip)     # 0x3a4e8
leaq 0x25a0(%rip), %rbx      # 0x406c
movq %rbx, %rdi
movq %rax, %rsi
callq 0x1347
movq %rbx, %rdi
callq 0x1696
movq 0x38a02(%rip), %rcx     # 0x3a4e8
movq %rax, 0x10(%rcx)
leaq 0x25fd(%rip), %rbx      # 0x40ee
movq %rbx, %rdi
callq 0x174e
movq %rax, %r14
movq %rbx, %rdi
movq %rax, %rsi
callq 0x1347
movq 0x5632(%rip), %rsi      # 0x7140
movq %r14, 0x8(%rsi)
leaq 0x25df(%rip), %rdi      # 0x40f8
callq 0x1347
leaq 0x25db(%rip), %r14      # 0x4100
movq %r14, %rdi
callq 0x174e
movq %rax, %rbx
movq %r14, %rdi
movq %rax, %rsi
callq 0x1347
leaq 0x25ba(%rip), %r14      # 0x40fc
movq %r14, %rdi
callq 0x174e
movq %rax, %r15
movq %r14, %rdi
movq %rax, %rsi
callq 0x1347
movq %r15, 0x8(%rbx)
movq 0x55dd(%rip), %rax      # 0x7140
movq %rax, 0x18(%rbx)
leaq 0x259d(%rip), %r15      # 0x410b
movq %r15, %rdi
callq 0x174e
movq %rax, %r14
movq %r15, %rdi
movq %rax, %rsi
callq 0x1347
leaq 0x257c(%rip), %r15      # 0x4107
movq %r15, %rdi
callq 0x174e
movq %rax, %r12
movq %r15, %rdi
movq %rax, %rsi
callq 0x1347
movq %r12, 0x8(%r14)
leaq 0x2565(%rip), %r15      # 0x4111
movq %r15, %rdi
callq 0x174e
movq %rax, 0x38935(%rip)     # 0x3a4f0
movq %r15, %rdi
movq %rax, %rsi
callq 0x1347
movl %ebp, %edi
callq 0x1289
movq %rax, 0x38924(%rip)     # 0x3a4f8
leaq 0x253c(%rip), %r15      # 0x4117
movq %r15, %rdi
movq %rax, %rsi
callq 0x1347
movq %r15, %rdi
callq 0x1696
movq 0x38903(%rip), %rcx     # 0x3a4f8
movq %rax, 0x10(%rcx)
movl %ebp, %edi
callq 0x1289
movq %rax, 0x388f9(%rip)     # 0x3a500
leaq 0x250e(%rip), %r15      # 0x411c
movq %r15, %rdi
movq %rax, %rsi
callq 0x1347
movq %r15, %rdi
callq 0x1696
movq 0x388d8(%rip), %rcx     # 0x3a500
movq %rax, 0x10(%rcx)
leaq 0x24f2(%rip), %r15      # 0x4125
movq %r15, %rdi
callq 0x174e
movq %rax, 0x388c6(%rip)     # 0x3a508
movq %r15, %rdi
movq %rax, %rsi
callq 0x1347
leaq 0x24d9(%rip), %r15      # 0x412d
movq %r15, %rdi
callq 0x174e
movq %rax, %r12
movq %r15, %rdi
movq %rax, %rsi
callq 0x1347
xorl %edi, %edi
callq 0x1289
movq %rax, 0x38898(%rip)     # 0x3a510
movq %r12, 0x8(%rax)
leaq 0x24af(%rip), %rdi      # 0x4132
movq %rax, %rsi
callq 0x1347
leaq 0x24a5(%rip), %r15      # 0x4137
movq %r15, %rdi
callq 0x174e
movq %rax, %r12
movq %r15, %rdi
movq %rax, %rsi
callq 0x1347
xorl %edi, %edi
callq 0x1289
movq %rax, 0x38862(%rip)     # 0x3a518
movq %r12, 0x8(%rax)
leaq 0x247c(%rip), %rdi      # 0x413d
movq %rax, %rsi
callq 0x1347
leaq 0x247a(%rip), %r15      # 0x414a
movq %r15, %rdi
callq 0x174e
movq %rax, 0x38841(%rip)     # 0x3a520
movq %r15, %rdi
movq %rax, %rsi
callq 0x1347
leaq 0x23b8(%rip), %r15      # 0x40a9
movq %r15, %rdi
callq 0x174e
movq %r15, %rdi
movq %rax, %rsi
callq 0x1347
leaq 0x2438(%rip), %r15      # 0x4143
movq %r15, %rdi
callq 0x174e
movq %r15, %rdi
movq %rax, %rsi
callq 0x1347
leaq 0x242b(%rip), %r15      # 0x4150
movq %r15, %rdi
callq 0x174e
movq %rax, 0x387f4(%rip)     # 0x3a528
movq %r15, %rdi
movq %rax, %rsi
callq 0x1347
leaq 0x2332(%rip), %r15      # 0x4078
movq %r15, %rdi
callq 0x174e
movq %r15, %rdi
movq %rax, %rsi
callq 0x1347
leaq 0x231d(%rip), %r15      # 0x407d
movq %r15, %rdi
callq 0x174e
movq %r15, %rdi
movq %rax, %rsi
callq 0x1347
callq 0x17e7
movq %rax, 0x20(%rbx)
pushq $0x1
popq %rax
movq %rax, 0x28(%rbx)
movq %rax, 0x28(%r14)
pushq $0x2
popq %rdi
callq 0x1289
movq %rax, 0x3879a(%rip)     # 0x3a530
leaq 0x23ba(%rip), %rdi      # 0x4157
movq %rax, %rsi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x1347