File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed
Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -234,6 +234,24 @@ static public boolean isHighEndGfx(Display display) {
234234 return false ;
235235 }
236236
237+ /**
238+ * Use to decide whether the running device can be considered a "large
239+ * RAM" device. Exactly what memory limit large RAM is will vary, but
240+ * it essentially means there is plenty of RAM to have lots of background
241+ * processes running under decent loads.
242+ * @hide
243+ */
244+ static public boolean isLargeRAM () {
245+ MemInfoReader reader = new MemInfoReader ();
246+ reader .readMemInfo ();
247+ if (reader .getTotalSize () >= (640 *1024 *1024 )) {
248+ // Currently 640MB RAM available to the kernel is the point at
249+ // which we have plenty of RAM to spare.
250+ return true ;
251+ }
252+ return false ;
253+ }
254+
237255 /**
238256 * Information you can retrieve about tasks that the user has most recently
239257 * started or visited.
You can’t perform that action at this time.
0 commit comments