Re-compile on userfaultfd phenotype flag change.
After this change, odrefresh re-compiles everything when the phenotype
flag `runtime_native_boot.enable_uffd_gc` changes. It writes the value
of the flag to cache-info.xml for change detection.
According to go/platform-experiment-namespaces#namespace-types, the
phenotype flag is back by a persistent system property. Therefore, we
can directly read the flag from the system property instead of depending
on the `server_configurable_flags` library. This behavior is consistent
with the existing ART code (particularly, `art::Flag`), which reads
other phenotype flags.
Bug: 231298279
Test: atest odsign_e2e_tests_full
Ignore-AOSP-First: Merge conflict. Will cherry-pick later.
Change-Id: I02b70569ecd96d4ded6d2d3be22c34b2c6a4c5b4
diff --git a/odrefresh/CacheInfo.xsd b/odrefresh/CacheInfo.xsd
index 1cbef8a..196caf7 100644
--- a/odrefresh/CacheInfo.xsd
+++ b/odrefresh/CacheInfo.xsd
@@ -27,6 +27,7 @@
<!-- True if the cache info is generated in the Compilation OS. -->
<xs:attribute name="compilationOsMode" type="xs:boolean" />
<xs:sequence>
+ <xs:element name="systemProperties" minOccurs="1" maxOccurs="1" type="t:keyValuePairList" />
<xs:element name="artModuleInfo" minOccurs="1" maxOccurs="1" type="t:moduleInfo" />
<xs:element name="moduleInfoList" minOccurs="1" maxOccurs="1" type="t:moduleInfoList" />
<xs:element name="bootClasspath" minOccurs="1" maxOccurs="1" type="t:classpath" />
@@ -36,6 +37,19 @@
</xs:complexType>
</xs:element>
+ <!-- List of key-value pairs. -->
+ <xs:complexType name="keyValuePairList">
+ <xs:sequence>
+ <xs:element name="item" type="t:keyValuePair" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <!-- A key-value pair. -->
+ <xs:complexType name="keyValuePair">
+ <xs:attribute name="k" type="xs:string" use="required" />
+ <xs:attribute name="v" type="xs:string" use="required" />
+ </xs:complexType>
+
<!-- List of modules. -->
<xs:complexType name="moduleInfoList">
<xs:sequence>