github.com/xushiwei/go@v0.0.0-20130601165731-2b9d83f45bc9/src/cmd/5g/galign.c (about)

     1  // Copyright 2009 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  #include <u.h>
     6  #include <libc.h>
     7  #include "gg.h"
     8  
     9  int	thechar	= '5';
    10  char*	thestring	= "arm";
    11  
    12  vlong MAXWIDTH = (1LL<<32) - 1;
    13  
    14  /*
    15   * go declares several platform-specific type aliases:
    16   * int, uint, float, and uintptr
    17   */
    18  Typedef	typedefs[] =
    19  {
    20  	"int",		TINT,		TINT32,
    21  	"uint",		TUINT,		TUINT32,
    22  	"uintptr",	TUINTPTR,	TUINT32,
    23  	0
    24  };
    25  
    26  void
    27  betypeinit(void)
    28  {
    29  	widthptr = 4;
    30  	widthint = 4;
    31  
    32  	zprog.link = P;
    33  	zprog.as = AGOK;
    34  	zprog.scond = C_SCOND_NONE;
    35  	zprog.reg = NREG;
    36  	zprog.from.type = D_NONE;
    37  	zprog.from.name = D_NONE;
    38  	zprog.from.reg = NREG;
    39  	zprog.to = zprog.from;
    40  
    41  	listinit();
    42  }