[6.2.0][技术优化] 添加BitmapFactory解码耗时检测

This commit is contained in:
renwj
2023-11-22 15:56:49 +08:00
parent a4b193385c
commit 4e99e35637
2 changed files with 13 additions and 1 deletions

View File

@@ -8,6 +8,8 @@ import android.app.Service;
import android.content.BroadcastReceiver;
import android.content.ContentProvider;
import android.content.pm.PackageManager;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.opengl.GLSurfaceView;
import android.os.SystemClock;
import android.view.View;
@@ -22,6 +24,7 @@ import com.mogo.core.lancetx.compiler.lib.generator.Type;
import java.io.File;
import java.io.InputStream;
import java.nio.channels.FileChannel;
import java.util.concurrent.locks.Lock;
import java.util.concurrent.locks.LockSupport;
@@ -394,4 +397,13 @@ class JankPointAutoGenerator {
}
)
private GLSurfaceView.Renderer renderer;
@LancetXGenerator(
group = "main_block_check",
type = Type.IO,
scope = Scope.SELF,
hookType = HookType.REPLACE_INVOKE,
hookAllPublicMethods = true
)
private BitmapFactory factory;
}

View File

@@ -209,7 +209,7 @@ ext {
//========================= LancetX ===================
lancetx_runtime : "io.github.knight-zxw:lancet-runtime:10.50.0",
lancetx_compiler : "com.mogo.eagle.core.lancetx:compiler:1.0.5",
lancetx_compiler : "com.mogo.eagle.core.lancetx:compiler:1.0.6",
lancetx_compiler_lib : "com.mogo.eagle.core.lancetx:runtime:1.0.5",