Skip to content

Commit 1bbfd9a

Browse files
committed
[wip] Add SDK validation test
This test compares two API digests of large chunks of the installed SDK—one from the toolchain’s API digester, one from the just-built API digester—and flags any changes in behavior that would affect source compatibility.
1 parent b99a4f8 commit 1bbfd9a

File tree

2 files changed

+206
-0
lines changed

2 files changed

+206
-0
lines changed
Lines changed: 187 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,187 @@
1+
/* Generic Signature Changes */
2+
3+
/* RawRepresentable Changes */
4+
5+
/* Removed Decls */
6+
Var __GNUC_VA_LIST has been removed
7+
8+
/* Moved Decls */
9+
10+
/* Renamed Decls */
11+
12+
/* Type Changes */
13+
14+
/* Decl Attribute changes */
15+
16+
/* Fixed-layout Type Changes */
17+
18+
/* Protocol Conformance Change */
19+
Struct DIR has removed conformance to Sendable
20+
Struct FTS has removed conformance to Sendable
21+
Struct FTS.__Unnamed_union___Anonymous_field8 has removed conformance to Sendable
22+
Struct _RuneEntry has removed conformance to Sendable
23+
Struct _RuneLocale has removed conformance to Sendable
24+
Struct _RuneRange has removed conformance to Sendable
25+
Struct __Reply__host_lockgroup_info_t has removed conformance to Sendable
26+
Struct __Reply__host_processor_info_t has removed conformance to Sendable
27+
Struct __Reply__host_processor_sets_t has removed conformance to Sendable
28+
Struct __Reply__host_processors_t has removed conformance to Sendable
29+
Struct __Reply__host_virtual_physical_table_info_t has removed conformance to Sendable
30+
Struct __Reply__kext_request_t has removed conformance to Sendable
31+
Struct __Reply__kmod_control_t has removed conformance to Sendable
32+
Struct __Reply__kmod_get_info_t has removed conformance to Sendable
33+
Struct __Reply__mach_memory_info_t has removed conformance to Sendable
34+
Struct __Reply__mach_port_get_set_status_t has removed conformance to Sendable
35+
Struct __Reply__mach_port_names_t has removed conformance to Sendable
36+
Struct __Reply__mach_port_space_info_t has removed conformance to Sendable
37+
Struct __Reply__mach_ports_lookup_t has removed conformance to Sendable
38+
Struct __Reply__mach_vm_read_t has removed conformance to Sendable
39+
Struct __Reply__mach_vm_region_info_64_t has removed conformance to Sendable
40+
Struct __Reply__mach_vm_region_info_t has removed conformance to Sendable
41+
Struct __Reply__mach_zone_info_t has removed conformance to Sendable
42+
Struct __Reply__processor_set_tasks_t has removed conformance to Sendable
43+
Struct __Reply__processor_set_tasks_with_flavor_t has removed conformance to Sendable
44+
Struct __Reply__processor_set_threads_t has removed conformance to Sendable
45+
Struct __Reply__task_get_dyld_image_infos_t has removed conformance to Sendable
46+
Struct __Reply__task_get_emulation_vector_t has removed conformance to Sendable
47+
Struct __Reply__task_threads_t has removed conformance to Sendable
48+
Struct __Reply__task_zone_info_t has removed conformance to Sendable
49+
Struct __Reply__vm_mapped_pages_info_t has removed conformance to Sendable
50+
Struct __Reply__vm_read_t has removed conformance to Sendable
51+
Struct __Request__host_security_create_task_token_t has removed conformance to Sendable
52+
Struct __Request__kext_request_t has removed conformance to Sendable
53+
Struct __Request__kmod_control_t has removed conformance to Sendable
54+
Struct __Request__mach_port_construct_t has removed conformance to Sendable
55+
Struct __Request__mach_ports_register_t has removed conformance to Sendable
56+
Struct __Request__mach_vm_write_t has removed conformance to Sendable
57+
Struct __Request__task_create_t has removed conformance to Sendable
58+
Struct __Request__task_register_dyld_image_infos_t has removed conformance to Sendable
59+
Struct __Request__task_set_emulation_vector_t has removed conformance to Sendable
60+
Struct __Request__task_unregister_dyld_image_infos_t has removed conformance to Sendable
61+
Struct __Request__vm_write_t has removed conformance to Sendable
62+
Struct __darwin_pthread_handler_rec has removed conformance to Sendable
63+
Struct __darwin_sigaltstack has removed conformance to Sendable
64+
Struct __darwin_ucontext has removed conformance to Sendable
65+
Struct __darwin_ucontext64 has removed conformance to Sendable
66+
Struct __msfilterreq has removed conformance to Sendable
67+
Struct __nl_cat_d has removed conformance to Sendable
68+
Struct __sFILE has removed conformance to Sendable
69+
Struct __sbuf has removed conformance to Sendable
70+
Struct __shmid_ds_new has removed conformance to Sendable
71+
Struct __siginfo has removed conformance to Sendable
72+
Struct _ftsent has removed conformance to Sendable
73+
Struct _malloc_zone_t has removed conformance to Sendable
74+
Struct _opaque_pthread_t has removed conformance to Sendable
75+
Struct _pcred has removed conformance to Sendable
76+
Struct addrinfo has removed conformance to Sendable
77+
Struct aiocb has removed conformance to Sendable
78+
Struct au_arb_t has removed conformance to Sendable
79+
Struct au_arg32_t has removed conformance to Sendable
80+
Struct au_arg64_t has removed conformance to Sendable
81+
Struct au_cert_hash_t has removed conformance to Sendable
82+
Struct au_class_ent has removed conformance to Sendable
83+
Struct au_event_ent has removed conformance to Sendable
84+
Struct au_execarg_t has removed conformance to Sendable
85+
Struct au_execenv_t has removed conformance to Sendable
86+
Struct au_file_t has removed conformance to Sendable
87+
Struct au_identity_t has removed conformance to Sendable
88+
Struct au_invalid_t has removed conformance to Sendable
89+
Struct au_krb5_principal_t has removed conformance to Sendable
90+
Struct au_opaque_t has removed conformance to Sendable
91+
Struct au_path_t has removed conformance to Sendable
92+
Struct au_sdev_handle has removed conformance to Sendable
93+
Struct au_session has removed conformance to Sendable
94+
Struct au_text_t has removed conformance to Sendable
95+
Struct au_user_ent has removed conformance to Sendable
96+
Struct au_zonename_t has removed conformance to Sendable
97+
Struct bpf_program has removed conformance to Sendable
98+
Struct ctlname has removed conformance to Sendable
99+
Struct datum has removed conformance to Sendable
100+
Struct dk_error_description_t has removed conformance to Sendable
101+
Struct dk_format_capacities_t has removed conformance to Sendable
102+
Struct dk_provision_status_t has removed conformance to Sendable
103+
Struct dk_unmap_t has removed conformance to Sendable
104+
Struct dl_info has removed conformance to Sendable
105+
Struct entry has removed conformance to Sendable
106+
Struct eproc has removed conformance to Sendable
107+
Struct eventreq has removed conformance to Sendable
108+
Struct exception has removed conformance to Sendable
109+
Struct extern_proc has removed conformance to Sendable
110+
Struct fchecklv has removed conformance to Sendable
111+
Struct fsignatures has removed conformance to Sendable
112+
Struct fssearchblock has removed conformance to Sendable
113+
Struct fstab has removed conformance to Sendable
114+
Struct glob_t has removed conformance to Sendable
115+
Struct glob_t.__Unnamed_union___Anonymous_field5 has removed conformance to Sendable
116+
Struct gmonparam has removed conformance to Sendable
117+
Struct group has removed conformance to Sendable
118+
Struct hfs_mount_args has removed conformance to Sendable
119+
Struct hostent has removed conformance to Sendable
120+
Struct iconv_allocation_t has removed conformance to Sendable
121+
Struct iconv_fallbacks has removed conformance to Sendable
122+
Struct iconv_hooks has removed conformance to Sendable
123+
Struct if_clonereq has removed conformance to Sendable
124+
Struct if_nameindex has removed conformance to Sendable
125+
Struct ifaddrs has removed conformance to Sendable
126+
Struct ifdrv has removed conformance to Sendable
127+
Struct ifmaddrs has removed conformance to Sendable
128+
Struct ifmedia_description has removed conformance to Sendable
129+
Struct ifmediareq has removed conformance to Sendable
130+
Struct ifqueue has removed conformance to Sendable
131+
Struct iovec has removed conformance to Sendable
132+
Struct kevent has removed conformance to Sendable
133+
Struct kinfo_proc has removed conformance to Sendable
134+
Struct klist has removed conformance to Sendable
135+
Struct kmod_info has removed conformance to Sendable
136+
Struct kmod_reference has removed conformance to Sendable
137+
Struct lconv has removed conformance to Sendable
138+
Struct mach_msg_ool_descriptor_t has removed conformance to Sendable
139+
Struct mach_msg_ool_ports_descriptor_t has removed conformance to Sendable
140+
Struct mig_subsystem has removed conformance to Sendable
141+
Struct mig_symtab has removed conformance to Sendable
142+
Struct msg has removed conformance to Sendable
143+
Struct msgbuf has removed conformance to Sendable
144+
Struct msghdr has removed conformance to Sendable
145+
Struct ndrv_protocol_desc has removed conformance to Sendable
146+
Struct netent has removed conformance to Sendable
147+
Struct option has removed conformance to Sendable
148+
Struct passwd has removed conformance to Sendable
149+
Struct pipebuf has removed conformance to Sendable
150+
Struct port_obj_tentry has removed conformance to Sendable
151+
Struct protoent has removed conformance to Sendable
152+
Struct pseminfo has removed conformance to Sendable
153+
Struct pshminfo has removed conformance to Sendable
154+
Struct pstats has removed conformance to Sendable
155+
Struct qelem has removed conformance to Sendable
156+
Struct rb_node has removed conformance to Sendable
157+
Struct rb_tree has removed conformance to Sendable
158+
Struct rb_tree_ops_t has removed conformance to Sendable
159+
Struct regex_t has removed conformance to Sendable
160+
Struct routine_descriptor has removed conformance to Sendable
161+
Struct rpc_routine_descriptor has removed conformance to Sendable
162+
Struct rpc_signature has removed conformance to Sendable
163+
Struct rpc_subsystem has removed conformance to Sendable
164+
Struct rpcent has removed conformance to Sendable
165+
Struct rslvmulti_req has removed conformance to Sendable
166+
Struct rt_addrinfo has removed conformance to Sendable
167+
Struct sa_endpoints has removed conformance to Sendable
168+
Struct sbuf has removed conformance to Sendable
169+
Struct servent has removed conformance to Sendable
170+
Struct sf_hdtr has removed conformance to Sendable
171+
Struct sigevent has removed conformance to Sendable
172+
Struct sigstack has removed conformance to Sendable
173+
Struct tm has removed conformance to Sendable
174+
Struct tokenstr has removed conformance to Sendable
175+
Struct tokenstr.__Unnamed_union_tt has removed conformance to Sendable
176+
Struct uprof has removed conformance to Sendable
177+
Struct vfsidctl has removed conformance to Sendable
178+
Struct vfsstatfs has removed conformance to Sendable
179+
Struct vmspace has removed conformance to Sendable
180+
Struct wordexp_t has removed conformance to Sendable
181+
182+
/* Protocol Requirement Change */
183+
184+
/* Class Inheritance Change */
185+
186+
/* Others */
187+
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
// REQUIRES: VENDOR=apple
2+
3+
// RUN: %empty-directory(%t.mod)
4+
// RUN: %empty-directory(%t.sdk)
5+
// RUN: %empty-directory(%t.module-cache)
6+
7+
// Generate a baseline using the HOST API digester, capturing how the host toolchain imports APIs.
8+
// RUN: time env xcrun swift-api-digester -target %target-triple -dump-sdk -module-list-file %s -o %t.baseline -module-cache-path %t.module-cache -sdk %sdk -swift-version 5 -avoid-location -avoid-tool-args
9+
// RUN: time %api-digester -dump-sdk -module-list-file %s -o %t.result -module-cache-path %t.module-cache -sdk %sdk -swift-version 5 -avoid-location -avoid-tool-args
10+
// RUN: time %api-digester -diagnose-sdk -module-list-file %s -input-paths %t.baseline -input-paths %t.result -module-cache-path %t.module-cache -sdk %sdk -swift-version 5 -avoid-location -avoid-tool-args -breakage-allowlist-path %S/Inputs/intentionally-changed-apis.txt
11+
12+
// Force output
13+
// RUN: false
14+
15+
Darwin
16+
Foundation
17+
UIKit
18+
AppKit
19+
SwiftUI

0 commit comments

Comments
 (0)