google / gapid

Graphics API Debugger
https://gapid.dev
Apache License 2.0
2.2k stars 327 forks source link

Fails to work on Android 7.1 on Google Pixelbook 2017 with Linux host #1611

Open linyaa-kiwi opened 6 years ago

linyaa-kiwi commented 6 years ago

Summary

The gapid gui is unable to scan the packages/actions on my Android 7.1 client when running the gui on a Linux desktop.

Details

Using the official gapid-1.0.2-linux.zip.

The Android 7.1 device is the Google Pixelbook 2017, codenamed "Eve". Specifically, the client is the ARC++ container running inside Chrome OS. The Android device supports the following ABIs according to getprop: x86_64 (primary), x86, armeabi-v7a, armeabi.

The gapid gui is running on Google's internal Debian distro.

Logs & Screen Capture

Attached is a short (17s) screen capture of my problem; logs and device info (such as the GLES and Vulkan capabilities) of the Android device; and the stdout/stderr of gapid.

(Apologies for zipping the mp4 file, but Github rejects stand-alone video files).

2018-02-09-23-31-56Z-chadversary--android-dumpsys-surfaceflinger.log 2018-02-09-23-31-56Z-chadversary--android-getprop.log 2018-02-09-23-31-56Z-chadversary--android-vkinfo.log 2018-02-09-23-31-56Z-chadversary--gapid.log 2018-02-09-23-31-56Z-chadversary--gapid-screen-capture.mp4.zip

Armchair Diagnosis

The device's primary ABI is x86_64, but the gapid binary releases do not provide gapid-x86_64.apk.

ben-clayton commented 6 years ago

Hi @chadversary, Sorry for not getting back to sooner - I've been swamped.

From the gapid log:
Error: getting package list
   Cause: Opening gapid.apk
   Cause: read /usr/local/google/home/chadversary/.local/opt/gapid-1.0.2: is a directory

This does look like we're trying to load an APK of an ABI we do not support (likely x86_64 as you suggest). Let me look into this error and see if I can improve the message to confirm.

pmuetschard commented 6 years ago

Another thing to consider is to use one of the fallback ABIs.

The Android device supports the following ABIs: x86_64 (primary), x86, armeabi-v7a, armeabi.

Since we don't support the primary ABI, we should fallback to x86.

ben-clayton commented 6 years ago

Agreed. I'll try to get my hands on one of these devices so I can reproduce and make the necessary fixes.