commit | eaac9171f57cc8462d549b3ca85e28a9594538a5 | [log] [tgz] |
---|---|---|
author | Denis Vnukov <vnukov@google.com> | Tue Jun 06 11:08:08 2017 -0700 |
committer | Denis Vnukov <vnukov@google.com> | Tue Jun 06 11:08:08 2017 -0700 |
tree | 2a5bb5702d1460d810fe5b3473559bea915b4065 | |
parent | f19dfabc704b3975d66019c0817d65fc48921284 [diff] |
Lazy class loading with resource providers. Extending the current lazy loading implementation to allow API consumer to pass instances implementing LazyResourceProvider interface as a source of resources that can be queried lazily for on-demand class searches. Only class files can be added this way in this implementation. This functionality is currently implemented as an *extension* of regular lazy loading which is based on DexClassPromise and LazyClassFileLoader, and reuses this implementation a lot. The advantage of using lazy resource providers is that it does not require actually having all the resources preloaded up front, but it comes at cost of minor differences of how errors for conflicting classes are reported in resource-provider based and regular scenarios. Currently all the resources added to D8 via --lib or --classpath are still loaded via regular lazy loading mechanism, resource providers are only available for API users. BUG= Change-Id: I70cba6f3603bfd1e8e33a168d5fd8a3000a6e762
The R8 repo contains two tools.
D8 is a dexer that converts java byte code to dex code.
R8 is a java program shrinking and minification tool.