Re: [Lldb-commits] [PATCH] D13816: Fix a some silly warnings
artagnon updated this revision to Diff 37611. artagnon added a comment. Er, silly mistake (build failure) http://reviews.llvm.org/D13816 Files: source/Commands/CommandObjectMemory.cpp tools/debugserver/source/RNBRemote.cpp tools/debugserver/source/debugserver.cpp Index: tools/debugserver/source/debugserver.cpp === --- tools/debugserver/source/debugserver.cpp +++ tools/debugserver/source/debugserver.cpp @@ -313,7 +313,6 @@ switch (pid_state) { -default: case eStateInvalid: case eStateUnloaded: case eStateAttaching: @@ -631,28 +630,28 @@ while (mode == eRNBRunLoopModePlatformMode) { std::string set_events_str; -const uint32_t event_mask = RNBContext::event_read_packet_available | +const uint32_t event_mask = RNBContext::event_read_packet_available | RNBContext::event_read_thread_exiting; - + DNBLogThreadedIf (LOG_RNB_EVENTS, "%s ctx.Events().WaitForSetEvents(0x%08x) ...",__FUNCTION__, event_mask); nub_event_t set_events = ctx.Events().WaitForSetEvents(event_mask); DNBLogThreadedIf (LOG_RNB_EVENTS, "%s ctx.Events().WaitForSetEvents(0x%08x) => 0x%08x (%s)",__FUNCTION__, event_mask, set_events, ctx.EventsAsString(set_events, set_events_str)); - + if (set_events) { if (set_events & RNBContext::event_read_packet_available) { if (remote->HandleReceivedPacket() == rnb_not_connected) mode = eRNBRunLoopModeExit; } - + if (set_events & RNBContext::event_read_thread_exiting) { mode = eRNBRunLoopModeExit; } ctx.Events().ResetEvents(set_events); } -} +} return eRNBRunLoopModeExit; } @@ -665,9 +664,9 @@ PortWasBoundCallbackUnixSocket (const void *baton, in_port_t port) { //::printf ("PortWasBoundCallbackUnixSocket (baton = %p, port = %u)\n", baton, port); - + const char *unix_socket_name = (const char *)baton; - + if (unix_socket_name && unix_socket_name[0]) { // We were given a unix socket name to use to communicate the port @@ -679,37 +678,37 @@ perror("error: socket (AF_UNIX, SOCK_STREAM, 0)"); exit(1); } - + saddr_un.sun_family = AF_UNIX; ::strncpy(saddr_un.sun_path, unix_socket_name, sizeof(saddr_un.sun_path) - 1); saddr_un.sun_path[sizeof(saddr_un.sun_path) - 1] = '\0'; saddr_un.sun_len = SUN_LEN (&saddr_un); - + if (::connect (s, (struct sockaddr *)&saddr_un, static_cast(SUN_LEN (&saddr_un))) < 0) { perror("error: connect (socket, &saddr_un, saddr_un_len)"); exit(1); } - + //::printf ("connect () sucess!!\n"); - - + + // We were able to connect to the socket, now write our PID so whomever // launched us will know this process's ID RNBLogSTDOUT ("Listening to port %i...\n", port); - + char pid_str[64]; const int pid_str_len = ::snprintf (pid_str, sizeof(pid_str), "%u", port); const ssize_t bytes_sent = ::send (s, pid_str, pid_str_len, 0); - + if (pid_str_len != bytes_sent) { perror("error: send (s, pid_str, pid_str_len, 0)"); exit (1); } - + //::printf ("send () sucess!!\n"); - + // We are done with the socket close (s); } @@ -887,7 +886,7 @@ #if defined (__arm__) || defined (__arm64__) || defined (__aarch64__) struct sched_param thread_param; int thread_sched_policy; -if (pthread_getschedparam(pthread_self(), &thread_sched_policy, &thread_param) == 0) +if (pthread_getschedparam(pthread_self(), &thread_sched_policy, &thread_param) == 0) { thread_param.sched_priority = 47; pthread_setschedparam(pthread_self(), thread_sched_policy, &thread_param); @@ -909,25 +908,25 @@ //signal (SIGINT, signal_handler); signal (SIGPIPE, signal_handler); signal (SIGHUP, signal_handler); - + // We're always sitting in waitpid or kevent waiting on our target process' death, // we don't need no stinking SIGCHLD's... - + sigset_t sigset; sigemptyset(&sigset); sigaddset(&sigset, SIGCHLD); sigprocmask(SIG_BLOCK, &sigset, NULL); g_remoteSP.reset (new RNBRemote ()); - - + + RNBRemote *remote = g_remoteSP.get(); if (remote == NULL) { RNBLogSTDERR ("error: failed to create a remote connection class\n"); return -1; } - + RNBContext& ctx = remote->Context(); int i; @@ -959,20 +958,20 @@
[Lldb-commits] [PATCH] D13816: Fix a some silly warnings
artagnon created this revision. artagnon added a reviewer: clayborg. artagnon added a subscriber: lldb-commits. http://reviews.llvm.org/D13816 Files: source/Commands/CommandObjectMemory.cpp tools/debugserver/source/RNBRemote.cpp tools/debugserver/source/debugserver.cpp Index: tools/debugserver/source/debugserver.cpp === --- tools/debugserver/source/debugserver.cpp +++ tools/debugserver/source/debugserver.cpp @@ -313,7 +313,6 @@ switch (pid_state) { -default: case eStateInvalid: case eStateUnloaded: case eStateAttaching: @@ -631,28 +630,28 @@ while (mode == eRNBRunLoopModePlatformMode) { std::string set_events_str; -const uint32_t event_mask = RNBContext::event_read_packet_available | +const uint32_t event_mask = RNBContext::event_read_packet_available | RNBContext::event_read_thread_exiting; - + DNBLogThreadedIf (LOG_RNB_EVENTS, "%s ctx.Events().WaitForSetEvents(0x%08x) ...",__FUNCTION__, event_mask); nub_event_t set_events = ctx.Events().WaitForSetEvents(event_mask); DNBLogThreadedIf (LOG_RNB_EVENTS, "%s ctx.Events().WaitForSetEvents(0x%08x) => 0x%08x (%s)",__FUNCTION__, event_mask, set_events, ctx.EventsAsString(set_events, set_events_str)); - + if (set_events) { if (set_events & RNBContext::event_read_packet_available) { if (remote->HandleReceivedPacket() == rnb_not_connected) mode = eRNBRunLoopModeExit; } - + if (set_events & RNBContext::event_read_thread_exiting) { mode = eRNBRunLoopModeExit; } ctx.Events().ResetEvents(set_events); } -} +} return eRNBRunLoopModeExit; } @@ -665,9 +664,9 @@ PortWasBoundCallbackUnixSocket (const void *baton, in_port_t port) { //::printf ("PortWasBoundCallbackUnixSocket (baton = %p, port = %u)\n", baton, port); - + const char *unix_socket_name = (const char *)baton; - + if (unix_socket_name && unix_socket_name[0]) { // We were given a unix socket name to use to communicate the port @@ -679,37 +678,37 @@ perror("error: socket (AF_UNIX, SOCK_STREAM, 0)"); exit(1); } - + saddr_un.sun_family = AF_UNIX; ::strncpy(saddr_un.sun_path, unix_socket_name, sizeof(saddr_un.sun_path) - 1); saddr_un.sun_path[sizeof(saddr_un.sun_path) - 1] = '\0'; saddr_un.sun_len = SUN_LEN (&saddr_un); - + if (::connect (s, (struct sockaddr *)&saddr_un, static_cast(SUN_LEN (&saddr_un))) < 0) { perror("error: connect (socket, &saddr_un, saddr_un_len)"); exit(1); } - + //::printf ("connect () sucess!!\n"); - - + + // We were able to connect to the socket, now write our PID so whomever // launched us will know this process's ID RNBLogSTDOUT ("Listening to port %i...\n", port); - + char pid_str[64]; const int pid_str_len = ::snprintf (pid_str, sizeof(pid_str), "%u", port); const ssize_t bytes_sent = ::send (s, pid_str, pid_str_len, 0); - + if (pid_str_len != bytes_sent) { perror("error: send (s, pid_str, pid_str_len, 0)"); exit (1); } - + //::printf ("send () sucess!!\n"); - + // We are done with the socket close (s); } @@ -887,7 +886,7 @@ #if defined (__arm__) || defined (__arm64__) || defined (__aarch64__) struct sched_param thread_param; int thread_sched_policy; -if (pthread_getschedparam(pthread_self(), &thread_sched_policy, &thread_param) == 0) +if (pthread_getschedparam(pthread_self(), &thread_sched_policy, &thread_param) == 0) { thread_param.sched_priority = 47; pthread_setschedparam(pthread_self(), thread_sched_policy, &thread_param); @@ -909,25 +908,25 @@ //signal (SIGINT, signal_handler); signal (SIGPIPE, signal_handler); signal (SIGHUP, signal_handler); - + // We're always sitting in waitpid or kevent waiting on our target process' death, // we don't need no stinking SIGCHLD's... - + sigset_t sigset; sigemptyset(&sigset); sigaddset(&sigset, SIGCHLD); sigprocmask(SIG_BLOCK, &sigset, NULL); g_remoteSP.reset (new RNBRemote ()); - - + + RNBRemote *remote = g_remoteSP.get(); if (remote == NULL) { RNBLogSTDERR ("error: failed to create a remote connection class\n"); return -1; } - + RNBContext& ctx = remote->Context(); int i; @@ -959,20 +958,20 @@
[Lldb-commits] [PATCH] D13819: LLDBStandalone: Report nice errors on missing vars
artagnon created this revision. artagnon added reviewers: chaoren, brucem. artagnon added a subscriber: lldb-commits. http://reviews.llvm.org/D13819 Files: cmake/modules/LLDBStandalone.cmake Index: cmake/modules/LLDBStandalone.cmake === --- cmake/modules/LLDBStandalone.cmake +++ cmake/modules/LLDBStandalone.cmake @@ -23,22 +23,35 @@ else() get_filename_component(LLVM_MAIN_SRC_DIR ${LLDB_PATH_TO_LLVM_SOURCE} ABSOLUTE) + set(LLVM_MAIN_INCLUDE_DIR "${LLVM_MAIN_SRC_DIR}/include") list(APPEND CMAKE_MODULE_PATH "${LLVM_MAIN_SRC_DIR}/cmake/modules") endif() endif() if (LLDB_PATH_TO_CLANG_SOURCE) get_filename_component(CLANG_MAIN_SRC_DIR ${LLDB_PATH_TO_CLANG_SOURCE} ABSOLUTE) + set(CLANG_MAIN_INCLUDE_DIR "${CLANG_MAIN_SRC_DIR}/include") endif() list(APPEND CMAKE_MODULE_PATH "${LLDB_PATH_TO_LLVM_BUILD}/share/llvm/cmake") - get_filename_component(PATH_TO_LLVM_BUILD ${LLDB_PATH_TO_LLVM_BUILD} - ABSOLUTE) + if (LLDB_PATH_TO_LLVM_BUILD) +get_filename_component(PATH_TO_LLVM_BUILD ${LLDB_PATH_TO_LLVM_BUILD} + ABSOLUTE) + else() +message(FATAL_ERROR "Please set LLDB_PATH_TO_LLVM_BUILD to the root " +"directory of LLVM build or install site.") + endif() + + if (LLDB_PATH_TO_CLANG_BUILD) +get_filename_component(PATH_TO_CLANG_BUILD ${LLDB_PATH_TO_CLANG_BUILD} + ABSOLUTE) + else() +message(FATAL_ERROR "Please set LLDB_PATH_TO_CLANG_BUILD to the root " +"directory of Clang build or install site.") + endif() - get_filename_component(PATH_TO_CLANG_BUILD ${LLDB_PATH_TO_CLANG_BUILD} - ABSOLUTE) # These variables are used by add_llvm_library. set(LLVM_RUNTIME_OUTPUT_INTDIR ${CMAKE_BINARY_DIR}/${CMAKE_CFG_INTDIR}/bin) @@ -67,11 +80,8 @@ set(PACKAGE_VERSION "${LLVM_PACKAGE_VERSION}") - set(LLVM_MAIN_INCLUDE_DIR "${LLVM_MAIN_SRC_DIR}/include") set(LLVM_BINARY_DIR ${CMAKE_BINARY_DIR}) - set(CLANG_MAIN_INCLUDE_DIR "${CLANG_MAIN_SRC_DIR}/include") - set(CMAKE_INCLUDE_CURRENT_DIR ON) include_directories("${PATH_TO_LLVM_BUILD}/include" "${LLVM_MAIN_INCLUDE_DIR}" Index: cmake/modules/LLDBStandalone.cmake === --- cmake/modules/LLDBStandalone.cmake +++ cmake/modules/LLDBStandalone.cmake @@ -23,22 +23,35 @@ else() get_filename_component(LLVM_MAIN_SRC_DIR ${LLDB_PATH_TO_LLVM_SOURCE} ABSOLUTE) + set(LLVM_MAIN_INCLUDE_DIR "${LLVM_MAIN_SRC_DIR}/include") list(APPEND CMAKE_MODULE_PATH "${LLVM_MAIN_SRC_DIR}/cmake/modules") endif() endif() if (LLDB_PATH_TO_CLANG_SOURCE) get_filename_component(CLANG_MAIN_SRC_DIR ${LLDB_PATH_TO_CLANG_SOURCE} ABSOLUTE) + set(CLANG_MAIN_INCLUDE_DIR "${CLANG_MAIN_SRC_DIR}/include") endif() list(APPEND CMAKE_MODULE_PATH "${LLDB_PATH_TO_LLVM_BUILD}/share/llvm/cmake") - get_filename_component(PATH_TO_LLVM_BUILD ${LLDB_PATH_TO_LLVM_BUILD} - ABSOLUTE) + if (LLDB_PATH_TO_LLVM_BUILD) +get_filename_component(PATH_TO_LLVM_BUILD ${LLDB_PATH_TO_LLVM_BUILD} + ABSOLUTE) + else() +message(FATAL_ERROR "Please set LLDB_PATH_TO_LLVM_BUILD to the root " +"directory of LLVM build or install site.") + endif() + + if (LLDB_PATH_TO_CLANG_BUILD) +get_filename_component(PATH_TO_CLANG_BUILD ${LLDB_PATH_TO_CLANG_BUILD} + ABSOLUTE) + else() +message(FATAL_ERROR "Please set LLDB_PATH_TO_CLANG_BUILD to the root " +"directory of Clang build or install site.") + endif() - get_filename_component(PATH_TO_CLANG_BUILD ${LLDB_PATH_TO_CLANG_BUILD} - ABSOLUTE) # These variables are used by add_llvm_library. set(LLVM_RUNTIME_OUTPUT_INTDIR ${CMAKE_BINARY_DIR}/${CMAKE_CFG_INTDIR}/bin) @@ -67,11 +80,8 @@ set(PACKAGE_VERSION "${LLVM_PACKAGE_VERSION}") - set(LLVM_MAIN_INCLUDE_DIR "${LLVM_MAIN_SRC_DIR}/include") set(LLVM_BINARY_DIR ${CMAKE_BINARY_DIR}) - set(CLANG_MAIN_INCLUDE_DIR "${CLANG_MAIN_SRC_DIR}/include") - set(CMAKE_INCLUDE_CURRENT_DIR ON) include_directories("${PATH_TO_LLVM_BUILD}/include" "${LLVM_MAIN_INCLUDE_DIR}" ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
Re: [Lldb-commits] [PATCH] D13816: Fix a some silly warnings
This revision was automatically updated to reflect the committed changes. Closed by commit rL251979: Squelch a silly warning regarding an extra 'default' in 'case' (authored by artagnon). Changed prior to commit: http://reviews.llvm.org/D13816?vs=37611&id=39111#toc Repository: rL LLVM http://reviews.llvm.org/D13816 Files: lldb/trunk/tools/debugserver/source/debugserver.cpp Index: lldb/trunk/tools/debugserver/source/debugserver.cpp === --- lldb/trunk/tools/debugserver/source/debugserver.cpp +++ lldb/trunk/tools/debugserver/source/debugserver.cpp @@ -319,7 +319,6 @@ switch (pid_state) { -default: case eStateInvalid: case eStateUnloaded: case eStateAttaching: @@ -637,28 +636,28 @@ while (mode == eRNBRunLoopModePlatformMode) { std::string set_events_str; -const uint32_t event_mask = RNBContext::event_read_packet_available | +const uint32_t event_mask = RNBContext::event_read_packet_available | RNBContext::event_read_thread_exiting; - + DNBLogThreadedIf (LOG_RNB_EVENTS, "%s ctx.Events().WaitForSetEvents(0x%08x) ...",__FUNCTION__, event_mask); nub_event_t set_events = ctx.Events().WaitForSetEvents(event_mask); DNBLogThreadedIf (LOG_RNB_EVENTS, "%s ctx.Events().WaitForSetEvents(0x%08x) => 0x%08x (%s)",__FUNCTION__, event_mask, set_events, ctx.EventsAsString(set_events, set_events_str)); - + if (set_events) { if (set_events & RNBContext::event_read_packet_available) { if (remote->HandleReceivedPacket() == rnb_not_connected) mode = eRNBRunLoopModeExit; } - + if (set_events & RNBContext::event_read_thread_exiting) { mode = eRNBRunLoopModeExit; } ctx.Events().ResetEvents(set_events); } -} +} return eRNBRunLoopModeExit; } @@ -671,9 +670,9 @@ PortWasBoundCallbackUnixSocket (const void *baton, in_port_t port) { //::printf ("PortWasBoundCallbackUnixSocket (baton = %p, port = %u)\n", baton, port); - + const char *unix_socket_name = (const char *)baton; - + if (unix_socket_name && unix_socket_name[0]) { // We were given a unix socket name to use to communicate the port @@ -685,37 +684,37 @@ perror("error: socket (AF_UNIX, SOCK_STREAM, 0)"); exit(1); } - + saddr_un.sun_family = AF_UNIX; ::strncpy(saddr_un.sun_path, unix_socket_name, sizeof(saddr_un.sun_path) - 1); saddr_un.sun_path[sizeof(saddr_un.sun_path) - 1] = '\0'; saddr_un.sun_len = SUN_LEN (&saddr_un); - + if (::connect (s, (struct sockaddr *)&saddr_un, static_cast(SUN_LEN (&saddr_un))) < 0) { perror("error: connect (socket, &saddr_un, saddr_un_len)"); exit(1); } - + //::printf ("connect () sucess!!\n"); - - + + // We were able to connect to the socket, now write our PID so whomever // launched us will know this process's ID RNBLogSTDOUT ("Listening to port %i...\n", port); - + char pid_str[64]; const int pid_str_len = ::snprintf (pid_str, sizeof(pid_str), "%u", port); const ssize_t bytes_sent = ::send (s, pid_str, pid_str_len, 0); - + if (pid_str_len != bytes_sent) { perror("error: send (s, pid_str, pid_str_len, 0)"); exit (1); } - + //::printf ("send () sucess!!\n"); - + // We are done with the socket close (s); } @@ -893,7 +892,7 @@ #if defined (__arm__) || defined (__arm64__) || defined (__aarch64__) struct sched_param thread_param; int thread_sched_policy; -if (pthread_getschedparam(pthread_self(), &thread_sched_policy, &thread_param) == 0) +if (pthread_getschedparam(pthread_self(), &thread_sched_policy, &thread_param) == 0) { thread_param.sched_priority = 47; pthread_setschedparam(pthread_self(), thread_sched_policy, &thread_param); @@ -915,25 +914,25 @@ //signal (SIGINT, signal_handler); signal (SIGPIPE, signal_handler); signal (SIGHUP, signal_handler); - + // We're always sitting in waitpid or kevent waiting on our target process' death, // we don't need no stinking SIGCHLD's... - + sigset_t sigset; sigemptyset(&sigset); sigaddset(&sigset, SIGCHLD); sigprocmask(SIG_BLOCK, &sigset, NULL); g_remoteSP.reset (new RNBRemote ()); - - + + RNBRemote *remote = g_remoteSP.get(); if (remote == NULL) { RNBLogSTDERR ("error: failed to create a re
[Lldb-commits] [lldb] r251979 - Squelch a silly warning regarding an extra 'default' in 'case'
Author: artagnon Date: Tue Nov 3 15:29:52 2015 New Revision: 251979 URL: http://llvm.org/viewvc/llvm-project?rev=251979&view=rev Log: Squelch a silly warning regarding an extra 'default' in 'case' Let the editor also clean up whitespace for that file. Reviewers: clayborg Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D13816 Modified: lldb/trunk/tools/debugserver/source/debugserver.cpp Modified: lldb/trunk/tools/debugserver/source/debugserver.cpp URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/tools/debugserver/source/debugserver.cpp?rev=251979&r1=251978&r2=251979&view=diff == --- lldb/trunk/tools/debugserver/source/debugserver.cpp (original) +++ lldb/trunk/tools/debugserver/source/debugserver.cpp Tue Nov 3 15:29:52 2015 @@ -319,7 +319,6 @@ RNBRunLoopLaunchInferior (RNBRemote *rem switch (pid_state) { -default: case eStateInvalid: case eStateUnloaded: case eStateAttaching: @@ -637,13 +636,13 @@ RNBRunLoopPlatform (RNBRemote *remote) while (mode == eRNBRunLoopModePlatformMode) { std::string set_events_str; -const uint32_t event_mask = RNBContext::event_read_packet_available | +const uint32_t event_mask = RNBContext::event_read_packet_available | RNBContext::event_read_thread_exiting; - + DNBLogThreadedIf (LOG_RNB_EVENTS, "%s ctx.Events().WaitForSetEvents(0x%08x) ...",__FUNCTION__, event_mask); nub_event_t set_events = ctx.Events().WaitForSetEvents(event_mask); DNBLogThreadedIf (LOG_RNB_EVENTS, "%s ctx.Events().WaitForSetEvents(0x%08x) => 0x%08x (%s)",__FUNCTION__, event_mask, set_events, ctx.EventsAsString(set_events, set_events_str)); - + if (set_events) { if (set_events & RNBContext::event_read_packet_available) @@ -651,14 +650,14 @@ RNBRunLoopPlatform (RNBRemote *remote) if (remote->HandleReceivedPacket() == rnb_not_connected) mode = eRNBRunLoopModeExit; } - + if (set_events & RNBContext::event_read_thread_exiting) { mode = eRNBRunLoopModeExit; } ctx.Events().ResetEvents(set_events); } -} +} return eRNBRunLoopModeExit; } @@ -671,9 +670,9 @@ static void PortWasBoundCallbackUnixSocket (const void *baton, in_port_t port) { //::printf ("PortWasBoundCallbackUnixSocket (baton = %p, port = %u)\n", baton, port); - + const char *unix_socket_name = (const char *)baton; - + if (unix_socket_name && unix_socket_name[0]) { // We were given a unix socket name to use to communicate the port @@ -685,37 +684,37 @@ PortWasBoundCallbackUnixSocket (const vo perror("error: socket (AF_UNIX, SOCK_STREAM, 0)"); exit(1); } - + saddr_un.sun_family = AF_UNIX; ::strncpy(saddr_un.sun_path, unix_socket_name, sizeof(saddr_un.sun_path) - 1); saddr_un.sun_path[sizeof(saddr_un.sun_path) - 1] = '\0'; saddr_un.sun_len = SUN_LEN (&saddr_un); - + if (::connect (s, (struct sockaddr *)&saddr_un, static_cast(SUN_LEN (&saddr_un))) < 0) { perror("error: connect (socket, &saddr_un, saddr_un_len)"); exit(1); } - + //::printf ("connect () sucess!!\n"); - - + + // We were able to connect to the socket, now write our PID so whomever // launched us will know this process's ID RNBLogSTDOUT ("Listening to port %i...\n", port); - + char pid_str[64]; const int pid_str_len = ::snprintf (pid_str, sizeof(pid_str), "%u", port); const ssize_t bytes_sent = ::send (s, pid_str, pid_str_len, 0); - + if (pid_str_len != bytes_sent) { perror("error: send (s, pid_str, pid_str_len, 0)"); exit (1); } - + //::printf ("send () sucess!!\n"); - + // We are done with the socket close (s); } @@ -893,7 +892,7 @@ main (int argc, char *argv[]) #if defined (__arm__) || defined (__arm64__) || defined (__aarch64__) struct sched_param thread_param; int thread_sched_policy; -if (pthread_getschedparam(pthread_self(), &thread_sched_policy, &thread_param) == 0) +if (pthread_getschedparam(pthread_self(), &thread_sched_policy, &thread_param) == 0) { thread_param.sched_priority = 47; pthread_setschedparam(pthread_self(), thread_sched_policy, &thread_param); @@ -915,25 +914,25 @@ main (int argc, char *argv[]) //signal (SIGINT, signal_handler); signal (SIGPIPE, signal_handler); signal (SIGHUP, signal_han
Re: [Lldb-commits] [PATCH] D13819: LLDBStandalone: Report nice errors on missing vars
artagnon added a comment. Okay, so run this on the current HEAD: $ cmake -GNinja -DCMAKE_BUILD_TYPE=Debug ../lldb -- The C compiler identification is AppleClang 6.1.0.6020053 -- The CXX compiler identification is AppleClang 6.1.0.6020053 -- Check for working C compiler using: Ninja -- Check for working C compiler using: Ninja -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Detecting C compile features -- Detecting C compile features - done -- Check for working CXX compiler using: Ninja -- Check for working CXX compiler using: Ninja -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Detecting CXX compile features -- Detecting CXX compile features - done CMake Error at cmake/modules/LLDBStandalone.cmake:37 (get_filename_component): get_filename_component called with incorrect number of arguments Call Stack (most recent call first): CMakeLists.txt:3 (include) CMake Error at cmake/modules/LLDBStandalone.cmake:40 (get_filename_component): get_filename_component called with incorrect number of arguments Call Stack (most recent call first): CMakeLists.txt:3 (include) CMake Error at cmake/modules/LLDBStandalone.cmake:48 (include): include could not find load file: AddLLVM Call Stack (most recent call first): CMakeLists.txt:3 (include) CMake Error at cmake/modules/LLDBStandalone.cmake:49 (include): include could not find load file: HandleLLVMOptions Call Stack (most recent call first): CMakeLists.txt:3 (include) -- Found PythonInterp: CMake Error at cmake/modules/LLDBStandalone.cmake:63 (include): include could not find load file: /share/llvm/cmake/LLVMConfig.cmake Call Stack (most recent call first): CMakeLists.txt:3 (include) -- Found PythonLibs: /usr/lib/libpython2.7.dylib (found version "2.7.10") CMake Error at cmake/modules/LLDBConfig.cmake:205 (check_cxx_compiler_flag): Unknown CMake command "check_cxx_compiler_flag". Call Stack (most recent call first): CMakeLists.txt:4 (include) -- Configuring incomplete, errors occurred! See also "/home/rramacha/src/lldb-build2/CMakeFiles/CMakeOutput.log". Cryptic syntax errors right? Now apply the patch and run: $ cmake -GNinja -DCMAKE_BUILD_TYPE=Debug ../lldb -- The C compiler identification is AppleClang 6.1.0.6020053 -- The CXX compiler identification is AppleClang 6.1.0.6020053 -- Check for working C compiler using: Ninja -- Check for working C compiler using: Ninja -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Detecting C compile features -- Detecting C compile features - done -- Check for working CXX compiler using: Ninja -- Check for working CXX compiler using: Ninja -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Detecting CXX compile features -- Detecting CXX compile features - done CMake Error at cmake/modules/LLDBStandalone.cmake:43 (message): Please set LLDB_PATH_TO_LLVM_BUILD to the root directory of LLVM build or install site. Call Stack (most recent call first): CMakeLists.txt:3 (include) -- Configuring incomplete, errors occurred! See also "/home/rramacha/src/lldb-build2/CMakeFiles/CMakeOutput.log". Great. To fix that, run: $ cmake -GNinja -DCMAKE_BUILD_TYPE=Debug -DLLDB_PATH_TO_LLVM_BUILD=~/src/llvm-build ../lldb -- The C compiler identification is AppleClang 6.1.0.6020053 -- The CXX compiler identification is AppleClang 6.1.0.6020053 -- Check for working C compiler using: Ninja -- Check for working C compiler using: Ninja -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Detecting C compile features -- Detecting C compile features - done -- Check for working CXX compiler using: Ninja -- Check for working CXX compiler using: Ninja -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Detecting CXX compile features -- Detecting CXX compile features - done CMake Error at cmake/modules/LLDBStandalone.cmake:51 (message): Please set LLDB_PATH_TO_CLANG_BUILD to the root directory of Clang build or install site. Call Stack (most recent call first): CMakeLists.txt:3 (include) -- Configuring incomplete, errors occurred! See also "/home/rramacha/src/lldb-build2/CMakeFiles/CMakeOutput.log". To build successfully, you need to (with or without the patch): $ cmake -GNinja -DCMAKE_BUILD_TYPE=Debug -DLLDB_PATH_TO_LLVM_SOURCE=~/src/llvm -DLLDB_PATH_TO_LLVM_BUILD=~/src/llvm-build -DLLDB_PATH_TO_CLANG_SOURCE=~/src/clang -DLLDB_PATH_TO_CLANG_BUILD=~/src/clang-build ../lldb The patch doesn't solve all issues: for instance, what happens when LLDB_PATH_TO_{LLVM,CLANG}_SOURCE isn't suitable? Why can't I query llvm-config and get all these paths? (and hopefully
[Lldb-commits] [lldb] r252624 - LLDBStandalone: Report nice errors on missing vars
Author: artagnon Date: Tue Nov 10 12:09:14 2015 New Revision: 252624 URL: http://llvm.org/viewvc/llvm-project?rev=252624&view=rev Log: LLDBStandalone: Report nice errors on missing vars Differential Revision: http://reviews.llvm.org/D13819 Modified: lldb/trunk/cmake/modules/LLDBStandalone.cmake Modified: lldb/trunk/cmake/modules/LLDBStandalone.cmake URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/cmake/modules/LLDBStandalone.cmake?rev=252624&r1=252623&r2=252624&view=diff == --- lldb/trunk/cmake/modules/LLDBStandalone.cmake (original) +++ lldb/trunk/cmake/modules/LLDBStandalone.cmake Tue Nov 10 12:09:14 2015 @@ -23,6 +23,7 @@ if (CMAKE_SOURCE_DIR STREQUAL CMAKE_CURR else() get_filename_component(LLVM_MAIN_SRC_DIR ${LLDB_PATH_TO_LLVM_SOURCE} ABSOLUTE) + set(LLVM_MAIN_INCLUDE_DIR "${LLVM_MAIN_SRC_DIR}/include") list(APPEND CMAKE_MODULE_PATH "${LLVM_MAIN_SRC_DIR}/cmake/modules") endif() endif() @@ -30,15 +31,27 @@ if (CMAKE_SOURCE_DIR STREQUAL CMAKE_CURR if (LLDB_PATH_TO_CLANG_SOURCE) get_filename_component(CLANG_MAIN_SRC_DIR ${LLDB_PATH_TO_CLANG_SOURCE} ABSOLUTE) + set(CLANG_MAIN_INCLUDE_DIR "${CLANG_MAIN_SRC_DIR}/include") endif() list(APPEND CMAKE_MODULE_PATH "${LLDB_PATH_TO_LLVM_BUILD}/share/llvm/cmake") - get_filename_component(PATH_TO_LLVM_BUILD ${LLDB_PATH_TO_LLVM_BUILD} - ABSOLUTE) + if (LLDB_PATH_TO_LLVM_BUILD) +get_filename_component(PATH_TO_LLVM_BUILD ${LLDB_PATH_TO_LLVM_BUILD} + ABSOLUTE) + else() +message(FATAL_ERROR "Please set LLDB_PATH_TO_LLVM_BUILD to the root " +"directory of LLVM build or install site.") + endif() + + if (LLDB_PATH_TO_CLANG_BUILD) +get_filename_component(PATH_TO_CLANG_BUILD ${LLDB_PATH_TO_CLANG_BUILD} + ABSOLUTE) + else() +message(FATAL_ERROR "Please set LLDB_PATH_TO_CLANG_BUILD to the root " +"directory of Clang build or install site.") + endif() - get_filename_component(PATH_TO_CLANG_BUILD ${LLDB_PATH_TO_CLANG_BUILD} - ABSOLUTE) # These variables are used by add_llvm_library. set(LLVM_RUNTIME_OUTPUT_INTDIR ${CMAKE_BINARY_DIR}/${CMAKE_CFG_INTDIR}/bin) @@ -67,11 +80,8 @@ if (CMAKE_SOURCE_DIR STREQUAL CMAKE_CURR set(PACKAGE_VERSION "${LLVM_PACKAGE_VERSION}") - set(LLVM_MAIN_INCLUDE_DIR "${LLVM_MAIN_SRC_DIR}/include") set(LLVM_BINARY_DIR ${CMAKE_BINARY_DIR}) - set(CLANG_MAIN_INCLUDE_DIR "${CLANG_MAIN_SRC_DIR}/include") - set(CMAKE_INCLUDE_CURRENT_DIR ON) include_directories("${PATH_TO_LLVM_BUILD}/include" "${LLVM_MAIN_INCLUDE_DIR}" ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
Re: [Lldb-commits] [PATCH] D13819: LLDBStandalone: Report nice errors on missing vars
This revision was automatically updated to reflect the committed changes. Closed by commit rL252624: LLDBStandalone: Report nice errors on missing vars (authored by artagnon). Changed prior to commit: http://reviews.llvm.org/D13819?vs=37616&id=39822#toc Repository: rL LLVM http://reviews.llvm.org/D13819 Files: lldb/trunk/cmake/modules/LLDBStandalone.cmake Index: lldb/trunk/cmake/modules/LLDBStandalone.cmake === --- lldb/trunk/cmake/modules/LLDBStandalone.cmake +++ lldb/trunk/cmake/modules/LLDBStandalone.cmake @@ -23,22 +23,35 @@ else() get_filename_component(LLVM_MAIN_SRC_DIR ${LLDB_PATH_TO_LLVM_SOURCE} ABSOLUTE) + set(LLVM_MAIN_INCLUDE_DIR "${LLVM_MAIN_SRC_DIR}/include") list(APPEND CMAKE_MODULE_PATH "${LLVM_MAIN_SRC_DIR}/cmake/modules") endif() endif() if (LLDB_PATH_TO_CLANG_SOURCE) get_filename_component(CLANG_MAIN_SRC_DIR ${LLDB_PATH_TO_CLANG_SOURCE} ABSOLUTE) + set(CLANG_MAIN_INCLUDE_DIR "${CLANG_MAIN_SRC_DIR}/include") endif() list(APPEND CMAKE_MODULE_PATH "${LLDB_PATH_TO_LLVM_BUILD}/share/llvm/cmake") - get_filename_component(PATH_TO_LLVM_BUILD ${LLDB_PATH_TO_LLVM_BUILD} - ABSOLUTE) + if (LLDB_PATH_TO_LLVM_BUILD) +get_filename_component(PATH_TO_LLVM_BUILD ${LLDB_PATH_TO_LLVM_BUILD} + ABSOLUTE) + else() +message(FATAL_ERROR "Please set LLDB_PATH_TO_LLVM_BUILD to the root " +"directory of LLVM build or install site.") + endif() + + if (LLDB_PATH_TO_CLANG_BUILD) +get_filename_component(PATH_TO_CLANG_BUILD ${LLDB_PATH_TO_CLANG_BUILD} + ABSOLUTE) + else() +message(FATAL_ERROR "Please set LLDB_PATH_TO_CLANG_BUILD to the root " +"directory of Clang build or install site.") + endif() - get_filename_component(PATH_TO_CLANG_BUILD ${LLDB_PATH_TO_CLANG_BUILD} - ABSOLUTE) # These variables are used by add_llvm_library. set(LLVM_RUNTIME_OUTPUT_INTDIR ${CMAKE_BINARY_DIR}/${CMAKE_CFG_INTDIR}/bin) @@ -67,11 +80,8 @@ set(PACKAGE_VERSION "${LLVM_PACKAGE_VERSION}") - set(LLVM_MAIN_INCLUDE_DIR "${LLVM_MAIN_SRC_DIR}/include") set(LLVM_BINARY_DIR ${CMAKE_BINARY_DIR}) - set(CLANG_MAIN_INCLUDE_DIR "${CLANG_MAIN_SRC_DIR}/include") - set(CMAKE_INCLUDE_CURRENT_DIR ON) include_directories("${PATH_TO_LLVM_BUILD}/include" "${LLVM_MAIN_INCLUDE_DIR}" Index: lldb/trunk/cmake/modules/LLDBStandalone.cmake === --- lldb/trunk/cmake/modules/LLDBStandalone.cmake +++ lldb/trunk/cmake/modules/LLDBStandalone.cmake @@ -23,22 +23,35 @@ else() get_filename_component(LLVM_MAIN_SRC_DIR ${LLDB_PATH_TO_LLVM_SOURCE} ABSOLUTE) + set(LLVM_MAIN_INCLUDE_DIR "${LLVM_MAIN_SRC_DIR}/include") list(APPEND CMAKE_MODULE_PATH "${LLVM_MAIN_SRC_DIR}/cmake/modules") endif() endif() if (LLDB_PATH_TO_CLANG_SOURCE) get_filename_component(CLANG_MAIN_SRC_DIR ${LLDB_PATH_TO_CLANG_SOURCE} ABSOLUTE) + set(CLANG_MAIN_INCLUDE_DIR "${CLANG_MAIN_SRC_DIR}/include") endif() list(APPEND CMAKE_MODULE_PATH "${LLDB_PATH_TO_LLVM_BUILD}/share/llvm/cmake") - get_filename_component(PATH_TO_LLVM_BUILD ${LLDB_PATH_TO_LLVM_BUILD} - ABSOLUTE) + if (LLDB_PATH_TO_LLVM_BUILD) +get_filename_component(PATH_TO_LLVM_BUILD ${LLDB_PATH_TO_LLVM_BUILD} + ABSOLUTE) + else() +message(FATAL_ERROR "Please set LLDB_PATH_TO_LLVM_BUILD to the root " +"directory of LLVM build or install site.") + endif() + + if (LLDB_PATH_TO_CLANG_BUILD) +get_filename_component(PATH_TO_CLANG_BUILD ${LLDB_PATH_TO_CLANG_BUILD} + ABSOLUTE) + else() +message(FATAL_ERROR "Please set LLDB_PATH_TO_CLANG_BUILD to the root " +"directory of Clang build or install site.") + endif() - get_filename_component(PATH_TO_CLANG_BUILD ${LLDB_PATH_TO_CLANG_BUILD} - ABSOLUTE) # These variables are used by add_llvm_library. set(LLVM_RUNTIME_OUTPUT_INTDIR ${CMAKE_BINARY_DIR}/${CMAKE_CFG_INTDIR}/bin) @@ -67,11 +80,8 @@ set(PACKAGE_VERSION "${LLVM_PACKAGE_VERSION}") - set(LLVM_MAIN_INCLUDE_DIR "${LLVM_MAIN_SRC_DIR}/include") set(LLVM_BINARY_DIR ${CMAKE_BINARY_DIR}) - set(CLANG_MAIN_INCLUDE_DIR "${CLANG_MAIN_SRC_DIR}/include") - set(CMAKE_INCLUDE_CURRENT_DIR ON) include_directories("${PATH_TO_LLVM_BUILD}/include" "${LLVM_MAIN_INCLUDE_DIR}" ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
[Lldb-commits] [PATCH] D14549: Use uniqueness of C++ fully-qualified names to resolve conflicts
artagnon created this revision. artagnon added reviewers: clayborg, tfiala. artagnon added a subscriber: lldb-commits. A very expected layout: source tree is in ~/src/llvm, the build directory is in ~/src/llvm-build, and the install location is in /usr/local/{lib,include}. The DWARF information in /usr/local/lib/libLLVM.a for ilist.h points to ~/src/llvm-build/include/llvm/ADT/ilist.h. Now, when someone includes "llvm/ADT/ilist.h" and links against /usr/local/lib/libLLVM.a. Disaster. The DWARF information in libUser.so for ilist.h points to two locations: the one in /usr/include, and the one in ~/src/llvm-build/include. LLDB gets confused. Let's uniquify fully-qualified names and never trip on such a thing. Patch-by: Greg Clayton http://reviews.llvm.org/D14549 Files: source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp Index: source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp === --- source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp +++ source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp @@ -457,24 +457,44 @@ // and clang isn't good and sharing the stack space for variables in different blocks. std::unique_ptr unique_ast_entry_ap(new UniqueDWARFASTType()); -// Only try and unique the type if it has a name. -if (type_name_const_str && -dwarf->GetUniqueDWARFASTTypeMap().Find (type_name_const_str, -die, -decl, -byte_size_valid ? byte_size : -1, -*unique_ast_entry_ap)) +if (type_name_const_str) { -// We have already parsed this type or from another -// compile unit. GCC loves to use the "one definition -// rule" which can result in multiple definitions -// of the same class over and over in each compile -// unit. -type_sp = unique_ast_entry_ap->m_type_sp; -if (type_sp) +LanguageType die_language = die.GetLanguage(); +bool handled = false; +if (Language::LanguageIsCPlusPlus(die_language)) { +std::string qualified_name; +if (die.GetQualifiedName(qualified_name)) +{ +handled = true; +ConstString const_qualified_name(qualified_name); +if (dwarf->GetUniqueDWARFASTTypeMap().Find(const_qualified_name, die, Declaration(), + byte_size_valid ? byte_size : -1, + *unique_ast_entry_ap)) +{ +type_sp = unique_ast_entry_ap->m_type_sp; +if (type_sp) +{ +dwarf->GetDIEToType()[die.GetDIE()] = type_sp.get(); +return type_sp; +} +} +} +} + +if (!handled) +{ +if (dwarf->GetUniqueDWARFASTTypeMap().Find(type_name_const_str, die, decl, + byte_size_valid ? byte_size : -1, + *unique_ast_entry_ap)) +{ +type_sp = unique_ast_entry_ap->m_type_sp; +if (type_sp) +{ dwarf->GetDIEToType()[die.GetDIE()] = type_sp.get(); return type_sp; +} +} } } @@ -1251,13 +1271,13 @@ class_type->GetName().GetCString(), die.GetID(), dwarf->GetObjectFile()->GetFileSpec().GetPath().c_str()); - + const bool is_attr_used = false;
[Lldb-commits] [lldb] r252898 - Use uniqueness of C++ fully-qualified names to resolve conflicts
Author: artagnon Date: Thu Nov 12 08:44:24 2015 New Revision: 252898 URL: http://llvm.org/viewvc/llvm-project?rev=252898&view=rev Log: Use uniqueness of C++ fully-qualified names to resolve conflicts A very expected layout: source tree is in ~/src/llvm, the build directory is in ~/src/llvm-build, and the install location is in /usr/local/{lib,include}. The DWARF information in /usr/local/lib/libLLVM.a for ilist.h points to ~/src/llvm-build/include/llvm/ADT/ilist.h. Now, when someone includes "llvm/ADT/ilist.h" and links against /usr/local/lib/libLLVM.a. Disaster. The DWARF information in libUser.so for ilist.h points to two locations: the one in /usr/include, and the one in ~/src/llvm-build/include. LLDB gets confused. Let's uniquify fully-qualified names and never trip on such a thing. Differential Revision: http://reviews.llvm.org/D14549 Modified: lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp Modified: lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp?rev=252898&r1=252897&r2=252898&view=diff == --- lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp (original) +++ lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp Thu Nov 12 08:44:24 2015 @@ -457,24 +457,44 @@ DWARFASTParserClang::ParseTypeFromDWARF // and clang isn't good and sharing the stack space for variables in different blocks. std::unique_ptr unique_ast_entry_ap(new UniqueDWARFASTType()); -// Only try and unique the type if it has a name. -if (type_name_const_str && -dwarf->GetUniqueDWARFASTTypeMap().Find (type_name_const_str, -die, -decl, - byte_size_valid ? byte_size : -1, - *unique_ast_entry_ap)) +if (type_name_const_str) { -// We have already parsed this type or from another -// compile unit. GCC loves to use the "one definition -// rule" which can result in multiple definitions -// of the same class over and over in each compile -// unit. -type_sp = unique_ast_entry_ap->m_type_sp; -if (type_sp) +LanguageType die_language = die.GetLanguage(); +bool handled = false; +if (Language::LanguageIsCPlusPlus(die_language)) +{ +std::string qualified_name; +if (die.GetQualifiedName(qualified_name)) +{ +handled = true; +ConstString const_qualified_name(qualified_name); +if (dwarf->GetUniqueDWARFASTTypeMap().Find(const_qualified_name, die, Declaration(), + byte_size_valid ? byte_size : -1, + *unique_ast_entry_ap)) +{ +type_sp = unique_ast_entry_ap->m_type_sp; +if (type_sp) +{ +dwarf->GetDIEToType()[die.GetDIE()] = type_sp.get(); +return type_sp; +} +} +} +} + +if (!handled) +{ +if (dwarf->GetUniqueDWARFASTTypeMap().Find(type_name_const_str, die, decl, + byte_size_valid ? byte_size : -1, + *unique_ast_entry_ap)) { +type_sp = unique_ast_entry_ap->m_type_sp; +if (type_sp) +{ dwarf->GetDIEToType()[die.GetDIE()] = type_sp.get(); return type_sp; +} +} } } @@ -1251,13 +1271,13 @@ DWARFASTParserClang::ParseTypeFromDWARF
Re: [Lldb-commits] [PATCH] D14549: Use uniqueness of C++ fully-qualified names to resolve conflicts
This revision was automatically updated to reflect the committed changes. Closed by commit rL252898: Use uniqueness of C++ fully-qualified names to resolve conflicts (authored by artagnon). Changed prior to commit: http://reviews.llvm.org/D14549?vs=39841&id=40044#toc Repository: rL LLVM http://reviews.llvm.org/D14549 Files: lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp Index: lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp === --- lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp +++ lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp @@ -457,24 +457,44 @@ // and clang isn't good and sharing the stack space for variables in different blocks. std::unique_ptr unique_ast_entry_ap(new UniqueDWARFASTType()); -// Only try and unique the type if it has a name. -if (type_name_const_str && -dwarf->GetUniqueDWARFASTTypeMap().Find (type_name_const_str, -die, -decl, -byte_size_valid ? byte_size : -1, -*unique_ast_entry_ap)) +if (type_name_const_str) { -// We have already parsed this type or from another -// compile unit. GCC loves to use the "one definition -// rule" which can result in multiple definitions -// of the same class over and over in each compile -// unit. -type_sp = unique_ast_entry_ap->m_type_sp; -if (type_sp) +LanguageType die_language = die.GetLanguage(); +bool handled = false; +if (Language::LanguageIsCPlusPlus(die_language)) +{ +std::string qualified_name; +if (die.GetQualifiedName(qualified_name)) +{ +handled = true; +ConstString const_qualified_name(qualified_name); +if (dwarf->GetUniqueDWARFASTTypeMap().Find(const_qualified_name, die, Declaration(), + byte_size_valid ? byte_size : -1, + *unique_ast_entry_ap)) +{ +type_sp = unique_ast_entry_ap->m_type_sp; +if (type_sp) +{ +dwarf->GetDIEToType()[die.GetDIE()] = type_sp.get(); +return type_sp; +} +} +} +} + +if (!handled) +{ +if (dwarf->GetUniqueDWARFASTTypeMap().Find(type_name_const_str, die, decl, + byte_size_valid ? byte_size : -1, + *unique_ast_entry_ap)) { +type_sp = unique_ast_entry_ap->m_type_sp; +if (type_sp) +{ dwarf->GetDIEToType()[die.GetDIE()] = type_sp.get(); return type_sp; +} +} } } @@ -1251,13 +1271,13 @@ class_type->GetName().GetCString(), die.GetID(), dwarf->GetObjectFile()->GetFileSpec().GetPath().c_str()); - + const bool is_attr_used = false; // Neither GCC 4.2 nor clang++ currently set a valid accessibility // in the DWARF for C++ methods... Default to public for now... if (accessibility == eAccessNone) accessibility = eAccessPublic; -