Android Question App performance degradation after update

johnf2013

Member
Licensed User
Longtime User
Does anyone have any idea about this issue because I cannot find the answer myself.

I am developing an app which is computationally intensive and makes heavy use of vector drawing functions. The design goal is a screen refresh rate of 50Hz and so far it is achieving this easily. Data for the app is being provided by a remote embedded device which itself is quite capable so when I reach the limits of the Android phone I will just begin offloading functionality to the remote device.

If I compile and run the app it runs very fast, both in the emulator and on the real device. If I make any change, even the most minor change, and update the running app then it runs so slow it is barely useable. We are talking 2 orders of magnitude here!!! The only way to make it go fast again is to perform a "Clean Project" followed by a "Compile and Run".

This is rather tedious.

I thought I may have a configuration problem but I am at a loss to find it.
Any clues to track this down would be appreciated. Thanks.

Update: This behavior stopped after a reboot of the computer. It has not happened again and if it does I will post again with everything I can find. It is good that the problem is gone. It is bad that it ever happened in the first instance.
 
Last edited:

johnf2013

Member
Licensed User
Longtime User
Yes. Clean Project does fix it, but it is only temporary. It seems that simple changes do not usually cause a problem but more complex ones do. For example if I change the value of a constant then problems do not occur, but if I change a formula with a trancendental function in it then it almost guarantees the program will run slow - really slow - until I clean the project. It runs slow on the emulator as well as the real device, and it looks like it has something to do with the debugger because release versions do not exhibit this behavior.
Consistent behavior in a development system would be nice to have. If I have a configuration issue I would like to fix it but I have run out of things to configure.
 
Upvote 0

Erel

B4X founder
Staff member
Licensed User
Longtime User
Consistent behavior in a development system would be nice to have.
Add:
B4X:
#DebuggerForceFullDeployment: true
This will disable the quick deployment mode and it will run fast.

The debugger can update code without making a full deployment. It is however executed in a slower pipeline. Cleaning the project or setting the above attribute will force it to make full deployments.
 
Upvote 0
Top