8 Replies Latest reply on Oct 29, 2008 12:58 AM by asohangh

    how to build BROOK code in active (release) configuration (VC++)

    AIGPU

       

      Hi,

      I tried to build hello_brook in active (release) configuration. The implicitly debug building mode it’s working. When I switch to active configuration (VC++ 2008 Express Edition), the building is performed, but when I run the program, a dialog window appears stating: “Debugging information for ‘hello_brook.exe’ cannot be found or does not match. Binary was not built with debug information.” Ignoring the message generates the folowing output:

      'hello_brook.exe': Loaded 'I:\samples\bin\xp_x86_32\hello_brook.exe', Binary was not built with debug information.

      'hello_brook.exe': Loaded 'C:\WINDOWS\system32\ntdll.dll'

      'hello_brook.exe': Loaded 'C:\WINDOWS\system32\kernel32.dll'

      'hello_brook.exe': Loaded 'C:\Program Files\AMD\AMD BROOK 1.01.0_beta\sdk\lib\brook.dll', Binary was not built with debug information.

      'hello_brook.exe': Loaded 'C:\Program Files\AMD\AMD CAL 1.01.1_beta\lib\xp32\amdcalcl.dll'

      'hello_brook.exe': Loaded 'C:\Program Files\AMD\AMD CAL 1.01.1_beta\lib\xp32\amdcalrt.dll'

      'hello_brook.exe': Loaded 'C:\WINDOWS\system32\user32.dll'

      'hello_brook.exe': Loaded 'C:\WINDOWS\system32\gdi32.dll'

      'hello_brook.exe': Loaded 'C:\WINDOWS\system32\advapi32.dll'

      'hello_brook.exe': Loaded 'C:\WINDOWS\system32\rpcrt4.dll'

      'hello_brook.exe': Loaded 'C:\WINDOWS\system32\secur32.dll'

      The program '[1992] hello_brook.exe: Native' has exited with code -1 (0xffffffff).

       

      Thank you.

        • how to build BROOK code in active (release) configuration (VC++)
          Ceq
          Umh, are you clicking the green play button with label "Start Debugging"?
          If you want to launch normal execution with a button you have to add another similar button to the toolbar called "Start Without Debugging" or click it in the "Debug" menu.
            • how to build BROOK code in active (release) configuration (VC++)
              AIGPU

              Pressing CTRL-F5 (Start without debugging) in Visual C++ Express Edition 2008 resulted in:

              ERROR: No appropriate map technique found (out of 0 available)

              Press any key to continue ...

              I founded this http://forums.amd.com/forum/messageview.cfm?catid=328&threadid=97918 , but in VC++ I don't know from where I can disable address translation (if realy this is the problem).

                • how to build BROOK code in active (release) configuration (VC++)
                  ryta1203
                  1. Build in Release mode (looks like you are doing this)
                  2. In file properties make sure that the "-A" is not there (address translation).
                  3. Check out this thread: http://forums.amd.com/devforum...d=94972&enterthread=y
                  4. Check out this thread: http://forums.amd.com/devforum...id=92759&enterthread=y (scroll down toward the bottom)
                    • how to build BROOK code in active (release) configuration (VC++)
                      AIGPU

                       

                      Thanks for info, ryta1203.

                       

                      I have read the posts from your links. In hello_brook.vcproj, I edited the line for win32 release configuration to (I have added –r to disable address virtualization):

                      CommandLine=""$(BROOKROOT)sdk\bin\brcc.exe " -r -o "$(ProjectDir)\built\$(ProjectName)" "$(InputPath)" "

                       

                      Sadly, the result is the same.

                       

                      Observation: When I have tried to add –r to debug configuration, also I receive a similar error:

                      ERROR: No appropriate map technique found (out of 1 available)

                      Now is 1 available (in debug mode)!

                       

                      What I have to do next ?

                       

                        • how to build BROOK code in active (release) configuration (VC++)
                          ryta1203
                          AIGPU, I'm just a user so hopefully someone from AMD will answer this thread (they kind of pick and choose which threads to respond to), but:

                          1. VC2008 is not fully supported (only preliminarily supported via the release notes). I am using VC2005 with 4850 and don't have any problems running Hello_Brook out of the box.
                          2. You shouldn't have to add the -r, or at least I didn't.
                          3. When running in Release mode, I also got the dialog box that you mention in your first post, I just said "don't show me again" and ignored it, no problems. Is your ERROR: No appropriate map technique found (out of 1 available) coming up in the console window or a dialog box?
                            • how to build BROOK code in active (release) configuration (VC++)
                              AIGPU

                              The message "ERROR: No appropriate map technique found (out of 1 available)" appears in console (debug configuration with manually eddited vcproj by adding -r).

                              Without -r debug mode is working.

                              Release mode is not working (with or without -r), but the message from console is :

                              "ERROR: No appropriate map technique found (out of 0 available)"


                              Edit 1:

                              I have implemented a Convolutional Neural Network both on CPU and on GPU. The GPU variant is slower! I hope this is mainly because of the debug mode.

                              Edit2:

                              I have instaled VC++ 2005 Express Edition and I can run the programs in release mode.

                                • how to build BROOK code in active (release) configuration (VC++)
                                  foxx1337

                                  This is old, but just for the sake of Google search:

                                  with the latest Brook+ 1.2 beta, in order to get it going with Visual Studio 2008, one should simply load and convert "$(BROOKROOT)\platform\brook.sln" into DevEnv and rebuild the "runtime" project, for both Debug and Release configurations.

                                  Before this, fix Project Properties - Linker - General - Additional Library Directories to point to "$(CALROOT)\lib\LH64" (or LH32, i'm on 2008 server x64 here) and Build Events - Post-Build Event - Command Line to read copy "$(TargetDir)\$(TargetFileName)" "$(BROOKROOT)\sdk\lib\" (Program Files (x86) contains spaces and the copy command fails) for the configurations.

                                  Don't forget to also copy the .lib files from, for example "$(BROOKROOT)\platform\runtime\lib\xp_x86_64" to "$(BROOKROOT)\sdk\lib".

                                  Probably an ABI incompatibility between VS 2005 and 2008.

                                    • how to build BROOK code in active (release) configuration (VC++)
                                      asohangh

                                       

                                      Originally posted by: foxx1337 This is old, but just for the sake of Google search:

                                       

                                      with the latest Brook+ 1.2 beta, in order to get it going with Visual Studio 2008, one should simply load and convert "$(BROOKROOT)\platform\brook.sln" into DevEnv and rebuild the "runtime" project, for both Debug and Release configurations.

                                       

                                      Before this, fix Project Properties - Linker - General - Additional Library Directories to point to "$(CALROOT)\lib\LH64" (or LH32, i'm on 2008 server x64 here) and Build Events - Post-Build Event - Command Line to read copy "$(TargetDir)\$(TargetFileName)" "$(BROOKROOT)\sdk\lib\" (Program Files (x86) contains spaces and the copy command fails) for the configurations.

                                       

                                      Don't forget to also copy the .lib files from, for example "$(BROOKROOT)\platform\runtime\lib\xp_x86_64" to "$(BROOKROOT)\sdk\lib".

                                       

                                      Probably an ABI incompatibility between VS 2005 and 2008.

                                       

                                       

                                      Thanks for that fix foxx, I wasn't able to get the hello_brook code to build and run with VS2008 and that helped me out a lot.  I hadn't even thought to install the Brook+ source code at first.