• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..20-Aug-2021-

linux/H20-Aug-2021-4,8833,859

.gitignoreH A D20-Aug-202116 32

README.mdH A D20-Aug-20218.5 KiB185138

affinity_linux.goH A D20-Aug-20211.9 KiB8757

aliases.goH A D20-Aug-2021484 165

asm_aix_ppc64.sH A D20-Aug-2021420 195

asm_bsd_386.sH A D20-Aug-2021742 3011

asm_bsd_amd64.sH A D20-Aug-2021785 3011

asm_bsd_arm.sH A D20-Aug-2021732 3011

asm_bsd_arm64.sH A D20-Aug-2021762 3011

asm_linux_386.sH A D20-Aug-20211.4 KiB6740

asm_linux_amd64.sH A D20-Aug-20211.2 KiB5937

asm_linux_arm.sH A D20-Aug-20211.1 KiB5836

asm_linux_arm64.sH A D20-Aug-20211.1 KiB5435

asm_linux_mips64x.sH A D20-Aug-20211.2 KiB5835

asm_linux_mipsx.sH A D20-Aug-20211.2 KiB5632

asm_linux_ppc64x.sH A D20-Aug-2021962 4627

asm_linux_riscv64.sH A D20-Aug-20211 KiB5029

asm_linux_s390x.sH A D20-Aug-20211.2 KiB5835

asm_openbsd_mips64.sH A D20-Aug-2021690 3111

asm_solaris_amd64.sH A D20-Aug-2021436 195

asm_zos_s390x.sH A D20-Aug-20218.4 KiB427314

bluetooth_linux.goH A D20-Aug-2021680 3725

cap_freebsd.goH A D20-Aug-20215 KiB197148

constants.goH A D20-Aug-2021390 156

creds_test.goH A D20-Aug-20212.9 KiB12194

darwin_test.goH A D20-Aug-20218.3 KiB211170

dev_aix_ppc.goH A D20-Aug-2021757 2810

dev_aix_ppc64.goH A D20-Aug-2021878 3012

dev_darwin.goH A D20-Aug-2021747 2510

dev_dragonfly.goH A D20-Aug-20211 KiB3110

dev_freebsd.goH A D20-Aug-20211,013 3110

dev_linux.goH A D20-Aug-20211.5 KiB4318

dev_linux_test.goH A D20-Aug-20211.5 KiB5843

dev_netbsd.goH A D20-Aug-2021913 3015

dev_openbsd.goH A D20-Aug-2021918 3015

dev_zos.goH A D20-Aug-2021850 3010

dev_zos_test.goH A D20-Aug-20211.4 KiB5842

dirent.goH A D20-Aug-20213.1 KiB10485

dirent_test.goH A D20-Aug-20213.5 KiB152125

endian_big.goH A D20-Aug-2021421 112

endian_little.goH A D20-Aug-2021451 112

env_unix.goH A D20-Aug-2021717 3317

epoll_zos.goH A D20-Aug-20215 KiB222155

epoll_zos_test.goH A D20-Aug-20216.3 KiB278207

errors_freebsd_386.goH A D20-Aug-20219.4 KiB234225

errors_freebsd_amd64.goH A D20-Aug-20219.4 KiB234225

errors_freebsd_arm.goH A D20-Aug-20218.8 KiB227219

errors_freebsd_arm64.goH A D20-Aug-2021481 189

example_exec_test.goH A D20-Aug-2021494 2110

example_flock_test.goH A D20-Aug-2021677 2715

export_test.goH A D20-Aug-2021349 112

fcntl.goH A D20-Aug-20211.1 KiB3821

fcntl_darwin.goH A D20-Aug-2021806 2513

fcntl_linux_32bit.goH A D20-Aug-2021500 154

fdset.goH A D20-Aug-2021853 3115

fdset_test.goH A D20-Aug-20211.3 KiB6548

fstatfs_zos.goH A D20-Aug-20214.1 KiB165146

fstatfs_zos_test.goH A D20-Aug-20211.8 KiB7457

gccgo.goH A D20-Aug-20211.9 KiB6140

gccgo_c.cH A D20-Aug-20211.5 KiB4628

gccgo_linux_amd64.goH A D20-Aug-2021464 2210

getdirentries_test.goH A D20-Aug-20211.9 KiB8569

ifreq_linux.goH A D20-Aug-20214.5 KiB15072

ifreq_linux_test.goH A D20-Aug-20214.6 KiB187131

ioctl.goH A D20-Aug-20212.5 KiB7637

ioctl_linux.goH A D20-Aug-20216.5 KiB197131

ioctl_zos.goH A D20-Aug-20212.1 KiB7539

mkall.shH A D20-Aug-20218 KiB232196

mkasm_darwin.goH A D20-Aug-20212.7 KiB8767

mkerrors.shH A D20-Aug-202118.8 KiB758675

mkmerge.goH A D20-Aug-202112.9 KiB524369

mkmerge_test.goH A D20-Aug-202110.6 KiB507373

mkpost.goH A D20-Aug-20216.6 KiB17698

mksyscall.goH A D20-Aug-202112.1 KiB400304

mksyscall_aix_ppc.goH A D20-Aug-202112.3 KiB421324

mksyscall_aix_ppc64.goH A D20-Aug-202119.1 KiB620437

mksyscall_solaris.goH A D20-Aug-20219.7 KiB347254

mksysctl_openbsd.goH A D20-Aug-20218.1 KiB359293

mksysnum.goH A D20-Aug-20214.5 KiB191142

mmap_unix_test.goH A D20-Aug-20211 KiB4329

mmap_zos_test.goH A D20-Aug-20212.1 KiB8864

openbsd_test.goH A D20-Aug-20212.5 KiB11587

pagesize_unix.goH A D20-Aug-2021457 175

pipe2_test.goH A D20-Aug-20212.1 KiB9681

pledge_openbsd.goH A D20-Aug-20213.7 KiB164102

ptrace_darwin.goH A D20-Aug-2021337 134

ptrace_ios.goH A D20-Aug-2021298 134

race.goH A D20-Aug-2021675 3218

race0.goH A D20-Aug-2021643 2713

readdirent_getdents.goH A D20-Aug-2021454 144

readdirent_getdirentries.goH A D20-Aug-2021715 216

sendfile_test.goH A D20-Aug-20212.5 KiB10578

sockcmsg_dragonfly.goH A D20-Aug-2021544 178

sockcmsg_linux.goH A D20-Aug-20211 KiB3721

sockcmsg_unix.goH A D20-Aug-20212.7 KiB9464

sockcmsg_unix_other.goH A D20-Aug-20211.3 KiB4825

str.goH A D20-Aug-2021705 2818

syscall.goH A D20-Aug-20213 KiB9647

syscall_aix.goH A D20-Aug-202115.5 KiB554315

syscall_aix_ppc.goH A D20-Aug-20211.4 KiB5531

syscall_aix_ppc64.goH A D20-Aug-20212 KiB8656

syscall_aix_test.goH A D20-Aug-20212.1 KiB10981

syscall_bsd.goH A D20-Aug-202116.2 KiB665504

syscall_bsd_test.goH A D20-Aug-20211.8 KiB8669

syscall_darwin.1_12.goH A D20-Aug-2021885 3319

syscall_darwin.1_13.goH A D20-Aug-20212.7 KiB10965

syscall_darwin.goH A D20-Aug-202120.2 KiB722270

syscall_darwin_amd64.goH A D20-Aug-20211.5 KiB5226

syscall_darwin_arm64.goH A D20-Aug-20211.4 KiB5226

syscall_darwin_libSystem.goH A D20-Aug-20211.2 KiB289

syscall_darwin_test.goH A D20-Aug-20215.6 KiB259211

syscall_dragonfly.goH A D20-Aug-202114.3 KiB542168

syscall_dragonfly_amd64.goH A D20-Aug-20211.3 KiB5838

syscall_freebsd.goH A D20-Aug-202124.4 KiB873423

syscall_freebsd_386.goH A D20-Aug-20211.8 KiB6846

syscall_freebsd_amd64.goH A D20-Aug-20211.7 KiB6846

syscall_freebsd_arm.goH A D20-Aug-20211.6 KiB6443

syscall_freebsd_arm64.goH A D20-Aug-20211.6 KiB6443

syscall_freebsd_test.goH A D20-Aug-20218.2 KiB350282

syscall_illumos.goH A D20-Aug-20214 KiB179131

syscall_illumos_test.goH A D20-Aug-2021573 2716

syscall_internal_bsd_test.goH A D20-Aug-20213.2 KiB156132

syscall_internal_darwin_test.goH A D20-Aug-20212.7 KiB132117

syscall_internal_linux_test.goH A D20-Aug-202118.3 KiB865797

syscall_linux.goH A D20-Aug-202169.4 KiB2,4151,528

syscall_linux_386.goH A D20-Aug-202110.7 KiB393277

syscall_linux_amd64.goH A D20-Aug-20216.6 KiB20095

syscall_linux_amd64_gc.goH A D20-Aug-2021315 143

syscall_linux_arm.goH A D20-Aug-20218.7 KiB292173

syscall_linux_arm64.goH A D20-Aug-20217.5 KiB251148

syscall_linux_gc.goH A D20-Aug-2021514 163

syscall_linux_gc_386.goH A D20-Aug-2021608 185

syscall_linux_gc_arm.goH A D20-Aug-2021434 153

syscall_linux_gccgo_386.goH A D20-Aug-20211,012 3220

syscall_linux_gccgo_arm.goH A D20-Aug-2021622 2212

syscall_linux_mips64x.goH A D20-Aug-20217 KiB236137

syscall_linux_mipsx.goH A D20-Aug-20217.4 KiB244134

syscall_linux_ppc.goH A D20-Aug-20218.5 KiB276160

syscall_linux_ppc64x.goH A D20-Aug-20216.1 KiB16260

syscall_linux_riscv64.goH A D20-Aug-20217.1 KiB236137

syscall_linux_s390x.goH A D20-Aug-202110.7 KiB348244

syscall_linux_sparc64.goH A D20-Aug-20215.5 KiB15767

syscall_linux_test.goH A D20-Aug-202125.1 KiB1,008815

syscall_netbsd.goH A D20-Aug-202116.2 KiB619177

syscall_netbsd_386.goH A D20-Aug-2021840 3924

syscall_netbsd_amd64.goH A D20-Aug-2021837 3924

syscall_netbsd_arm.goH A D20-Aug-2021840 3924

syscall_netbsd_arm64.goH A D20-Aug-2021837 3924

syscall_netbsd_test.goH A D20-Aug-20211.8 KiB7656

syscall_openbsd.goH A D20-Aug-202111.1 KiB391156

syscall_openbsd_386.goH A D20-Aug-20211,022 4325

syscall_openbsd_amd64.goH A D20-Aug-20211,014 4325

syscall_openbsd_arm.goH A D20-Aug-20211,022 4325

syscall_openbsd_arm64.goH A D20-Aug-20211,014 4325

syscall_openbsd_mips64.goH A D20-Aug-2021874 3622

syscall_openbsd_test.goH A D20-Aug-20211 KiB5139

syscall_solaris.goH A D20-Aug-202127.7 KiB987670

syscall_solaris_amd64.goH A D20-Aug-2021617 2916

syscall_solaris_test.goH A D20-Aug-20217.8 KiB335304

syscall_test.goH A D20-Aug-20211.6 KiB7354

syscall_unix.goH A D20-Aug-202111 KiB436337

syscall_unix_gc.goH A D20-Aug-2021751 196

syscall_unix_gc_ppc64x.goH A D20-Aug-2021839 2614

syscall_unix_test.goH A D20-Aug-202123.2 KiB984817

syscall_zos_s390x.goH A D20-Aug-202149.2 KiB1,8301,418

syscall_zos_test.goH A D20-Aug-202121.5 KiB872732

timestruct.goH A D20-Aug-20212.3 KiB7844

timestruct_test.goH A D20-Aug-20211.8 KiB5641

types_aix.goH A D20-Aug-20214.3 KiB239104

types_darwin.goH A D20-Aug-20216.4 KiB326141

types_dragonfly.goH A D20-Aug-20215.4 KiB275120

types_freebsd.goH A D20-Aug-20218.7 KiB414184

types_illumos.goH A D20-Aug-2021962 4815

types_netbsd.goH A D20-Aug-20215.9 KiB305135

types_openbsd.goH A D20-Aug-20215.5 KiB288123

types_solaris.goH A D20-Aug-20216.4 KiB303140

unveil_openbsd.goH A D20-Aug-20211 KiB4328

xattr_bsd.goH A D20-Aug-20215 KiB242178

xattr_test.goH A D20-Aug-20214.6 KiB209155

zerrors_aix_ppc.goH A D20-Aug-202152.4 KiB1,3861,366

zerrors_aix_ppc64.goH A D20-Aug-202152.7 KiB1,3871,367

zerrors_darwin_amd64.goH A D20-Aug-202176.2 KiB1,8671,847

zerrors_darwin_arm64.goH A D20-Aug-202176.2 KiB1,8671,847

zerrors_dragonfly_amd64.goH A D20-Aug-202170.7 KiB1,7391,719

zerrors_freebsd_386.goH A D20-Aug-202175.9 KiB1,9491,929

zerrors_freebsd_amd64.goH A D20-Aug-202175.9 KiB1,9481,928

zerrors_freebsd_arm.goH A D20-Aug-202171.9 KiB1,8471,827

zerrors_freebsd_arm64.goH A D20-Aug-202175.9 KiB1,9491,929

zerrors_linux.goH A D20-Aug-2021148.9 KiB2,9442,932

zerrors_linux_386.goH A D20-Aug-202133.2 KiB822802

zerrors_linux_amd64.goH A D20-Aug-202133.2 KiB822802

zerrors_linux_arm.goH A D20-Aug-202133.4 KiB828808

zerrors_linux_arm64.goH A D20-Aug-202133.1 KiB819799

zerrors_linux_mips.goH A D20-Aug-202133.7 KiB829809

zerrors_linux_mips64.goH A D20-Aug-202133.7 KiB829809

zerrors_linux_mips64le.goH A D20-Aug-202133.7 KiB829809

zerrors_linux_mipsle.goH A D20-Aug-202133.7 KiB829809

zerrors_linux_ppc.goH A D20-Aug-202135.8 KiB881861

zerrors_linux_ppc64.goH A D20-Aug-202136 KiB885865

zerrors_linux_ppc64le.goH A D20-Aug-202136 KiB885865

zerrors_linux_riscv64.goH A D20-Aug-202132.7 KiB809789

zerrors_linux_s390x.goH A D20-Aug-202135.7 KiB884864

zerrors_linux_sparc64.goH A D20-Aug-202135.9 KiB879859

zerrors_netbsd_386.goH A D20-Aug-202172.8 KiB1,7811,761

zerrors_netbsd_amd64.goH A D20-Aug-202172.4 KiB1,7711,751

zerrors_netbsd_arm.goH A D20-Aug-202171.9 KiB1,7601,740

zerrors_netbsd_arm64.goH A D20-Aug-202172.4 KiB1,7711,751

zerrors_openbsd_386.goH A D20-Aug-202168.3 KiB1,6691,649

zerrors_openbsd_amd64.goH A D20-Aug-202172.7 KiB1,7761,756

zerrors_openbsd_arm.goH A D20-Aug-202168.4 KiB1,6711,651

zerrors_openbsd_arm64.goH A D20-Aug-202173.8 KiB1,7991,779

zerrors_openbsd_mips64.goH A D20-Aug-202176.8 KiB1,8641,844

zerrors_solaris_amd64.goH A D20-Aug-202159 KiB1,5581,538

zerrors_zos_s390x.goH A D20-Aug-202134.5 KiB861842

zptrace_armnn_linux.goH A D20-Aug-20211.2 KiB4323

zptrace_linux_arm64.goH A D20-Aug-2021733 1810

zptrace_mipsnn_linux.goH A D20-Aug-20211.4 KiB5232

zptrace_mipsnnle_linux.goH A D20-Aug-20211.5 KiB5232

zptrace_x86_linux.goH A D20-Aug-20211.9 KiB8262

zsyscall_aix_ppc.goH A D20-Aug-202136.1 KiB1,486992

zsyscall_aix_ppc64.goH A D20-Aug-202130.5 KiB1,4441,073

zsyscall_aix_ppc64_gc.goH A D20-Aug-202142.5 KiB1,193594

zsyscall_aix_ppc64_gccgo.goH A D20-Aug-202130.8 KiB1,071590

zsyscall_darwin_amd64.1_13.goH A D20-Aug-20211 KiB4120

zsyscall_darwin_amd64.1_13.sH A D20-Aug-2021766 2613

zsyscall_darwin_amd64.goH A D20-Aug-202163.8 KiB2,4321,565

zsyscall_darwin_amd64.sH A D20-Aug-202127.9 KiB860569

zsyscall_darwin_arm64.1_13.goH A D20-Aug-20211 KiB4120

zsyscall_darwin_arm64.1_13.sH A D20-Aug-2021766 2613

zsyscall_darwin_arm64.goH A D20-Aug-202163.7 KiB2,4321,565

zsyscall_darwin_arm64.sH A D20-Aug-202127.8 KiB860569

zsyscall_dragonfly_amd64.goH A D20-Aug-202139.1 KiB1,6801,272

zsyscall_freebsd_386.goH A D20-Aug-202148.3 KiB2,0171,543

zsyscall_freebsd_amd64.goH A D20-Aug-202148.1 KiB2,0171,543

zsyscall_freebsd_arm.goH A D20-Aug-202148.3 KiB2,0171,543

zsyscall_freebsd_arm64.goH A D20-Aug-202148.1 KiB2,0171,543

zsyscall_illumos_amd64.goH A D20-Aug-20213.5 KiB12983

zsyscall_linux.goH A D20-Aug-202146.9 KiB1,9551,537

zsyscall_linux_386.goH A D20-Aug-202114.3 KiB580424

zsyscall_linux_amd64.goH A D20-Aug-202118.7 KiB747546

zsyscall_linux_arm.goH A D20-Aug-202118.3 KiB717525

zsyscall_linux_arm64.goH A D20-Aug-202115.5 KiB604439

zsyscall_linux_mips.goH A D20-Aug-202119.2 KiB760556

zsyscall_linux_mips64.goH A D20-Aug-202118.3 KiB731536

zsyscall_linux_mips64le.goH A D20-Aug-202118.3 KiB731536

zsyscall_linux_mipsle.goH A D20-Aug-202119.2 KiB760556

zsyscall_linux_ppc.goH A D20-Aug-202119.3 KiB763559

zsyscall_linux_ppc64.goH A D20-Aug-202120.3 KiB809593

zsyscall_linux_ppc64le.goH A D20-Aug-202120.3 KiB809593

zsyscall_linux_riscv64.goH A D20-Aug-202115 KiB584422

zsyscall_linux_s390x.goH A D20-Aug-202114 KiB579426

zsyscall_linux_sparc64.goH A D20-Aug-202118.7 KiB742544

zsyscall_netbsd_386.goH A D20-Aug-202144.3 KiB1,8631,428

zsyscall_netbsd_amd64.goH A D20-Aug-202144.1 KiB1,8631,428

zsyscall_netbsd_arm.goH A D20-Aug-202144.3 KiB1,8631,428

zsyscall_netbsd_arm64.goH A D20-Aug-202144.1 KiB1,8631,428

zsyscall_openbsd_386.goH A D20-Aug-202139.6 KiB1,6941,283

zsyscall_openbsd_amd64.goH A D20-Aug-202139.4 KiB1,6941,283

zsyscall_openbsd_arm.goH A D20-Aug-202139.6 KiB1,6941,283

zsyscall_openbsd_arm64.goH A D20-Aug-202139.4 KiB1,6941,283

zsyscall_openbsd_mips64.goH A D20-Aug-202139.4 KiB1,6941,283

zsyscall_solaris_amd64.goH A D20-Aug-202156.9 KiB2,0541,368

zsyscall_zos_s390x.goH A D20-Aug-202129.9 KiB1,256942

zsysctl_openbsd_386.goH A D20-Aug-202111.8 KiB275266

zsysctl_openbsd_amd64.goH A D20-Aug-202111.7 KiB273264

zsysctl_openbsd_arm.goH A D20-Aug-202111.8 KiB275266

zsysctl_openbsd_arm64.goH A D20-Aug-202111.8 KiB277268

zsysctl_openbsd_mips64.goH A D20-Aug-202111.9 KiB281272

zsysnum_darwin_amd64.goH A D20-Aug-202117.9 KiB441432

zsysnum_darwin_arm64.goH A D20-Aug-202117.8 KiB439430

zsysnum_dragonfly_amd64.goH A D20-Aug-202127.6 KiB318309

zsysnum_freebsd_386.goH A D20-Aug-202136.2 KiB398389

zsysnum_freebsd_amd64.goH A D20-Aug-202136.2 KiB398389

zsysnum_freebsd_arm.goH A D20-Aug-202136.2 KiB398389

zsysnum_freebsd_arm64.goH A D20-Aug-202136.2 KiB398389

zsysnum_linux_386.goH A D20-Aug-202117.1 KiB446438

zsysnum_linux_amd64.goH A D20-Aug-202112.3 KiB368360

zsysnum_linux_arm.goH A D20-Aug-202115.7 KiB410402

zsysnum_linux_arm64.goH A D20-Aug-202110.5 KiB313305

zsysnum_linux_mips.goH A D20-Aug-202117 KiB431423

zsysnum_linux_mips64.goH A D20-Aug-202112.5 KiB361353

zsysnum_linux_mips64le.goH A D20-Aug-202112.5 KiB361353

zsysnum_linux_mipsle.goH A D20-Aug-202117 KiB431423

zsysnum_linux_ppc.goH A D20-Aug-202116.8 KiB438430

zsysnum_linux_ppc64.goH A D20-Aug-202113.8 KiB410402

zsysnum_linux_ppc64le.goH A D20-Aug-202113.8 KiB410402

zsysnum_linux_riscv64.goH A D20-Aug-202110.4 KiB312304

zsysnum_linux_s390x.goH A D20-Aug-202112.6 KiB375367

zsysnum_linux_sparc64.goH A D20-Aug-202113.1 KiB389381

zsysnum_netbsd_386.goH A D20-Aug-202125.7 KiB276268

zsysnum_netbsd_amd64.goH A D20-Aug-202125.7 KiB276268

zsysnum_netbsd_arm.goH A D20-Aug-202125.7 KiB276268

zsysnum_netbsd_arm64.goH A D20-Aug-202125.7 KiB276268

zsysnum_openbsd_386.goH A D20-Aug-202117.9 KiB220212

zsysnum_openbsd_amd64.goH A D20-Aug-202117.9 KiB220212

zsysnum_openbsd_arm.goH A D20-Aug-202117.9 KiB220212

zsysnum_openbsd_arm64.goH A D20-Aug-202117.8 KiB219211

zsysnum_openbsd_mips64.goH A D20-Aug-202118 KiB222214

zsysnum_zos_s390x.goH A D20-Aug-2021117 KiB2,6712,660

ztypes_aix_ppc.goH A D20-Aug-20214.9 KiB355296

ztypes_aix_ppc64.goH A D20-Aug-20215 KiB359300

ztypes_darwin_amd64.goH A D20-Aug-20219.4 KiB642562

ztypes_darwin_arm64.goH A D20-Aug-20219.4 KiB642562

ztypes_dragonfly_amd64.goH A D20-Aug-20216.9 KiB475413

ztypes_freebsd_386.goH A D20-Aug-202110.9 KiB722639

ztypes_freebsd_amd64.goH A D20-Aug-202110.9 KiB725642

ztypes_freebsd_arm.goH A D20-Aug-202110.7 KiB706623

ztypes_freebsd_arm64.goH A D20-Aug-202110.6 KiB703620

ztypes_illumos_amd64.goH A D20-Aug-2021607 4128

ztypes_linux.goH A D20-Aug-2021140 KiB3,9263,729

ztypes_linux_386.goH A D20-Aug-202111.3 KiB638561

ztypes_linux_amd64.goH A D20-Aug-202111.6 KiB656579

ztypes_linux_arm.goH A D20-Aug-202111.3 KiB633556

ztypes_linux_arm64.goH A D20-Aug-202111.3 KiB635558

ztypes_linux_mips.goH A D20-Aug-202111.4 KiB639562

ztypes_linux_mips64.goH A D20-Aug-202111.4 KiB638561

ztypes_linux_mips64le.goH A D20-Aug-202111.4 KiB638561

ztypes_linux_mipsle.goH A D20-Aug-202111.4 KiB639562

ztypes_linux_ppc.goH A D20-Aug-202111.5 KiB645568

ztypes_linux_ppc64.goH A D20-Aug-202111.5 KiB645568

ztypes_linux_ppc64le.goH A D20-Aug-202111.5 KiB645568

ztypes_linux_riscv64.goH A D20-Aug-202111.6 KiB663586

ztypes_linux_s390x.goH A D20-Aug-202111.8 KiB659579

ztypes_linux_sparc64.goH A D20-Aug-202111.4 KiB640563

ztypes_netbsd_386.goH A D20-Aug-20217.4 KiB503435

ztypes_netbsd_amd64.goH A D20-Aug-20217.6 KiB511443

ztypes_netbsd_arm.goH A D20-Aug-20217.6 KiB508440

ztypes_netbsd_arm64.goH A D20-Aug-20217.6 KiB511443

ztypes_openbsd_386.goH A D20-Aug-20219.5 KiB576510

ztypes_openbsd_amd64.goH A D20-Aug-20219.4 KiB576510

ztypes_openbsd_arm.goH A D20-Aug-20219.4 KiB577511

ztypes_openbsd_arm64.goH A D20-Aug-20219.3 KiB570504

ztypes_openbsd_mips64.goH A D20-Aug-20219.3 KiB570504

ztypes_solaris_amd64.goH A D20-Aug-20217.1 KiB483418

ztypes_zos_s390x.goH A D20-Aug-20216.6 KiB407351

README.md

1# Building `sys/unix`
2
3The sys/unix package provides access to the raw system call interface of the
4underlying operating system. See: https://godoc.org/golang.org/x/sys/unix
5
6Porting Go to a new architecture/OS combination or adding syscalls, types, or
7constants to an existing architecture/OS pair requires some manual effort;
8however, there are tools that automate much of the process.
9
10## Build Systems
11
12There are currently two ways we generate the necessary files. We are currently
13migrating the build system to use containers so the builds are reproducible.
14This is being done on an OS-by-OS basis. Please update this documentation as
15components of the build system change.
16
17### Old Build System (currently for `GOOS != "linux"`)
18
19The old build system generates the Go files based on the C header files
20present on your system. This means that files
21for a given GOOS/GOARCH pair must be generated on a system with that OS and
22architecture. This also means that the generated code can differ from system
23to system, based on differences in the header files.
24
25To avoid this, if you are using the old build system, only generate the Go
26files on an installation with unmodified header files. It is also important to
27keep track of which version of the OS the files were generated from (ex.
28Darwin 14 vs Darwin 15). This makes it easier to track the progress of changes
29and have each OS upgrade correspond to a single change.
30
31To build the files for your current OS and architecture, make sure GOOS and
32GOARCH are set correctly and run `mkall.sh`. This will generate the files for
33your specific system. Running `mkall.sh -n` shows the commands that will be run.
34
35Requirements: bash, go
36
37### New Build System (currently for `GOOS == "linux"`)
38
39The new build system uses a Docker container to generate the go files directly
40from source checkouts of the kernel and various system libraries. This means
41that on any platform that supports Docker, all the files using the new build
42system can be generated at once, and generated files will not change based on
43what the person running the scripts has installed on their computer.
44
45The OS specific files for the new build system are located in the `${GOOS}`
46directory, and the build is coordinated by the `${GOOS}/mkall.go` program. When
47the kernel or system library updates, modify the Dockerfile at
48`${GOOS}/Dockerfile` to checkout the new release of the source.
49
50To build all the files under the new build system, you must be on an amd64/Linux
51system and have your GOOS and GOARCH set accordingly. Running `mkall.sh` will
52then generate all of the files for all of the GOOS/GOARCH pairs in the new build
53system. Running `mkall.sh -n` shows the commands that will be run.
54
55Requirements: bash, go, docker
56
57## Component files
58
59This section describes the various files used in the code generation process.
60It also contains instructions on how to modify these files to add a new
61architecture/OS or to add additional syscalls, types, or constants. Note that
62if you are using the new build system, the scripts/programs cannot be called normally.
63They must be called from within the docker container.
64
65### asm files
66
67The hand-written assembly file at `asm_${GOOS}_${GOARCH}.s` implements system
68call dispatch. There are three entry points:
69```
70  func Syscall(trap, a1, a2, a3 uintptr) (r1, r2, err uintptr)
71  func Syscall6(trap, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2, err uintptr)
72  func RawSyscall(trap, a1, a2, a3 uintptr) (r1, r2, err uintptr)
73```
74The first and second are the standard ones; they differ only in how many
75arguments can be passed to the kernel. The third is for low-level use by the
76ForkExec wrapper. Unlike the first two, it does not call into the scheduler to
77let it know that a system call is running.
78
79When porting Go to a new architecture/OS, this file must be implemented for
80each GOOS/GOARCH pair.
81
82### mksysnum
83
84Mksysnum is a Go program located at `${GOOS}/mksysnum.go` (or `mksysnum_${GOOS}.go`
85for the old system). This program takes in a list of header files containing the
86syscall number declarations and parses them to produce the corresponding list of
87Go numeric constants. See `zsysnum_${GOOS}_${GOARCH}.go` for the generated
88constants.
89
90Adding new syscall numbers is mostly done by running the build on a sufficiently
91new installation of the target OS (or updating the source checkouts for the
92new build system). However, depending on the OS, you may need to update the
93parsing in mksysnum.
94
95### mksyscall.go
96
97The `syscall.go`, `syscall_${GOOS}.go`, `syscall_${GOOS}_${GOARCH}.go` are
98hand-written Go files which implement system calls (for unix, the specific OS,
99or the specific OS/Architecture pair respectively) that need special handling
100and list `//sys` comments giving prototypes for ones that can be generated.
101
102The mksyscall.go program takes the `//sys` and `//sysnb` comments and converts
103them into syscalls. This requires the name of the prototype in the comment to
104match a syscall number in the `zsysnum_${GOOS}_${GOARCH}.go` file. The function
105prototype can be exported (capitalized) or not.
106
107Adding a new syscall often just requires adding a new `//sys` function prototype
108with the desired arguments and a capitalized name so it is exported. However, if
109you want the interface to the syscall to be different, often one will make an
110unexported `//sys` prototype, and then write a custom wrapper in
111`syscall_${GOOS}.go`.
112
113### types files
114
115For each OS, there is a hand-written Go file at `${GOOS}/types.go` (or
116`types_${GOOS}.go` on the old system). This file includes standard C headers and
117creates Go type aliases to the corresponding C types. The file is then fed
118through godef to get the Go compatible definitions. Finally, the generated code
119is fed though mkpost.go to format the code correctly and remove any hidden or
120private identifiers. This cleaned-up code is written to
121`ztypes_${GOOS}_${GOARCH}.go`.
122
123The hardest part about preparing this file is figuring out which headers to
124include and which symbols need to be `#define`d to get the actual data
125structures that pass through to the kernel system calls. Some C libraries
126preset alternate versions for binary compatibility and translate them on the
127way in and out of system calls, but there is almost always a `#define` that can
128get the real ones.
129See `types_darwin.go` and `linux/types.go` for examples.
130
131To add a new type, add in the necessary include statement at the top of the
132file (if it is not already there) and add in a type alias line. Note that if
133your type is significantly different on different architectures, you may need
134some `#if/#elif` macros in your include statements.
135
136### mkerrors.sh
137
138This script is used to generate the system's various constants. This doesn't
139just include the error numbers and error strings, but also the signal numbers
140and a wide variety of miscellaneous constants. The constants come from the list
141of include files in the `includes_${uname}` variable. A regex then picks out
142the desired `#define` statements, and generates the corresponding Go constants.
143The error numbers and strings are generated from `#include <errno.h>`, and the
144signal numbers and strings are generated from `#include <signal.h>`. All of
145these constants are written to `zerrors_${GOOS}_${GOARCH}.go` via a C program,
146`_errors.c`, which prints out all the constants.
147
148To add a constant, add the header that includes it to the appropriate variable.
149Then, edit the regex (if necessary) to match the desired constant. Avoid making
150the regex too broad to avoid matching unintended constants.
151
152### mkmerge.go
153
154This program is used to extract duplicate const, func, and type declarations
155from the generated architecture-specific files listed below, and merge these
156into a common file for each OS.
157
158The merge is performed in the following steps:
1591. Construct the set of common code that is idential in all architecture-specific files.
1602. Write this common code to the merged file.
1613. Remove the common code from all architecture-specific files.
162
163
164## Generated files
165
166### `zerrors_${GOOS}_${GOARCH}.go`
167
168A file containing all of the system's generated error numbers, error strings,
169signal numbers, and constants. Generated by `mkerrors.sh` (see above).
170
171### `zsyscall_${GOOS}_${GOARCH}.go`
172
173A file containing all the generated syscalls for a specific GOOS and GOARCH.
174Generated by `mksyscall.go` (see above).
175
176### `zsysnum_${GOOS}_${GOARCH}.go`
177
178A list of numeric constants for all the syscall number of the specific GOOS
179and GOARCH. Generated by mksysnum (see above).
180
181### `ztypes_${GOOS}_${GOARCH}.go`
182
183A file containing Go types for passing into (or returning from) syscalls.
184Generated by godefs and the types file (see above).
185