abi_platforms.go (19799B)
1 package cc 2 3 import "encoding/binary" 4 5 // abiByteOrders contains byte order information for known architectures. 6 var ( 7 abiByteOrders = map[string]binary.ByteOrder{ 8 "386": binary.LittleEndian, 9 "amd64": binary.LittleEndian, 10 "arm": binary.LittleEndian, 11 "arm64": binary.LittleEndian, 12 "ppc64le": binary.LittleEndian, 13 "riscv64": binary.LittleEndian, 14 "s390x": binary.BigEndian, 15 } 16 17 abiSignedChar = map[[2]string]bool{ 18 {"freebsd", "arm"}: false, 19 {"freebsd", "arm64"}: false, 20 {"linux", "arm"}: false, 21 {"linux", "arm64"}: false, 22 {"linux", "ppc64le"}: false, 23 {"linux", "riscv64"}: false, 24 {"linux", "s390x"}: false, 25 {"netbsd", "arm"}: false, 26 27 {"darwin", "amd64"}: true, 28 {"darwin", "arm64"}: true, 29 {"freebsd", "386"}: true, 30 {"freebsd", "amd64"}: true, 31 {"linux", "386"}: true, 32 {"linux", "amd64"}: true, 33 {"netbsd", "386"}: true, 34 {"netbsd", "amd64"}: true, 35 {"openbsd", "386"}: true, 36 {"openbsd", "amd64"}: true, 37 {"openbsd", "arm64"}: true, 38 {"windows", "386"}: true, 39 {"windows", "amd64"}: true, 40 {"windows", "arm64"}: true, 41 } 42 ) 43 44 // abiTypes contains size and alignment information for known OS/arch pairs. 45 // 46 // The content is generated by ./cmd/cabi/main.c. 47 var abiTypes = map[[2]string]map[Kind]ABIType{ 48 // Linux, generated by GCC 8.3.0 49 {"linux", "amd64"}: { 50 Void: {1, 1, 1}, 51 Bool: {1, 1, 1}, 52 Char: {1, 1, 1}, 53 SChar: {1, 1, 1}, 54 UChar: {1, 1, 1}, 55 Short: {2, 2, 2}, 56 UShort: {2, 2, 2}, 57 Enum: {4, 4, 4}, 58 Int: {4, 4, 4}, 59 UInt: {4, 4, 4}, 60 Long: {8, 8, 8}, 61 ULong: {8, 8, 8}, 62 LongLong: {8, 8, 8}, 63 ULongLong: {8, 8, 8}, 64 Ptr: {8, 8, 8}, 65 Function: {8, 8, 8}, 66 Float: {4, 4, 4}, 67 Double: {8, 8, 8}, 68 LongDouble: {16, 16, 16}, 69 Int8: {1, 1, 1}, 70 UInt8: {1, 1, 1}, 71 Int16: {2, 2, 2}, 72 UInt16: {2, 2, 2}, 73 Int32: {4, 4, 4}, 74 UInt32: {4, 4, 4}, 75 Int64: {8, 8, 8}, 76 UInt64: {8, 8, 8}, 77 Int128: {16, 16, 16}, 78 UInt128: {16, 16, 16}, 79 Float32: {4, 4, 4}, 80 Float32x: {8, 8, 8}, 81 Float64: {8, 8, 8}, 82 Float64x: {16, 16, 16}, 83 Float128: {16, 16, 16}, 84 Decimal32: {4, 4, 4}, 85 Decimal64: {8, 8, 8}, 86 Decimal128: {16, 16, 16}, 87 }, 88 {"linux", "386"}: { 89 Void: {1, 1, 1}, 90 Bool: {1, 1, 1}, 91 Char: {1, 1, 1}, 92 SChar: {1, 1, 1}, 93 UChar: {1, 1, 1}, 94 Short: {2, 2, 2}, 95 UShort: {2, 2, 2}, 96 Enum: {4, 4, 4}, 97 Int: {4, 4, 4}, 98 UInt: {4, 4, 4}, 99 Long: {4, 4, 4}, 100 ULong: {4, 4, 4}, 101 LongLong: {8, 4, 4}, 102 ULongLong: {8, 4, 4}, 103 Ptr: {4, 4, 4}, 104 Function: {4, 4, 4}, 105 Float: {4, 4, 4}, 106 Double: {8, 4, 4}, 107 LongDouble: {12, 4, 4}, 108 Int8: {1, 1, 1}, 109 UInt8: {1, 1, 1}, 110 Int16: {2, 2, 2}, 111 UInt16: {2, 2, 2}, 112 Int32: {4, 4, 4}, 113 UInt32: {4, 4, 4}, 114 Int64: {8, 4, 4}, 115 UInt64: {8, 4, 4}, 116 Float32: {4, 4, 4}, 117 Float32x: {8, 4, 4}, 118 Float64: {8, 4, 4}, 119 Float64x: {12, 4, 4}, 120 Float128: {16, 16, 16}, 121 Decimal32: {4, 4, 4}, 122 Decimal64: {8, 8, 8}, 123 Decimal128: {16, 16, 16}, 124 }, 125 {"linux", "arm"}: { 126 Void: {1, 1, 1}, 127 Bool: {1, 1, 1}, 128 Char: {1, 1, 1}, 129 SChar: {1, 1, 1}, 130 UChar: {1, 1, 1}, 131 Short: {2, 2, 2}, 132 UShort: {2, 2, 2}, 133 Enum: {4, 4, 4}, 134 Int: {4, 4, 4}, 135 UInt: {4, 4, 4}, 136 Long: {4, 4, 4}, 137 ULong: {4, 4, 4}, 138 LongLong: {8, 8, 8}, 139 ULongLong: {8, 8, 8}, 140 Ptr: {4, 4, 4}, 141 Function: {4, 4, 4}, 142 Float: {4, 4, 4}, 143 Double: {8, 8, 8}, 144 LongDouble: {8, 8, 8}, 145 Int8: {1, 1, 1}, 146 UInt8: {1, 1, 1}, 147 Int16: {2, 2, 2}, 148 UInt16: {2, 2, 2}, 149 Int32: {4, 4, 4}, 150 UInt32: {4, 4, 4}, 151 Int64: {8, 8, 8}, 152 UInt64: {8, 8, 8}, 153 }, 154 {"linux", "arm64"}: { 155 Void: {1, 1, 1}, 156 Bool: {1, 1, 1}, 157 Char: {1, 1, 1}, 158 SChar: {1, 1, 1}, 159 UChar: {1, 1, 1}, 160 Short: {2, 2, 2}, 161 UShort: {2, 2, 2}, 162 Enum: {4, 4, 4}, 163 Int: {4, 4, 4}, 164 UInt: {4, 4, 4}, 165 Long: {8, 8, 8}, 166 ULong: {8, 8, 8}, 167 LongLong: {8, 8, 8}, 168 ULongLong: {8, 8, 8}, 169 Ptr: {8, 8, 8}, 170 Function: {8, 8, 8}, 171 Float: {4, 4, 4}, 172 Double: {8, 8, 8}, 173 LongDouble: {16, 16, 16}, 174 Int8: {1, 1, 1}, 175 UInt8: {1, 1, 1}, 176 Int16: {2, 2, 2}, 177 UInt16: {2, 2, 2}, 178 Int32: {4, 4, 4}, 179 UInt32: {4, 4, 4}, 180 Int64: {8, 8, 8}, 181 UInt64: {8, 8, 8}, 182 Int128: {16, 16, 16}, 183 UInt128: {16, 16, 16}, 184 }, 185 // $ x86_64-w64-mingw32-gcc main.c && wine a.exe 186 {"windows", "amd64"}: { 187 Void: {1, 1, 1}, 188 Bool: {1, 1, 1}, 189 Char: {1, 1, 1}, 190 SChar: {1, 1, 1}, 191 UChar: {1, 1, 1}, 192 Short: {2, 2, 2}, 193 UShort: {2, 2, 2}, 194 Enum: {4, 4, 4}, 195 Int: {4, 4, 4}, 196 UInt: {4, 4, 4}, 197 Long: {4, 4, 4}, 198 ULong: {4, 4, 4}, 199 LongLong: {8, 8, 8}, 200 ULongLong: {8, 8, 8}, 201 Ptr: {8, 8, 8}, 202 Function: {8, 8, 8}, 203 Float: {4, 4, 4}, 204 Double: {8, 8, 8}, 205 LongDouble: {16, 16, 16}, 206 Int8: {1, 1, 1}, 207 UInt8: {1, 1, 1}, 208 Int16: {2, 2, 2}, 209 UInt16: {2, 2, 2}, 210 Int32: {4, 4, 4}, 211 UInt32: {4, 4, 4}, 212 Int64: {8, 8, 8}, 213 UInt64: {8, 8, 8}, 214 Int128: {16, 16, 16}, 215 UInt128: {16, 16, 16}, 216 Float32: {4, 4, 4}, 217 Float32x: {8, 8, 8}, 218 Float64: {8, 8, 8}, 219 Float64x: {16, 16, 16}, 220 Float128: {16, 16, 16}, 221 Decimal32: {4, 4, 4}, 222 Decimal64: {8, 8, 8}, 223 Decimal128: {16, 16, 16}, 224 }, 225 // clang version 14.0.0 (https://github.com/llvm/llvm-project.git 329fda39c507e8740978d10458451dcdb21563be) 226 // Target: aarch64-w64-windows-gnu 227 {"windows", "arm64"}: { 228 Void: {1, 1, 1}, 229 Bool: {1, 1, 1}, 230 Char: {1, 1, 1}, 231 SChar: {1, 1, 1}, 232 UChar: {1, 1, 1}, 233 Short: {2, 2, 2}, 234 UShort: {2, 2, 2}, 235 Enum: {4, 4, 4}, 236 Int: {4, 4, 4}, 237 UInt: {4, 4, 4}, 238 Long: {4, 4, 4}, 239 ULong: {4, 4, 4}, 240 LongLong: {8, 8, 8}, 241 ULongLong: {8, 8, 8}, 242 Ptr: {8, 8, 8}, 243 Function: {8, 8, 8}, 244 Float: {4, 4, 4}, 245 Double: {8, 8, 8}, 246 LongDouble: {8, 8, 8}, 247 }, 248 // $ i686-w64-mingw32-gcc main.c && wine a.exe 249 {"windows", "386"}: { 250 Void: {1, 1, 1}, 251 Bool: {1, 1, 1}, 252 Char: {1, 1, 1}, 253 SChar: {1, 1, 1}, 254 UChar: {1, 1, 1}, 255 Short: {2, 2, 2}, 256 UShort: {2, 2, 2}, 257 Enum: {4, 4, 4}, 258 Int: {4, 4, 4}, 259 UInt: {4, 4, 4}, 260 Long: {4, 4, 4}, 261 ULong: {4, 4, 4}, 262 LongLong: {8, 8, 8}, 263 ULongLong: {8, 8, 8}, 264 Ptr: {4, 4, 4}, 265 Function: {4, 4, 4}, 266 Float: {4, 4, 4}, 267 Double: {8, 8, 8}, 268 LongDouble: {12, 4, 4}, 269 Int8: {1, 1, 1}, 270 UInt8: {1, 1, 1}, 271 Int16: {2, 2, 2}, 272 UInt16: {2, 2, 2}, 273 Int32: {4, 4, 4}, 274 UInt32: {4, 4, 4}, 275 Int64: {8, 8, 8}, 276 UInt64: {8, 8, 8}, 277 Float32: {4, 4, 4}, 278 Float32x: {8, 8, 8}, 279 Float64: {8, 8, 8}, 280 Float64x: {12, 4, 4}, 281 Float128: {16, 16, 16}, 282 Decimal32: {4, 4, 4}, 283 Decimal64: {8, 8, 8}, 284 Decimal128: {16, 16, 16}, 285 }, 286 {"darwin", "amd64"}: { 287 Void: {1, 1, 1}, 288 Bool: {1, 1, 1}, 289 Char: {1, 1, 1}, 290 SChar: {1, 1, 1}, 291 UChar: {1, 1, 1}, 292 Short: {2, 2, 2}, 293 UShort: {2, 2, 2}, 294 Enum: {4, 4, 4}, 295 Int: {4, 4, 4}, 296 UInt: {4, 4, 4}, 297 Long: {8, 8, 8}, 298 ULong: {8, 8, 8}, 299 LongLong: {8, 8, 8}, 300 ULongLong: {8, 8, 8}, 301 Ptr: {8, 8, 8}, 302 Function: {8, 8, 8}, 303 Float: {4, 4, 4}, 304 Double: {8, 8, 8}, 305 LongDouble: {16, 16, 16}, 306 Int8: {1, 1, 1}, 307 UInt8: {1, 1, 1}, 308 Int16: {2, 2, 2}, 309 UInt16: {2, 2, 2}, 310 Int32: {4, 4, 4}, 311 UInt32: {4, 4, 4}, 312 Int64: {8, 8, 8}, 313 UInt64: {8, 8, 8}, 314 Int128: {16, 16, 16}, 315 UInt128: {16, 16, 16}, 316 }, 317 {"darwin", "arm64"}: { 318 Void: {1, 1, 1}, 319 Bool: {1, 1, 1}, 320 Char: {1, 1, 1}, 321 SChar: {1, 1, 1}, 322 UChar: {1, 1, 1}, 323 Short: {2, 2, 2}, 324 UShort: {2, 2, 2}, 325 Enum: {4, 4, 4}, 326 Int: {4, 4, 4}, 327 UInt: {4, 4, 4}, 328 Long: {8, 8, 8}, 329 ULong: {8, 8, 8}, 330 LongLong: {8, 8, 8}, 331 ULongLong: {8, 8, 8}, 332 Ptr: {8, 8, 8}, 333 Function: {8, 8, 8}, 334 Float: {4, 4, 4}, 335 Double: {8, 8, 8}, 336 LongDouble: {8, 8, 8}, 337 Int8: {1, 1, 1}, 338 UInt8: {1, 1, 1}, 339 Int16: {2, 2, 2}, 340 UInt16: {2, 2, 2}, 341 Int32: {4, 4, 4}, 342 UInt32: {4, 4, 4}, 343 Int64: {8, 8, 8}, 344 UInt64: {8, 8, 8}, 345 Int128: {16, 16, 16}, 346 UInt128: {16, 16, 16}, 347 }, 348 // gcc (SUSE Linux) 7.5.0 349 {"linux", "s390x"}: { 350 Void: {1, 1, 1}, 351 Bool: {1, 1, 1}, 352 Char: {1, 1, 1}, 353 SChar: {1, 1, 1}, 354 UChar: {1, 1, 1}, 355 Short: {2, 2, 2}, 356 UShort: {2, 2, 2}, 357 Enum: {4, 4, 4}, 358 Int: {4, 4, 4}, 359 UInt: {4, 4, 4}, 360 Long: {8, 8, 8}, 361 ULong: {8, 8, 8}, 362 LongLong: {8, 8, 8}, 363 ULongLong: {8, 8, 8}, 364 Ptr: {8, 8, 8}, 365 Function: {8, 8, 8}, 366 Float: {4, 4, 4}, 367 Double: {8, 8, 8}, 368 LongDouble: {16, 8, 8}, 369 Int8: {1, 1, 1}, 370 UInt8: {1, 1, 1}, 371 Int16: {2, 2, 2}, 372 UInt16: {2, 2, 2}, 373 Int32: {4, 4, 4}, 374 UInt32: {4, 4, 4}, 375 Int64: {8, 8, 8}, 376 UInt64: {8, 8, 8}, 377 Int128: {16, 8, 8}, 378 UInt128: {16, 8, 8}, 379 Float32: {4, 4, 4}, 380 Float32x: {8, 8, 8}, 381 Float64: {8, 8, 8}, 382 Float64x: {16, 8, 8}, 383 Float128: {16, 8, 8}, 384 Decimal32: {4, 4, 4}, 385 Decimal64: {8, 8, 8}, 386 Decimal128: {16, 8, 8}, 387 }, 388 // gcc (FreeBSD Ports Collection) 10.3.0 389 {"freebsd", "amd64"}: { 390 Void: {1, 1, 1}, 391 Bool: {1, 1, 1}, 392 Char: {1, 1, 1}, 393 SChar: {1, 1, 1}, 394 UChar: {1, 1, 1}, 395 Short: {2, 2, 2}, 396 UShort: {2, 2, 2}, 397 Enum: {4, 4, 4}, 398 Int: {4, 4, 4}, 399 UInt: {4, 4, 4}, 400 Long: {8, 8, 8}, 401 ULong: {8, 8, 8}, 402 LongLong: {8, 8, 8}, 403 ULongLong: {8, 8, 8}, 404 Ptr: {8, 8, 8}, 405 Function: {8, 8, 8}, 406 Float: {4, 4, 4}, 407 Double: {8, 8, 8}, 408 LongDouble: {16, 16, 16}, 409 Int8: {1, 1, 1}, 410 UInt8: {1, 1, 1}, 411 Int16: {2, 2, 2}, 412 UInt16: {2, 2, 2}, 413 Int32: {4, 4, 4}, 414 UInt32: {4, 4, 4}, 415 Int64: {8, 8, 8}, 416 UInt64: {8, 8, 8}, 417 Int128: {16, 16, 16}, 418 UInt128: {16, 16, 16}, 419 }, 420 // gcc (FreeBSD Ports Collection) 11.3.0 421 {"freebsd", "arm64"}: { 422 Void: {1, 1, 1}, 423 Bool: {1, 1, 1}, 424 Char: {1, 1, 1}, 425 SChar: {1, 1, 1}, 426 UChar: {1, 1, 1}, 427 Short: {2, 2, 2}, 428 UShort: {2, 2, 2}, 429 Enum: {4, 4, 4}, 430 Int: {4, 4, 4}, 431 UInt: {4, 4, 4}, 432 Long: {8, 8, 8}, 433 ULong: {8, 8, 8}, 434 LongLong: {8, 8, 8}, 435 ULongLong: {8, 8, 8}, 436 Ptr: {8, 8, 8}, 437 Function: {8, 8, 8}, 438 Float: {4, 4, 4}, 439 Double: {8, 8, 8}, 440 LongDouble: {16, 16, 16}, 441 Int8: {1, 1, 1}, 442 UInt8: {1, 1, 1}, 443 Int16: {2, 2, 2}, 444 UInt16: {2, 2, 2}, 445 Int32: {4, 4, 4}, 446 UInt32: {4, 4, 4}, 447 Int64: {8, 8, 8}, 448 UInt64: {8, 8, 8}, 449 Int128: {16, 16, 16}, 450 UInt128: {16, 16, 16}, 451 }, 452 // gcc (FreeBSD Ports Collection) 10.3.0 453 {"freebsd", "386"}: { 454 Void: {1, 1, 1}, 455 Bool: {1, 1, 1}, 456 Char: {1, 1, 1}, 457 SChar: {1, 1, 1}, 458 UChar: {1, 1, 1}, 459 Short: {2, 2, 2}, 460 UShort: {2, 2, 2}, 461 Enum: {4, 4, 4}, 462 Int: {4, 4, 4}, 463 UInt: {4, 4, 4}, 464 Long: {4, 4, 4}, 465 ULong: {4, 4, 4}, 466 LongLong: {8, 4, 4}, 467 ULongLong: {8, 4, 4}, 468 Ptr: {4, 4, 4}, 469 Function: {4, 4, 4}, 470 Float: {4, 4, 4}, 471 Double: {8, 4, 4}, 472 LongDouble: {12, 4, 4}, 473 Int8: {1, 1, 1}, 474 UInt8: {1, 1, 1}, 475 Int16: {2, 2, 2}, 476 UInt16: {2, 2, 2}, 477 Int32: {4, 4, 4}, 478 UInt32: {4, 4, 4}, 479 Int64: {8, 4, 4}, 480 UInt64: {8, 4, 4}, 481 Float32: {4, 4, 4}, 482 Float32x: {8, 4, 4}, 483 Float64: {8, 4, 4}, 484 Float64x: {16, 16, 16}, 485 Float128: {16, 16, 16}, 486 }, 487 // gcc (FreeBSD Ports Collection) 11.3.0 488 {"freebsd", "arm"}: { 489 Void: {1, 1, 1}, 490 Bool: {1, 1, 1}, 491 Char: {1, 1, 1}, 492 SChar: {1, 1, 1}, 493 UChar: {1, 1, 1}, 494 Short: {2, 2, 2}, 495 UShort: {2, 2, 2}, 496 Enum: {4, 4, 4}, 497 Int: {4, 4, 4}, 498 UInt: {4, 4, 4}, 499 Long: {4, 4, 4}, 500 ULong: {4, 4, 4}, 501 LongLong: {8, 8, 8}, 502 ULongLong: {8, 8, 8}, 503 Ptr: {4, 4, 4}, 504 Function: {4, 4, 4}, 505 Float: {4, 4, 4}, 506 Double: {8, 8, 8}, 507 LongDouble: {8, 8, 8}, 508 Int8: {1, 1, 1}, 509 UInt8: {1, 1, 1}, 510 Int16: {2, 2, 2}, 511 UInt16: {2, 2, 2}, 512 Int32: {4, 4, 4}, 513 UInt32: {4, 4, 4}, 514 Int64: {8, 8, 8}, 515 UInt64: {8, 8, 8}, 516 }, 517 // gcc (GCC) 8.4.0 518 {"openbsd", "amd64"}: { 519 Void: {1, 1, 1}, 520 Bool: {1, 1, 1}, 521 Char: {1, 1, 1}, 522 SChar: {1, 1, 1}, 523 UChar: {1, 1, 1}, 524 Short: {2, 2, 2}, 525 UShort: {2, 2, 2}, 526 Enum: {4, 4, 4}, 527 Int: {4, 4, 4}, 528 UInt: {4, 4, 4}, 529 Long: {8, 8, 8}, 530 ULong: {8, 8, 8}, 531 LongLong: {8, 8, 8}, 532 ULongLong: {8, 8, 8}, 533 Ptr: {8, 8, 8}, 534 Function: {8, 8, 8}, 535 Float: {4, 4, 4}, 536 Double: {8, 8, 8}, 537 LongDouble: {16, 16, 16}, 538 Int8: {1, 1, 1}, 539 UInt8: {1, 1, 1}, 540 Int16: {2, 2, 2}, 541 UInt16: {2, 2, 2}, 542 Int32: {4, 4, 4}, 543 UInt32: {4, 4, 4}, 544 Int64: {8, 8, 8}, 545 UInt64: {8, 8, 8}, 546 Int128: {16, 16, 16}, 547 UInt128: {16, 16, 16}, 548 Float32: {4, 4, 4}, 549 Float32x: {8, 8, 8}, 550 Float64: {8, 8, 8}, 551 Float64x: {16, 16, 16}, 552 Float128: {16, 16, 16}, 553 }, 554 // OpenBSD clang version 13.0.0 555 {"openbsd", "arm64"}: { 556 Void: {1, 1, 1}, 557 Bool: {1, 1, 1}, 558 Char: {1, 1, 1}, 559 SChar: {1, 1, 1}, 560 UChar: {1, 1, 1}, 561 Short: {2, 2, 2}, 562 UShort: {2, 2, 2}, 563 Enum: {4, 4, 4}, 564 Int: {4, 4, 4}, 565 UInt: {4, 4, 4}, 566 Long: {8, 8, 8}, 567 ULong: {8, 8, 8}, 568 LongLong: {8, 8, 8}, 569 ULongLong: {8, 8, 8}, 570 Ptr: {8, 8, 8}, 571 Function: {8, 8, 8}, 572 Float: {4, 4, 4}, 573 Double: {8, 8, 8}, 574 LongDouble: {16, 16, 16}, 575 Int8: {1, 1, 1}, 576 UInt8: {1, 1, 1}, 577 Int16: {2, 2, 2}, 578 UInt16: {2, 2, 2}, 579 Int32: {4, 4, 4}, 580 UInt32: {4, 4, 4}, 581 Int64: {8, 8, 8}, 582 UInt64: {8, 8, 8}, 583 Int128: {16, 16, 16}, 584 UInt128: {16, 16, 16}, 585 }, 586 // OpenBSD clang version 13.0.0 587 {"openbsd", "386"}: { 588 Void: {1, 1, 1}, 589 Bool: {1, 1, 1}, 590 Char: {1, 1, 1}, 591 SChar: {1, 1, 1}, 592 UChar: {1, 1, 1}, 593 Short: {2, 2, 2}, 594 UShort: {2, 2, 2}, 595 Enum: {4, 4, 4}, 596 Int: {4, 4, 4}, 597 UInt: {4, 4, 4}, 598 Long: {4, 4, 4}, 599 ULong: {4, 4, 4}, 600 LongLong: {8, 4, 4}, 601 ULongLong: {8, 4, 4}, 602 Ptr: {4, 4, 4}, 603 Function: {4, 4, 4}, 604 Float: {4, 4, 4}, 605 Double: {8, 4, 4}, 606 LongDouble: {12, 4, 4}, 607 Int8: {1, 1, 1}, 608 UInt8: {1, 1, 1}, 609 Int16: {2, 2, 2}, 610 UInt16: {2, 2, 2}, 611 Int32: {4, 4, 4}, 612 UInt32: {4, 4, 4}, 613 Int64: {8, 4, 4}, 614 UInt64: {8, 4, 4}, 615 }, 616 // gcc (GCC) 10.3.0 617 {"netbsd", "amd64"}: { 618 Void: {1, 1, 1}, 619 Bool: {1, 1, 1}, 620 Char: {1, 1, 1}, 621 SChar: {1, 1, 1}, 622 UChar: {1, 1, 1}, 623 Short: {2, 2, 2}, 624 UShort: {2, 2, 2}, 625 Enum: {4, 4, 4}, 626 Int: {4, 4, 4}, 627 UInt: {4, 4, 4}, 628 Long: {8, 8, 8}, 629 ULong: {8, 8, 8}, 630 LongLong: {8, 8, 8}, 631 ULongLong: {8, 8, 8}, 632 Ptr: {8, 8, 8}, 633 Function: {8, 8, 8}, 634 Float: {4, 4, 4}, 635 Double: {8, 8, 8}, 636 LongDouble: {16, 16, 16}, 637 Int8: {1, 1, 1}, 638 UInt8: {1, 1, 1}, 639 Int16: {2, 2, 2}, 640 UInt16: {2, 2, 2}, 641 Int32: {4, 4, 4}, 642 UInt32: {4, 4, 4}, 643 Int64: {8, 8, 8}, 644 UInt64: {8, 8, 8}, 645 Int128: {16, 16, 16}, 646 UInt128: {16, 16, 16}, 647 }, 648 // gcc (nb4 20200810) 7.5.0 649 {"netbsd", "arm"}: { 650 Void: {1, 1, 1}, 651 Bool: {1, 1, 1}, 652 Char: {1, 1, 1}, 653 SChar: {1, 1, 1}, 654 UChar: {1, 1, 1}, 655 Short: {2, 2, 2}, 656 UShort: {2, 2, 2}, 657 Enum: {4, 4, 4}, 658 Int: {4, 4, 4}, 659 UInt: {4, 4, 4}, 660 Long: {4, 4, 4}, 661 ULong: {4, 4, 4}, 662 LongLong: {8, 8, 8}, 663 ULongLong: {8, 8, 8}, 664 Ptr: {4, 4, 4}, 665 Function: {4, 4, 4}, 666 Float: {4, 4, 4}, 667 Double: {8, 8, 8}, 668 LongDouble: {8, 8, 8}, 669 Int8: {1, 1, 1}, 670 UInt8: {1, 1, 1}, 671 Int16: {2, 2, 2}, 672 UInt16: {2, 2, 2}, 673 Int32: {4, 4, 4}, 674 UInt32: {4, 4, 4}, 675 Int64: {8, 8, 8}, 676 UInt64: {8, 8, 8}, 677 }, 678 // gcc (nb4 20200810) 7.5.0 679 {"netbsd", "386"}: { 680 Void: {1, 1, 1}, 681 Bool: {1, 1, 1}, 682 Char: {1, 1, 1}, 683 SChar: {1, 1, 1}, 684 UChar: {1, 1, 1}, 685 Short: {2, 2, 2}, 686 UShort: {2, 2, 2}, 687 Enum: {4, 4, 4}, 688 Int: {4, 4, 4}, 689 UInt: {4, 4, 4}, 690 Long: {4, 4, 4}, 691 ULong: {4, 4, 4}, 692 LongLong: {8, 4, 4}, 693 ULongLong: {8, 4, 4}, 694 Ptr: {4, 4, 4}, 695 Function: {4, 4, 4}, 696 Float: {4, 4, 4}, 697 Double: {8, 4, 4}, 698 LongDouble: {12, 4, 4}, 699 Int8: {1, 1, 1}, 700 UInt8: {1, 1, 1}, 701 Int16: {2, 2, 2}, 702 UInt16: {2, 2, 2}, 703 Int32: {4, 4, 4}, 704 UInt32: {4, 4, 4}, 705 Int64: {8, 4, 4}, 706 UInt64: {8, 4, 4}, 707 Float32: {4, 4, 4}, 708 Float32x: {8, 4, 4}, 709 Float64: {8, 4, 4}, 710 Float64x: {12, 4, 4}, 711 Float128: {16, 16, 16}, 712 }, 713 // gcc (Ubuntu 11.2.0-7ubuntu2) 11.2.0 714 {"linux", "riscv64"}: { 715 Void: {1, 1, 1}, 716 Bool: {1, 1, 1}, 717 Char: {1, 1, 1}, 718 SChar: {1, 1, 1}, 719 UChar: {1, 1, 1}, 720 Short: {2, 2, 2}, 721 UShort: {2, 2, 2}, 722 Enum: {4, 4, 4}, 723 Int: {4, 4, 4}, 724 UInt: {4, 4, 4}, 725 Long: {8, 8, 8}, 726 ULong: {8, 8, 8}, 727 LongLong: {8, 8, 8}, 728 ULongLong: {8, 8, 8}, 729 Ptr: {8, 8, 8}, 730 Function: {8, 8, 8}, 731 Float: {4, 4, 4}, 732 Double: {8, 8, 8}, 733 LongDouble: {16, 16, 16}, 734 Int8: {1, 1, 1}, 735 UInt8: {1, 1, 1}, 736 Int16: {2, 2, 2}, 737 UInt16: {2, 2, 2}, 738 Int32: {4, 4, 4}, 739 UInt32: {4, 4, 4}, 740 Int64: {8, 8, 8}, 741 UInt64: {8, 8, 8}, 742 Int128: {16, 16, 16}, 743 UInt128: {16, 16, 16}, 744 Float32: {4, 4, 4}, 745 Float32x: {8, 8, 8}, 746 Float64: {8, 8, 8}, 747 Float64x: {16, 16, 16}, 748 Float128: {16, 16, 16}, 749 }, 750 // gcc (Debian 10.2.1-6) 10.2.1 20210110 751 {"linux", "ppc64le"}: { 752 Void: {1, 1, 1}, 753 Bool: {1, 1, 1}, 754 Char: {1, 1, 1}, 755 SChar: {1, 1, 1}, 756 UChar: {1, 1, 1}, 757 Short: {2, 2, 2}, 758 UShort: {2, 2, 2}, 759 Enum: {4, 4, 4}, 760 Int: {4, 4, 4}, 761 UInt: {4, 4, 4}, 762 Long: {8, 8, 8}, 763 ULong: {8, 8, 8}, 764 LongLong: {8, 8, 8}, 765 ULongLong: {8, 8, 8}, 766 Ptr: {8, 8, 8}, 767 Function: {8, 8, 8}, 768 Float: {4, 4, 4}, 769 Double: {8, 8, 8}, 770 LongDouble: {16, 16, 16}, 771 Int8: {1, 1, 1}, 772 UInt8: {1, 1, 1}, 773 Int16: {2, 2, 2}, 774 UInt16: {2, 2, 2}, 775 Int32: {4, 4, 4}, 776 UInt32: {4, 4, 4}, 777 Int64: {8, 8, 8}, 778 UInt64: {8, 8, 8}, 779 Int128: {16, 16, 16}, 780 UInt128: {16, 16, 16}, 781 Float32: {4, 4, 4}, 782 Float32x: {8, 8, 8}, 783 Float64: {8, 8, 8}, 784 Float64x: {16, 16, 16}, 785 Float128: {16, 16, 16}, 786 Decimal32: {4, 4, 4}, 787 Decimal64: {8, 8, 8}, 788 Decimal128: {16, 16, 16}, 789 }, 790 }