Active Topics

 


Reply
Thread Tools
Posts: 213 | Thanked: 414 times | Joined on Nov 2010
#121
Demo works on Xiaomi Redmi Note 4, on 2.1.2.3.
 

The Following 2 Users Say Thank You to piggz For This Useful Post:
Posts: 1,414 | Thanked: 7,547 times | Joined on Aug 2016 @ Estonia
#122
@Zeta, I wonder if you could try to run the demo from

http://repo.merproject.org/obs/home:...mv7hl/armv7hl/

I tried to recompile qmapboxgl with the debug flag and remove ndebug option. Maybe your backtrace will have a bit more info then and we could submit it into the issue at github?
 

The Following 2 Users Say Thank You to rinigus For This Useful Post:
Posts: 339 | Thanked: 1,623 times | Joined on Oct 2013 @ France
#123
Originally Posted by rinigus View Post
@Zeta, I wonder if you could try to run the demo from

http://repo.merproject.org/obs/home:...mv7hl/armv7hl/
No problem to test !

So, first removing all previous *mapbox* programs, changing the repo to maps-debug, and installing the new version (pkcon install.... like previous tries), I still get a crash but with a simple null pointer as the source:

Code:
(gdb) bt full
#0  0x00000000 in ?? () 
No symbol table info available.
#1  0x2a18d280 in mbgl::gl::checkError(char const*, char const*, int) ()
No symbol table info available.
#2  0x2a18b5a6 in mbgl::gl::Context::initializeExtensions(std::function<void (*(char const*))()> const&) ()
No symbol table info available.
#3  0x2a0ed672 in void std::call_once<mbgl::RendererBackend::getContext()::{lambda()#1}>(std::once_flag&, mbgl::RendererBackend::getContext()::{lambda()#1}&&)::{lambda()#2}::_FUN() ()
No symbol table info available.
#4  0x40dee35c in __GI___pthread_once (once_control=0x44f224a0, init_routine=0x2a2fd6b9 <__once_proxy+1>) at ../ports/sysdeps/unix/sysv/linux/arm/nptl/pthread_once.c:76
        _buffer = {__routine = 0x40dee2cd <clear_once_control>, __arg = 0x44f224a0, __canceltype = 709104808, __prev = 0x0}
#5  0x2a0ed730 in mbgl::RendererBackend::getContext() ()
No symbol table info available.
#6  0x2a0ef176 in mbgl::Renderer::Impl::render(mbgl::UpdateParameters const&) ()
No symbol table info available.
#7  0x2a0e21c2 in QMapboxGLRendererFrontend::render() ()
No symbol table info available.
#8  0x2a08514c in QSGMapboxGLTextureNode::render (this=this@entry=0x44f61068, window=0x2a456308) at mapbox-gl-qml/src/qsgmapboxglnode.cpp:111
        loaded = false
        alignment = 4
#9  0x2a07effe in QQuickItemMapboxGL::updatePaintNode (this=0x2a54ab50, node=<optimized out>) at mapbox-gl-qml/src/qquickitemmapboxgl.cpp:769
        n = 0x44f61068
        sz = {wd = 540, ht = 960}
        map = 0x44f066c8
        loaded = <optimized out>
        tol = <optimized out>
#10 0x401fc970 in QQuickWindowPrivate::updateDirtyNode(QQuickItem*) () from /usr/lib/libQt5Quick.so.5
No symbol table info available.
#11 0x44f29618 in ?? ()
No symbol table info available.
#12 0x44f29618 in ?? ()
No symbol table info available.
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
So there must be a function pointer not initialized called by mbgl::gl::checkError().

If the version I have localy match the one you use, that would mean something like this causes the crash (from "mapbox-gl-native/src/mbgl/gl/gl.cpp") :
Code:
void checkError(const char* cmd, const char* file, int line) {
//    fprintf(stderr, "cmd: %s\n", cmd);
    GLenum err = GL_NO_ERROR;
    if ((err = glGetError()) != GL_NO_ERROR) {
        std::string message = std::string(cmd) + ": Error " + stringFromError(err);

        // Check for further errors
        while ((err = glGetError()) != GL_NO_ERROR) {
            message += ", ";
            message += stringFromError(err);
        }

        throw Error(message + " at " + file + ":" + util::toString(line));
    }
}
Not sure how the "throw" would be handled in a Qt context which doesn't use exceptions. Otherwise, there is not much that could call adress 0x0, everything else being static, so not due to a null object ?

What could help is to find a way to resolve the "No symbol table info available." messages, to be able to see local variables at each step. I have installed as much a I can (-debuginfo, -debugsource), but something is still missing.
 

The Following 2 Users Say Thank You to Zeta For This Useful Post:
Posts: 1,414 | Thanked: 7,547 times | Joined on Aug 2016 @ Estonia
#124
Zeta, thank you!

Throwing exceptions works quite nicely - the app dumps core on them with the corresponding exception message on the terminal. However, it maybe disturbed with static stdc++ builds. So, I made a new demo build with shared stdc++ linking under

https://build.merproject.org/package...pbox-demo-sfos

- maybe we'll get exception string that way.

As for how to get rid of these missing symbols - don't know. Somehow I cannot master that

Meanwhile, I am preparing the plugin for release. Its API is documented now in the repository and I have just to test gesture area separation before releasing the plugin.
 

The Following 3 Users Say Thank You to rinigus For This Useful Post:
Posts: 339 | Thanked: 1,623 times | Joined on Oct 2013 @ France
#125
Originally Posted by rinigus View Post
So, I made a new demo build with shared stdc++ linking under
https://build.merproject.org/package...pbox-demo-sfos
Just tested it for two minutes without any crash !

So it works on the Jolla 1 with this style.

So the crash we had before could be related to GPU memory exhaustion when using the full style, or that there are some gl calls not done in this simplified style ?
 

The Following User Says Thank You to Zeta For This Useful Post:
Posts: 1,414 | Thanked: 7,547 times | Joined on Aug 2016 @ Estonia
#126
Originally Posted by Zeta View Post
Just tested it for two minutes without any crash !

So it works on the Jolla 1 with this style.

So the crash we had before could be related to GPU memory exhaustion when using the full style, or that there are some gl calls not done in this simplified style ?
This is strange. I also wonder why statically linked c++ library resulted in a crash? Note that I had dynamic linking in the original demo version.

Maybe we should try to make the same test using just QML component. I'll make a simple QML app that would display the same map. I wonder if static linking would again be a problem...

I have opened a new thread with the announcement of Mapbox GL QML plugin at http://talk.maemo.org/showthread.php?p=1536584 since I think its ready now for the development. Should we move our debugging discussion over there?

Edit: QML-only demo is at https://github.com/rinigus/mapbox-de...aster/qml-only . You would need the both QML files in this directory and just to run

qmlscene mapbox-gl-qml.qml

when they are on device

Last edited by rinigus; 2017-10-12 at 18:18.
 

The Following User Says Thank You to rinigus For This Useful Post:
Reply


 
Forum Jump


All times are GMT. The time now is 05:51.