Thanks for everybody's reply.
I solved this problem!
Like I said before, I found that the application would search all the events under the /dev/input, even you don't use any input event plugin (tslib, evdevtouch, evdevkeyboard...etc). This would cause the app delay to show.
Therefore, I traced the source code to find where the setting is, and finally I found that in the following code:
//Qt5.3/qtbase/src/platformsupport/devicediscovery/qdevicediscovery_static.cpp
in this file, the function
QDeviceDiscovery::scanConnectedDevices()
would search /dev/input/
This code finally will be compiled and package as libQt5PlatformSupport.a
and the platform eglfs will use this.
In the file Qt5.3/qtbase/src/plugins/platforms/eglfs/qeglfsintegration.cpp, if there is no export variable set, that is, QT_QPA_EGLFS_DISABLE_INPUT, the plugin will set the variable mDisableInputHandlers to be false. This flag finally will start to search all event under /dev/input, and hence slow down the app to show.
In fact, I tried that before I ran the app, I set the export:
export QT_QPA_EGLFS_DISABLE_INPUT=1
and the app would show within 4,5 sec. This proved the setting indeed affect the speed.
Of course, this time still did not satisfy me, so I still used the tool strace to find another possibility. Finally I found that the font would cause the delay too. In my platform, the original font is DroidSansFallback.ttf in the /usr/local/Qt5.3/lib/fonts. When I selected another font, msyh.ttf. It was apparently that the app will show within about 1 sec. That is what I want. :)
By the way, if I choose this font, there is no difference that set the path in the file /etc/fonts/font.conf, that is, even I set the path to be /usr/share/fonts. The speed seems no much difference.
Finally, let me make 2 short conclusions:
set the flag QT_QPA_EGLFS_DISABLE_INPUT to be true, that is,
export QT_QPA_EGLFS_DISABLE_INPUT=1
before start to run the app.
2.check what the font you used
at least, use msyh.ttf is faster than DroidSansFallback.ttf in my platform.
I am not sure that the above comments are totally right or not, so if someone finds any wrong, please also let me know.
Thanks for everybody's opinion!