github.com/bgentry/go@v0.0.0-20150121062915-6cf5a733d54d/src/cmd/8g/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 = '8'; 10 char* thestring = "386"; 11 LinkArch* thelinkarch = &link386; 12 13 void 14 linkarchinit(void) 15 { 16 } 17 18 vlong MAXWIDTH = (1LL<<32) - 1; 19 20 /* 21 * go declares several platform-specific type aliases: 22 * int, uint, float, and uintptr 23 */ 24 Typedef typedefs[] = 25 { 26 {"int", TINT, TINT32}, 27 {"uint", TUINT, TUINT32}, 28 {"uintptr", TUINTPTR, TUINT32}, 29 {0} 30 }; 31 32 void 33 betypeinit(void) 34 { 35 widthptr = 4; 36 widthint = 4; 37 widthreg = 4; 38 39 zprog.link = P; 40 zprog.as = AGOK; 41 zprog.from.type = D_NONE; 42 zprog.from.index = D_NONE; 43 zprog.from.scale = 0; 44 zprog.to = zprog.from; 45 46 listinit8(); 47 }