Status Update
Comments
za...@affirm.com <za...@affirm.com> #2
Thank you for your patience while our engineering team worked to resolve this issue. A fix for this issue is now available in:
- Android Studio Ladybug Feature Drop | 2024.2.2 Canary 3
- Android Gradle Plugin 8.8.0-alpha03
We encourage you to try the latest update.
If you notice further issues or have questions, please file a new bug report.
Thank you for taking the time to submit feedback — we really appreciate it!
cl...@google.com <cl...@google.com> #3
It's difficult to tell from the information you provided.
(1) Is the crash happening only on specific devices, such as old devices (Android 4 or 4.4)?
(2) Is the class Lkotlin/LazyThreadSafetyMode;
present twice in the output app?
za...@affirm.com <za...@affirm.com> #4
Thank you for the reply! To your questions:
-
I've tested on an emulator for every OS version we support (24+) and they all crash. All of our beta tester's physical devices crash as well.
-
How do I confirm this? I looked at each of our DEX files and most of them contain an entry for
LazyThreadSafetyMode
, however I think this is normal behavior.
Happy to provide any additional info!
cl...@google.com <cl...@google.com> #5
I don't really have enough information to help. Is there a way I could reproduce your issue?
Is there other elements in the stack trace? Does the NoClassDefFoundError comes from an ExceptionInInitializer cause?
za...@affirm.com <za...@affirm.com> #6
A team member of mine determined that though LazyThreadSafetyMode
was being kept, its members SYNCHRONIZED, PUBLICATION and NONE, were not. The following rule fixed our issue:
-keepclassmembers class * {
kotlin.Lazy *;
}
We don't know why this started happening all the sudden but allows us to re-enable optimization. Thanks for trying to help, I know we didn't give you much to go on.
cl...@google.com <cl...@google.com> #7
Any clue what actually happened @sgjesse? It's fixed for them but I don't understand what happened.
sg...@google.com <sg...@google.com> #8
No, I also don't understand. The class kotlin.LazyThreadSafetyMode
is an enum
-keep class kotlin.** { *; }
. If you can still reproduce, can you share two apk's (one with and one without the rule in
sa...@affirm.com <sa...@affirm.com> #9
Hello, we just ran into the app crash again today, and the additional rule that had seemingly made it work so far doesn't help anymore.
However, the crash is fixed when we disable R8 optimization with the -dontoptimize
flag in the R8 configuration file.
Happy to share versions of the APK with and without the -dontoptimize
flags if that helps.
sg...@google.com <sg...@google.com> #10
Thank you for sharing the APKs. I can reproduce the java.lang.NoClassDefFoundError
, and the underlying issue is:
Failure to verify dex file '/data/app/.../base.apk!classes4.dex': Out-of-order method_ids
The class kotlin.LazyThreadSafetyMode
resides in classes4.dex
. Most likely the first class from classes4.dex
which is referenced.
Reading the DEX files with D8 and assertions enabled also fails:
java -ea -cp r8.jar com.android.tools.r8.D8 broken/classes4.dex
Error: java.lang.AssertionError: Out-of-order method ids (method #399: `void Xr.c.b(android.content.Context, Wr.o)`, method #400: `void Xr.c.b(android.content.Context, Wr.o)`)
This looks like an R8 issue where two methods ends up having identical signatures.
I have three things to try/questions to hopefuly help us move closer to locating the issue:
1. Build with assertions enabled
Will it be possible for you to run a build of the broken app with assertions enabled? That might hit an assertion in R8 earlier than when writing (where it should definitely his an assertion) that might provide more information. To build with assertions enabled add -ea
to your org.gradle.jvmargs
property in gradle.properties
for the app. E.g. change from
org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8
to
org.gradle.jvmargs=-ea -Xmx2048m -Dfile.encoding=UTF-8
2. Mapping file info
Also can you provide some information on what is mapping to Xr.c.b(android.content.Context, Wr.o)
and Wr.o
? In the mapping file (search for <something> -> Xr.c
and <something> -> Wr
)
3. -applymapping
Are you by any chance using -applymapping
?
Feel free to share your findings on our private email thread.
ap...@google.com <ap...@google.com> #11
Branch: main
commit dd3dc6192327f2d6335ce5a0c83a453748536b75
Author: Søren Gjesse <sgjesse@google.com>
Date: Wed Aug 14 08:03:18 2024
Add reproduction of outliner issue
Multiple outlines in a block covered by a catch handler cause invalid
rewriting.
Bug:
Change-Id: I85f80e4139e3b16418408120fafeb3019baffd20
A src/test/java/com/android/tools/r8/ir/optimize/outliner/MultipleOutlinesInMethodWithExceptionHandlerTest.java
ap...@google.com <ap...@google.com> #12
Branch: main
commit 707a275bd5c08bb5ba0ec431fe5bd2a329ebd74b
Author: Søren Gjesse <sgjesse@google.com>
Date: Wed Aug 14 10:53:26 2024
Fix invalid rewriting in outliner
When splitting blocks after inserting an invoke to an outline the block
after the split was not fully processed leaving some of the outlined
instructions.
Bug:
Change-Id: Ib74460c93b1bf46ce2d1cad602b804613b9b1205
M src/main/java/com/android/tools/r8/ir/optimize/outliner/OutlinerImpl.java
M src/test/java/com/android/tools/r8/ir/optimize/outliner/MultipleOutlinesInMethodWithExceptionHandlerTest.java
ap...@google.com <ap...@google.com> #13
Branch: 8.5
commit 321f96374308d424b3caef5987b7e716009eb60f
Author: Søren Gjesse <sgjesse@google.com>
Date: Thu Aug 15 09:13:59 2024
Version 8.5.40
Bug:
Change-Id: I6058470b6d9887c94032fe89fa8a4d2cf122378f
M src/main/java/com/android/tools/r8/Version.java
ap...@google.com <ap...@google.com> #14
Branch: 8.5
commit 03a0861b68f732ea29f828562f8f7d86a4a85d79
Author: Søren Gjesse <sgjesse@google.com>
Date: Thu Aug 15 09:13:49 2024
Fix invalid rewriting in outliner
When splitting blocks after inserting an invoke to an outline the block
after the split was not fully processed leaving some of the outlined
instructions.
Bug:
Change-Id: Ib74460c93b1bf46ce2d1cad602b804613b9b1205
M src/main/java/com/android/tools/r8/ir/optimize/outliner/OutlinerImpl.java
M src/test/java/com/android/tools/r8/ir/optimize/outliner/MultipleOutlinesInMethodWithExceptionHandlerTest.java
ap...@google.com <ap...@google.com> #15
Branch: 8.5
commit fbd75988381e2fe9fc76a24c7ac3fe37e1b2c870
Author: Søren Gjesse <sgjesse@google.com>
Date: Thu Aug 15 09:13:40 2024
Add reproduction of outliner issue
Multiple outlines in a block covered by a catch handler cause invalid
rewriting.
Bug:
Change-Id: I85f80e4139e3b16418408120fafeb3019baffd20
A src/test/java/com/android/tools/r8/ir/optimize/outliner/MultipleOutlinesInMethodWithExceptionHandlerTest.java
ap...@google.com <ap...@google.com> #16
Branch: 8.6
commit 506c0784f0539d012b1b718c58ddf1de3d3eb2b9
Author: Søren Gjesse <sgjesse@google.com>
Date: Thu Aug 15 09:12:59 2024
Version 8.6.23
Bug:
Change-Id: I9054cedf227d18700e6788f7e34741fdb1682ab9
M src/main/java/com/android/tools/r8/Version.java
ap...@google.com <ap...@google.com> #17
Branch: 8.6
commit 13ce7beb804cc96070cc70449538125db5d29604
Author: Søren Gjesse <sgjesse@google.com>
Date: Thu Aug 15 09:12:42 2024
Fix invalid rewriting in outliner
When splitting blocks after inserting an invoke to an outline the block
after the split was not fully processed leaving some of the outlined
instructions.
Bug:
Change-Id: Ib74460c93b1bf46ce2d1cad602b804613b9b1205
M src/main/java/com/android/tools/r8/ir/optimize/outliner/OutlinerImpl.java
M src/test/java/com/android/tools/r8/ir/optimize/outliner/MultipleOutlinesInMethodWithExceptionHandlerTest.java
ap...@google.com <ap...@google.com> #18
Branch: 8.6
commit 09d268ec5e84e60c29333b5b8355187fc3765530
Author: Søren Gjesse <sgjesse@google.com>
Date: Thu Aug 15 09:12:28 2024
Add reproduction of outliner issue
Multiple outlines in a block covered by a catch handler cause invalid
rewriting.
Bug:
Change-Id: I85f80e4139e3b16418408120fafeb3019baffd20
A src/test/java/com/android/tools/r8/ir/optimize/outliner/MultipleOutlinesInMethodWithExceptionHandlerTest.java
sg...@google.com <sg...@google.com> #19
The issue fixed in the outliner was discovered while analyzing this issue. However, it does not solve the original issue, with 8.5.40 the Out-of-order method ids (method #399: void Xr.c.b(android.content.Context, Wr.o)
, method #400: void Xr.c.b(android.content.Context, Wr.o)
) still reproduces (in classes4.dex
).
sa...@affirm.com <sa...@affirm.com> #20
Hello @sgjesse, apologies for the delay in following up on this. Is the original issue with out-of-order method ids still open?
sg...@google.com <sg...@google.com> #21
Info for reproduction and what I have found so far.
It reproduce with the dump in the team drive:
tools/compiledump.py -da --nolib -d /tmp/b353279141/dump.zip --temp /tmp/b353279141/dump
unzip /tmp/b353279141/dump/out.jar -d /tmp/b353279141/dump/out
and then running a test like this:
@Test
public void testD8() throws Exception {
for (int i = 1; i <= 6; i++) {
System.out.println(i);
testForD8(Backend.DEX)
.addProgramFiles(Paths.get("/tmp/b353279141/dump/out/classes" + (i > 1 ? "" + i : "") + ".dex"))
.setMinApi(AndroidApiLevel.N)
.allowStdoutMessages()
.compile()
.writeToZip(Paths.get("/tmp/b353279141/xxx.dex"));
}
}
fails with:
Out-of-order method ids (method #399: `void Xr.c.b(android.content.Context, Wr.o)`, method #400: `void Xr.c.b(android.content.Context, Wr.o)`)
java.lang.AssertionError: Out-of-order method ids (method #399: `void Xr.c.b(android.content.Context, Wr.o)`, method #400: `void Xr.c.b(android.content.Context, Wr.o)`)
when reading classes4.dex
.
This is with R8 8.5.10.
I also reproduced it on a881ab6d8e9c0980cdaf16b3c6f42e315d27a922
. However it does not reproduce on the one above that, 5109e113014bc95be4f9ba649712479f0564cb7b
, but I don't think that fixed the issue - just caused it not to surface (but I might be mistaken). Running with assertions fails, but I did fix some of the outliner issues revealed by enabling assertions.
Cherrypicking dd3dc6192327f2d6335ce5a0c83a453748536b75
and 707a275bd5c08bb5ba0ec431fe5bd2a329ebd74b
on a881ab6d8e9c0980cdaf16b3c6f42e315d27a922
hits an assertion for which more info is added by:
diff --git a/src/main/java/com/android/tools/r8/shaking/KeepInfoCollection.java b/src/main/java/com/android/tools/r8/shaking/KeepInfoCollection.java
index e524b2a910..ce8a956ea5 100644
--- a/src/main/java/com/android/tools/r8/shaking/KeepInfoCollection.java
+++ b/src/main/java/com/android/tools/r8/shaking/KeepInfoCollection.java
@@ -404,7 +404,16 @@ public abstract class KeepInfoCollection {
assert type.isIdenticalTo(newType)
|| !info.isPinned(options)
|| info.isMinificationAllowed(options)
- || info.isRepackagingAllowed(options);
+ || info.isRepackagingAllowed(options) :
+ type.toSourceString()
+ + " -> "
+ + newType.toSourceString()
+ + ": isPinned: "
+ + info.isPinned(options)
+ + ", isMinificationAllowed: "
+ + info.isMinificationAllowed(options)
+ + ", isRepackagingAllowed: "
+ + info.isRepackagingAllowed(options);
KeepClassInfo previous = newClassInfo.put(newType, info);
assert previous == null;
});
Not sure that assertion is related to this issue (the outliner issues where not).
ri...@google.com <ri...@google.com> #22
The problem here is that we rename two different methods in the input to the same method in the output:
com.iovation.mobile.android.c.b.a(android.content.Context, com.iovation.mobile.android.b.j)
com.iovation.mobile.android.c.b.b(android.content.Context, com.iovation.mobile.android.b.j)
are both renamed to
Xr.b.b(android.content.Context, Wr.j)
ri...@google.com <ri...@google.com> #23
The problem is that we have the two methods in #22 that ends up in
void Xr.b.a(android.content.Context, Wr.j)
void Xr.b.b(android.content.Context, Wr.j)
Now, in the ProtoNormalizer, we change the signature to:
void Xr.b.a(android.content.Context, Wr.j) // Same
void Xr.b.b(Wr.j, android.content.Context) // Swapped
In the minifier, for these two we calculate the mapping a -> b and b -> a!
However, there is a dangling reference to the "original" Xr.b.b(android.content.Context, Wr.j) from an enclosing method annotation in an inner class (Xr.b$a)
This means, that when collect indexed items we add that method when tracing the annotation, there is no remapping of that in the renaming set (since we swapped the arguments in the protonormalizer, it is not actually on any class) - so we simply give it it's own name, which is exactly the same as the renamed a!
ap...@google.com <ap...@google.com> #24
Project: r8
Branch: main
Author: Rico Wind <
Link:
Update enclosing method signature when normalizing protos
Expand for full commit details
Update enclosing method signature when normalizing protos
Bug: b/353279141
Change-Id: I58740138a75bd7052f624aaa1a17cdcb23990dcd
Files:
- M
src/main/java/com/android/tools/r8/optimize/proto/ProtoNormalizer.java
- M
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: b74c404673dd18104acdfb6f4cd3a296e33e93e7
Date: Fri Dec 06 13:00:04 2024
ap...@google.com <ap...@google.com> #25
Project: r8
Branch: main
Author: Rico Wind <
Link:
Reproduction for dangling reference in enclosing method annotation
Expand for full commit details
Reproduction for dangling reference in enclosing method annotation
Bug: b/353279141
Change-Id: I8b6bebe9d7bad8b93393c6ae03c513f512918a15
Files:
- A
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: e1545336c3fbe376ef07a7f169ca9557ddc05789
Date: Thu Dec 05 18:14:18 2024
ap...@google.com <ap...@google.com> #26
Project: r8
Branch: 8.8
Author: Rico Wind <
Link:
Version 8.8.23
Expand for full commit details
Version 8.8.23
Bug: b/353279141
Change-Id: I2cd1ff305de54c7bb83283f2b9f4091179249e21
Files:
- M
src/main/java/com/android/tools/r8/Version.java
Hash: c64c58c8f4ad7800f003d7fbfd77ced99f62d968
Date: Mon Dec 09 06:23:54 2024
ap...@google.com <ap...@google.com> #27
Project: r8
Branch: 8.8
Author: Rico Wind <
Link:
Reproduction for dangling reference in enclosing method annotation
Expand for full commit details
Reproduction for dangling reference in enclosing method annotation
Bug: b/353279141
Change-Id: I8b6bebe9d7bad8b93393c6ae03c513f512918a15
Files:
- A
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: bb97bdd15576363526a9017a7950698e0e3e6260
Date: Mon Dec 09 06:23:23 2024
ap...@google.com <ap...@google.com> #28
Project: r8
Branch: 8.8
Author: Rico Wind <
Link:
Update enclosing method signature when normalizing protos
Expand for full commit details
Update enclosing method signature when normalizing protos
Bug: b/353279141
Change-Id: I58740138a75bd7052f624aaa1a17cdcb23990dcd
Files:
- M
src/main/java/com/android/tools/r8/optimize/proto/ProtoNormalizer.java
- M
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: c37f8e4500a3e750e46da5f2052af4d57664ca05
Date: Mon Dec 09 06:23:40 2024
ap...@google.com <ap...@google.com> #29
Project: r8
Branch: 8.7
Author: Rico Wind <
Link:
Version 8.7.25
Expand for full commit details
Version 8.7.25
Bug: b/353279141
Change-Id: I3a350fdd1112e6471cf5bd14490576bfc24c395d
Files:
- M
src/main/java/com/android/tools/r8/Version.java
Hash: 83e86425dcd10ea9275f6e0b8fdcdfacefdd7714
Date: Mon Dec 09 06:25:25 2024
ap...@google.com <ap...@google.com> #30
Project: r8
Branch: 8.7
Author: Rico Wind <
Link:
Update enclosing method signature when normalizing protos
Expand for full commit details
Update enclosing method signature when normalizing protos
Bug: b/353279141
Change-Id: I58740138a75bd7052f624aaa1a17cdcb23990dcd
Files:
- M
src/main/java/com/android/tools/r8/optimize/proto/ProtoNormalizer.java
- M
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: dfd259fdd322623337cdf0237518ede415ef1a38
Date: Mon Dec 09 06:25:18 2024
ap...@google.com <ap...@google.com> #31
Project: r8
Branch: 8.7
Author: Rico Wind <
Link:
Reproduction for dangling reference in enclosing method annotation
Expand for full commit details
Reproduction for dangling reference in enclosing method annotation
Bug: b/353279141
Change-Id: I8b6bebe9d7bad8b93393c6ae03c513f512918a15
Files:
- A
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: b58b2c76ef0f479c034a07525f7360bcdd953180
Date: Mon Dec 09 06:25:10 2024
ap...@google.com <ap...@google.com> #32
Project: r8
Branch: 8.6
Author: Rico Wind <
Link:
Version 8.6.38
Expand for full commit details
Version 8.6.38
Bug: b/353279141
Change-Id: Iccaa9fa23aaeb9b13cbea1159afd8d1238948b2a
Files:
- M
src/main/java/com/android/tools/r8/Version.java
Hash: a99c18e769a2b345417a85ac5126539143a6ccdc
Date: Mon Dec 09 06:27:54 2024
ap...@google.com <ap...@google.com> #33
Project: r8
Branch: 8.6
Author: Rico Wind <
Link:
Update enclosing method signature when normalizing protos
Expand for full commit details
Update enclosing method signature when normalizing protos
Bug: b/353279141
Change-Id: I58740138a75bd7052f624aaa1a17cdcb23990dcd
Files:
- M
src/main/java/com/android/tools/r8/optimize/proto/ProtoNormalizer.java
- M
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: 11bdb4fb992bacd5d8ec14d225aa11a4ad2022ca
Date: Mon Dec 09 06:27:48 2024
ap...@google.com <ap...@google.com> #34
Project: r8
Branch: 8.6
Author: Rico Wind <
Link:
Reproduction for dangling reference in enclosing method annotation
Expand for full commit details
Reproduction for dangling reference in enclosing method annotation
Bug: b/353279141
Change-Id: I8b6bebe9d7bad8b93393c6ae03c513f512918a15
Files:
- A
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: 180c4eb0b3df82adeb672a26cf5631596dc79644
Date: Mon Dec 09 06:27:41 2024
ap...@google.com <ap...@google.com> #35
Project: r8
Branch: 8.5
Author: Rico Wind <
Link:
Reproduction for dangling reference in enclosing method annotation
Expand for full commit details
Reproduction for dangling reference in enclosing method annotation
Bug: b/353279141
Change-Id: I8b6bebe9d7bad8b93393c6ae03c513f512918a15
Files:
- A
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: c8daa7ebd1c35abc62b70db88a9417c70110c869
Date: Mon Dec 09 06:29:12 2024
ap...@google.com <ap...@google.com> #36
Project: r8
Branch: 8.5
Author: Rico Wind <
Link:
Update enclosing method signature when normalizing protos
Expand for full commit details
Update enclosing method signature when normalizing protos
Bug: b/353279141
Change-Id: I58740138a75bd7052f624aaa1a17cdcb23990dcd
Files:
- M
src/main/java/com/android/tools/r8/optimize/proto/ProtoNormalizer.java
- M
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: 82702b3ac17616c81bed8acf8eb35a196b4670f1
Date: Mon Dec 09 06:29:18 2024
ap...@google.com <ap...@google.com> #37
Project: r8
Branch: 8.5
Author: Rico Wind <
Link:
Version 8.5.49
Expand for full commit details
Version 8.5.49
Bug: b/353279141
Change-Id: Ic4e17c9754350d55add8faea527641ffc567751f
Files:
- M
src/main/java/com/android/tools/r8/Version.java
Hash: b21776e0fd79f3a210940ae580896f12ab82a4fb
Date: Mon Dec 09 06:29:24 2024
ap...@google.com <ap...@google.com> #38
Project: r8
Branch: 8.8
Author: Rico Wind <
Link:
Reproduction for dangling reference in enclosing method annotation
Expand for full commit details
Reproduction for dangling reference in enclosing method annotation
Bug: b/353279141
Change-Id: I8b6bebe9d7bad8b93393c6ae03c513f512918a15
Files:
- A
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: bb97bdd15576363526a9017a7950698e0e3e6260
Date: Mon Dec 09 06:23:23 2024
ap...@google.com <ap...@google.com> #39
Project: r8
Branch: 8.8
Author: Rico Wind <
Link:
Update enclosing method signature when normalizing protos
Expand for full commit details
Update enclosing method signature when normalizing protos
Bug: b/353279141
Change-Id: I58740138a75bd7052f624aaa1a17cdcb23990dcd
Files:
- M
src/main/java/com/android/tools/r8/optimize/proto/ProtoNormalizer.java
- M
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: c37f8e4500a3e750e46da5f2052af4d57664ca05
Date: Mon Dec 09 06:23:40 2024
ap...@google.com <ap...@google.com> #40
Project: r8
Branch: 8.7
Author: Rico Wind <
Link:
Update enclosing method signature when normalizing protos
Expand for full commit details
Update enclosing method signature when normalizing protos
Bug: b/353279141
Change-Id: I58740138a75bd7052f624aaa1a17cdcb23990dcd
Files:
- M
src/main/java/com/android/tools/r8/optimize/proto/ProtoNormalizer.java
- M
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: dfd259fdd322623337cdf0237518ede415ef1a38
Date: Mon Dec 09 06:25:18 2024
ap...@google.com <ap...@google.com> #41
Project: r8
Branch: 8.7
Author: Rico Wind <
Link:
Reproduction for dangling reference in enclosing method annotation
Expand for full commit details
Reproduction for dangling reference in enclosing method annotation
Bug: b/353279141
Change-Id: I8b6bebe9d7bad8b93393c6ae03c513f512918a15
Files:
- A
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: b58b2c76ef0f479c034a07525f7360bcdd953180
Date: Mon Dec 09 06:25:10 2024
ap...@google.com <ap...@google.com> #42
Project: r8
Branch: 8.6
Author: Rico Wind <
Link:
Update enclosing method signature when normalizing protos
Expand for full commit details
Update enclosing method signature when normalizing protos
Bug: b/353279141
Change-Id: I58740138a75bd7052f624aaa1a17cdcb23990dcd
Files:
- M
src/main/java/com/android/tools/r8/optimize/proto/ProtoNormalizer.java
- M
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: 11bdb4fb992bacd5d8ec14d225aa11a4ad2022ca
Date: Mon Dec 09 06:27:48 2024
ap...@google.com <ap...@google.com> #43
Project: r8
Branch: 8.6
Author: Rico Wind <
Link:
Reproduction for dangling reference in enclosing method annotation
Expand for full commit details
Reproduction for dangling reference in enclosing method annotation
Bug: b/353279141
Change-Id: I8b6bebe9d7bad8b93393c6ae03c513f512918a15
Files:
- A
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: 180c4eb0b3df82adeb672a26cf5631596dc79644
Date: Mon Dec 09 06:27:41 2024
ap...@google.com <ap...@google.com> #44
Project: r8
Branch: 8.8
Author: Rico Wind <
Link:
Reproduction for dangling reference in enclosing method annotation
Expand for full commit details
Reproduction for dangling reference in enclosing method annotation
Bug: b/353279141
Change-Id: I8b6bebe9d7bad8b93393c6ae03c513f512918a15
Files:
- A
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: bb97bdd15576363526a9017a7950698e0e3e6260
Date: Mon Dec 09 06:23:23 2024
ap...@google.com <ap...@google.com> #45
Project: r8
Branch: 8.8
Author: Rico Wind <
Link:
Update enclosing method signature when normalizing protos
Expand for full commit details
Update enclosing method signature when normalizing protos
Bug: b/353279141
Change-Id: I58740138a75bd7052f624aaa1a17cdcb23990dcd
Files:
- M
src/main/java/com/android/tools/r8/optimize/proto/ProtoNormalizer.java
- M
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: c37f8e4500a3e750e46da5f2052af4d57664ca05
Date: Mon Dec 09 06:23:40 2024
ap...@google.com <ap...@google.com> #46
Project: r8
Branch: 8.7
Author: Rico Wind <
Link:
Update enclosing method signature when normalizing protos
Expand for full commit details
Update enclosing method signature when normalizing protos
Bug: b/353279141
Change-Id: I58740138a75bd7052f624aaa1a17cdcb23990dcd
Files:
- M
src/main/java/com/android/tools/r8/optimize/proto/ProtoNormalizer.java
- M
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: dfd259fdd322623337cdf0237518ede415ef1a38
Date: Mon Dec 09 06:25:18 2024
ap...@google.com <ap...@google.com> #47
Project: r8
Branch: 8.7
Author: Rico Wind <
Link:
Reproduction for dangling reference in enclosing method annotation
Expand for full commit details
Reproduction for dangling reference in enclosing method annotation
Bug: b/353279141
Change-Id: I8b6bebe9d7bad8b93393c6ae03c513f512918a15
Files:
- A
src/test/java/com/android/tools/r8/regress/Regress353279141.java
Hash: b58b2c76ef0f479c034a07525f7360bcdd953180
Date: Mon Dec 09 06:25:10 2024
ri...@google.com <ri...@google.com> #48
This is fixed on main and backported on all release branches back to 8.5 (where this was seen).
You should be able to temporarily update your R8 version by doing something like (remove again when you update to the a new AGP version or you will be stuck on an old R8 version):
pluginManagement {
buildscript {
repositories {
mavenCentral()
maven {
url = uri("https://storage.googleapis.com/r8-releases/raw")
}
}
dependencies {
classpath("com.android.tools:r8:8.5.49")
}
}
}
an...@google.com <an...@google.com> #49
Thank you for your patience while our engineering team worked to resolve this issue. A fix for this issue is now available in:
- Android Studio Ladybug Feature Drop | 2024.2.2 Patch 1
- Android Gradle Plugin 8.8.1
We encourage you to try the latest update.
If you notice further issues or have questions, please file a new bug report.
Thank you for taking the time to submit feedback — we really appreciate it!
Description
We have recently started experiencing an intermittent crash right as the release build of our app opens. From one commit to the next the issue will be present/not present, all changes that appear unrelated to this class. Setting
-dontoptimize
appears to fix the issue (though we are not certain, given that the issue comes and goes from commit to commit)We have the following in our proguard files, and have confirmed when inspecting our DEX file that
LazyThreadSafetyMode
is present (screenshot attached).-keep class kotlin.** { *; }