Parallelize singleton execution
Bug: 281536768 Test: manual, presubmits Change-Id: I57fdc76ba6b277e88e196b506af87127a530fd37
This commit is contained in:
@@ -465,7 +465,7 @@ func dexpreoptBootJarsFactory() android.SingletonModule {
|
||||
}
|
||||
|
||||
func RegisterDexpreoptBootJarsComponents(ctx android.RegistrationContext) {
|
||||
ctx.RegisterSingletonModuleType("dex_bootjars", dexpreoptBootJarsFactory)
|
||||
ctx.RegisterParallelSingletonModuleType("dex_bootjars", dexpreoptBootJarsFactory)
|
||||
}
|
||||
|
||||
func SkipDexpreoptBootJars(ctx android.PathContext) bool {
|
||||
|
@@ -28,7 +28,7 @@ func init() {
|
||||
}
|
||||
|
||||
func RegisterDexpreoptCheckBuildComponents(ctx android.RegistrationContext) {
|
||||
ctx.RegisterSingletonModuleType("dexpreopt_systemserver_check", dexpreoptSystemserverCheckFactory)
|
||||
ctx.RegisterParallelSingletonModuleType("dexpreopt_systemserver_check", dexpreoptSystemserverCheckFactory)
|
||||
}
|
||||
|
||||
// A build-time check to verify if all compilation artifacts of system server jars are installed
|
||||
|
@@ -38,7 +38,7 @@ func init() {
|
||||
|
||||
func RegisterJavaFuzzBuildComponents(ctx android.RegistrationContext) {
|
||||
ctx.RegisterModuleType("java_fuzz", JavaFuzzFactory)
|
||||
ctx.RegisterSingletonType("java_fuzz_packaging", javaFuzzPackagingFactory)
|
||||
ctx.RegisterParallelSingletonType("java_fuzz_packaging", javaFuzzPackagingFactory)
|
||||
}
|
||||
|
||||
type JavaFuzzTest struct {
|
||||
|
@@ -25,7 +25,7 @@ func init() {
|
||||
}
|
||||
|
||||
func RegisterHiddenApiSingletonComponents(ctx android.RegistrationContext) {
|
||||
ctx.RegisterSingletonType("hiddenapi", hiddenAPISingletonFactory)
|
||||
ctx.RegisterParallelSingletonType("hiddenapi", hiddenAPISingletonFactory)
|
||||
}
|
||||
|
||||
var PrepareForTestWithHiddenApiBuildComponents = android.FixtureRegisterWithContext(RegisterHiddenApiSingletonComponents)
|
||||
|
@@ -73,8 +73,8 @@ func registerJavaBuildComponents(ctx android.RegistrationContext) {
|
||||
ctx.BottomUp("jacoco_deps", jacocoDepsMutator).Parallel()
|
||||
})
|
||||
|
||||
ctx.RegisterSingletonType("logtags", LogtagsSingleton)
|
||||
ctx.RegisterSingletonType("kythe_java_extract", kytheExtractJavaFactory)
|
||||
ctx.RegisterParallelSingletonType("logtags", LogtagsSingleton)
|
||||
ctx.RegisterParallelSingletonType("kythe_java_extract", kytheExtractJavaFactory)
|
||||
}
|
||||
|
||||
func RegisterJavaSdkMemberTypes() {
|
||||
|
@@ -26,7 +26,7 @@ import (
|
||||
// called. Dependency info file is generated in $OUT/module_bp_java_depend.json.
|
||||
|
||||
func init() {
|
||||
android.RegisterSingletonType("jdeps_generator", jDepsGeneratorSingleton)
|
||||
android.RegisterParallelSingletonType("jdeps_generator", jDepsGeneratorSingleton)
|
||||
}
|
||||
|
||||
func jDepsGeneratorSingleton() android.Singleton {
|
||||
|
@@ -705,7 +705,7 @@ func (l *lintSingleton) MakeVars(ctx android.MakeVarsContext) {
|
||||
var _ android.SingletonMakeVarsProvider = (*lintSingleton)(nil)
|
||||
|
||||
func init() {
|
||||
android.RegisterSingletonType("lint",
|
||||
android.RegisterParallelSingletonType("lint",
|
||||
func() android.Singleton { return &lintSingleton{} })
|
||||
|
||||
registerLintBuildComponents(android.InitRegistrationContext)
|
||||
|
@@ -26,7 +26,7 @@ func init() {
|
||||
}
|
||||
|
||||
func registerPlatformBootclasspathBuildComponents(ctx android.RegistrationContext) {
|
||||
ctx.RegisterSingletonModuleType("platform_bootclasspath", platformBootclasspathFactory)
|
||||
ctx.RegisterParallelSingletonModuleType("platform_bootclasspath", platformBootclasspathFactory)
|
||||
}
|
||||
|
||||
// The tags used for the dependencies between the platform bootclasspath and any configured boot
|
||||
|
@@ -36,7 +36,7 @@ var CompatConfigSdkMemberType = &compatConfigMemberType{
|
||||
}
|
||||
|
||||
func registerPlatformCompatConfigBuildComponents(ctx android.RegistrationContext) {
|
||||
ctx.RegisterSingletonType("platform_compat_config_singleton", platformCompatConfigSingletonFactory)
|
||||
ctx.RegisterParallelSingletonType("platform_compat_config_singleton", platformCompatConfigSingletonFactory)
|
||||
ctx.RegisterModuleType("platform_compat_config", PlatformCompatConfigFactory)
|
||||
ctx.RegisterModuleType("prebuilt_platform_compat_config", prebuiltCompatConfigFactory)
|
||||
ctx.RegisterModuleType("global_compat_config", globalCompatConfigFactory)
|
||||
|
@@ -28,7 +28,7 @@ import (
|
||||
|
||||
func init() {
|
||||
android.RegisterPreSingletonType("sdk_versions", sdkPreSingletonFactory)
|
||||
android.RegisterSingletonType("sdk", sdkSingletonFactory)
|
||||
android.RegisterParallelSingletonType("sdk", sdkSingletonFactory)
|
||||
android.RegisterMakeVarsProvider(pctx, sdkMakeVars)
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user