6 Replies Latest reply on Oct 12, 2016 7:30 AM by stephanp

    issue with radeon driver on Ubuntu 16.04

    stephanp

      Hello,

       

      i recently upgraded my sytem to Ubuntu 16.04. Since there is no fglrx driver for my AMD gpus, i had to use the radeon driver.

       

      My OpenGL application runs two windows on two gpus (each within its own thread). I used GLFW library. The gpus are two Radeon HD 7870.

       

      The application crashes when the second window tries to swap buffers. If I comment out the second swapbuffers call, everything runs at least.

       

      I tried with a much simpler test program, having two windows on the same gpu, with the same results.

       

      I know the driver development for Ubuntu 16.04 is still in progress, but maybe someone has an advice or workaround for this issue.

       

      Thanks in advance.

        • Re: issue with radeon driver on Ubuntu 16.04
          dwitczak

          Thank you for your report. Before I can forward it to the relevant team, I'm going to need to ask you for to provide a simple test app which reproduces the problem. Would you be able to provide one?

          • Re: issue with radeon driver on Ubuntu 16.04
            stephanp

            here's a simple test program: (sorry i don't know how to format the code correctly)

             

            // Include standard headers

            #include <stdio.h>

            #include <stdlib.h>

             

            // Include GLEW

            #include <GL/glew.h>

             

            // Include GLFW

            #include <glfw3.h>

            GLFWwindow* window1, window2;

             

             

            int main( void )

            {

                // Initialise GLFW

                if( !glfwInit() )

                {

                    fprintf( stderr, "Failed to initialize GLFW\n" );

                    return -1;

                }

             

                // Open the first window and create its OpenGL context

                window1 = glfwCreateWindow( 1024, 768, "Window1", NULL, NULL);

                if( window1 == NULL ){

                    glfwTerminate();

                    return -1;

                }

                glfwMakeContextCurrent(window1);

             

                // Initialize GLEW

                if (glewInit() != GLEW_OK) {

                    fprintf(stderr, "Failed to initialize GLEW\n");

                    return -1;

                }

             

                glfwSetInputMode(window1, GLFW_STICKY_KEYS, GL_TRUE);

             

                // Open the second window and create its OpenGL context

                window2 = glfwCreateWindow( 1024, 768, "Window2", NULL, NULL);

                if( window2 == NULL ){

                    glfwTerminate();

                    return -1;

                }

                glfwMakeContextCurrent(window2);

             

                do{

                    // Draw stuff

             

                    // Swap buffers

                    glfwSwapBuffers(window1);

                    glfwSwapBuffers(window2);   // <- the app crashes at this point!

             

                    glfwPollEvents();

             

                } // Check if the ESC key was pressed or the window was closed

                while( glfwGetKey(window1, GLFW_KEY_ESCAPE ) != GLFW_PRESS &&

                       glfwWindowShouldClose(window1) == 0 );

             

                // Close OpenGL window and terminate GLFW

                glfwTerminate();

             

                return 0;

            }