diff options
| author | Dmitry Vyukov <dvyukov@google.com> | 2018-05-05 15:40:10 +0200 |
|---|---|---|
| committer | Dmitry Vyukov <dvyukov@google.com> | 2018-05-05 15:40:10 +0200 |
| commit | 31ea20ce83aa7ca21b4d0ef28d8375a058292a5a (patch) | |
| tree | 4df7407aa0bca0fd4caeb65808e899f0c6558e21 /sys/windows | |
| parent | 08a0ef9cb0622002a2f9b0aabeab678bee4e0dbf (diff) | |
sys: move generate files to separate packages
Move generated files to gen subdir. This allows to:
1. Rebuild init.go without rebuilding generated code.
2. Excluding generated files from gometalinter checking.
This makes faster and consume less memory.
Update #538
Diffstat (limited to 'sys/windows')
| -rw-r--r-- | sys/windows/gen/amd64.go (renamed from sys/windows/amd64.go) | 8 | ||||
| -rw-r--r-- | sys/windows/init.go | 5 |
2 files changed, 8 insertions, 5 deletions
diff --git a/sys/windows/amd64.go b/sys/windows/gen/amd64.go index 29332168b..67c6b48a0 100644 --- a/sys/windows/amd64.go +++ b/sys/windows/gen/amd64.go @@ -1,12 +1,10 @@ // AUTOGENERATED FILE -package windows +package gen import . "github.com/google/syzkaller/prog" -func init() { - RegisterTarget(&Target{OS: "windows", Arch: "amd64", Revision: revision_amd64, PtrSize: 8, PageSize: 4096, NumPages: 4096, DataOffset: 536870912, Syscalls: syscalls_amd64, Resources: resources_amd64, Structs: structDescs_amd64, Consts: consts_amd64}, initTarget) -} +var Target_amd64 = &Target{OS: "windows", Arch: "amd64", Revision: revision_amd64, PtrSize: 8, PageSize: 4096, NumPages: 4096, DataOffset: 536870912, Syscalls: syscalls_amd64, Resources: resources_amd64, Structs: structDescs_amd64, Consts: consts_amd64} var resources_amd64 = []*ResourceDesc{ {Name: "HANDLE", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", TypeSize: 8}}}, Kind: []string{"HANDLE"}, Values: []uint64{18446744073709551615}}, @@ -14613,4 +14611,4 @@ var consts_amd64 = []ConstValue{ {Name: "WRITE_OWNER", Value: 524288}, } -const revision_amd64 = "47180614fec67dadb09d1411878a07a5132de548" +const revision_amd64 = "6285e05d0c2a423477b78cca69c1143794a9b482" diff --git a/sys/windows/init.go b/sys/windows/init.go index 7729f3260..f27f89cb0 100644 --- a/sys/windows/init.go +++ b/sys/windows/init.go @@ -5,8 +5,13 @@ package windows import ( "github.com/google/syzkaller/prog" + "github.com/google/syzkaller/sys/windows/gen" ) +func init() { + prog.RegisterTarget(gen.Target_amd64, initTarget) +} + func initTarget(target *prog.Target) { arch := &arch{ virtualAllocSyscall: target.SyscallMap["VirtualAlloc"], |
