summaryrefslogtreecommitdiff
path: root/src/debug/di
AgeCommit message (Collapse)AuthorFilesLines
2020-10-30Fix step with stackalloc (#27246) (#27351)submit/tizen_5.5_mobile_hotfix/20201030.060307accepted/tizen/5.5/unified/mobile/hotfix/20201103.003335accepted/tizen_5.5_unified_mobile_hotfixSteve MacLean3-2/+4
* Make ControllerStackInfo::m_returnFrame private * Make ControllerStackInfo always capture a return frame In case the active frame has no managed caller, capture the unmanaged frame * Fix step over stackalloc Generalize handling of stack allocations and stepping * Fix GetFunctionFromToken() argument checking Check token type is a method before creating a CordbFunction. Add extra assert to check for invalid tokens
2020-10-30Fix PIE options (#26323)Jan Vorlicek1-1/+0
* Fix PIE options We were missing passing the -pie linker option. That means that while we were compiling our code as position independent, the executables (not shared libraries) were not marked as position independent and ASLR was not applied to them. They were always loaded to fixed addresses. This change adds the missing -pie option and also replaces all the individual settings of -fPIE / -fPIC on the targets we build by a centralized setting of CMAKE_POSITION_INDEPENDENT_CODE variable that causes cmake to add the appropriate compiler options everywhere. * Fix native parts of coreclr tests build The native parts of the tests are not built using the root CMakeLists.txt so I am moving enabling the position independent code to configurecompiler.cmake Change-Id: Ieafff8984ec23e5fdb00fb0c2fb017e53afbce88
2019-07-16Add missing Arm64 specific diagnostic code (#25695)Steve MacLean2-10/+136
* Arm64 ICorDebugRegisterSet float support * Arm64 ICorDebugRegisterSet2 implementation * Add arm64 VLT_REG_FP case * Arm64 add funceval GetRegister SetRegister support
2019-07-08Add arm64 floatconversion.S (#25597)Steve MacLean2-1/+15
* Add arm64 floatconversion.S * Update comment
2019-06-26Delegate inspection API in the DBI (#25362)Juan Hoyos2-8/+203
* Add ICorDebugDelegateObjectValue interfaces * Expose appropriate HR (CORDBG_E_UNSUPPORTED_DELEGATE) * Partially DACize DelegateObject * Add DacDbi method for delegate inspection
2019-06-21ifdef Linux specific readvirtual code (#25299)Mike McLaughlin1-0/+8
2019-06-11Delete dead code (#25066)Jan Kotas1-1/+0
2019-06-04signedness (#24878)Sinan Kaya1-1/+1
2019-05-29Use /proc/<pid>/mem to read memory in remote DBI data target. It makes the ↵Mike McLaughlin1-8/+27
test case run at (#24844) least 4 to 5 times faster than before. Fallback to old transport ReadMemory if /proc/<pid>/mem can't be opened. This happens on attach because of permissions/access, but works fine on the launch (the most important case).
2019-05-22Delete FEATURE_WINDOWSPHONE (#24718)Jan Kotas2-33/+0
2019-05-10Move EventProvider native layout to be driven by CMake configure (#24478)Jeremy Koritzinsky1-0/+1
* Generate eventpipe implementation as part of CMake configure. * Generate Etw provider as part of CMake configure. * First pass porting over lttng provider to cmake. * Fix up CMake Lttng provider generation. * Move Lttng provider into CMake tree. * Move dummy event provider to CMake * Move genEventing into the CMake tree. * Remove extraneous logging and unused python locator. * Clean up build.sh * Clean up genEventingTests.py * Add dependencies to enable more incremental builds (providers not fully incremental). * Convert to custom command and targets instead of at configure time. * Get each eventing target to incrementally build. * Fix incremental builds * Add missing dependencies on eventing headers. * PR Feedback. Mark all generated files as generated * Clean up eventprovider test CMakeLists
2019-05-01Adjust some terms (#24351)Dan Moseley1-3/+3
2019-04-16Use delete [] on array types (#24027)Omair Majid1-1/+1
Calling delete on types allocated with new[] leads to undefined behaviour.
2019-04-15Use NewArrayHolder for array types in src/debug (#24013)Omair Majid2-2/+2
Using a NewHolder with array types means that when the holder is ready to release the memory, it ends up invoking `delete` (instead of `delete[]`) on that array. This is an undefined behaviour. Use NewArrayHolder isntead to fix this.
2019-03-11Merge pull request #23093 from franksinankaya/gcc_warnings_9Jan Vorlicek3-5/+5
GCC Signed compare and Narrowing warnings
2019-03-07Fix signed compare warningsSinan Kaya3-5/+5
warning: comparison between signed and unsigned integer expressions [-Wsign-compare] conversions Update src/ToolBox/superpmi/mcs/verbdumptoc.cpp Co-Authored-By: franksinankaya <41809318+franksinankaya@users.noreply.github.com>
2019-03-07Fix control C trap hang in the debugger (#23090)Juan Hoyos3-28/+33
2019-03-03Cleanup more GCC warnings (#22872)Sinan Kaya1-2/+2
* Add parenthesis src/vm/sha1.cpp: In function ‘void SHA1_block(SHA1_CTX*)’: src/vm/sha1.cpp:93:29: warning: suggest parentheses around arithmetic in operand of ‘|’ [-Wparentheses] #define ROUND3(B, C, D) ((C & (B | D) | (B & D)) + sha1_round3) ^ src/vm/sha1.cpp:139:32: note: in expansion of macro ‘ROUND3’ e += ROTATE32L(a, 5) + ROUND3(b, c, d) + msg80[i]; * Move declaration into same file as one was defined Extern the other one was static * Remove hr=hr undefined assignment * Fix mutli-line comment warning * Convert multi-character literal * Remove null check for stack local variables rc/vm/invokeutil.cpp: In static member function ‘static void InvokeUtil::SetValidField(CorElementType, TypeHandle, FieldDesc*, OBJECTREF*, OBJECTREF*, TypeHandle, CLR_BOOL*)’: src/vm/invokeutil.cpp:978:29: warning: the address of ‘Throwable’ will never be NULL [-Waddress] EX_CATCH_THROWABLE(&Throwable); ^ src/inc/ex.h:1087:21: note: in definition of macro ‘EX_CATCH_THROWABLE’ if (NULL != ppThrowable) ^
2019-02-26GCC compatibility fixes #7 (#22810)Sinan Kaya1-3/+3
* Use thread_local for thread local storage on non MSVC targets * Use local copy of visitor rather than function parameter * Remove extra class qualifier * Replace hex number representation in ASM files * Reorder STDAPI and DLLEXPORT * Suppress conversion Suppress warning during hash add casting * Remove anonymous struct src/vm/codeversion.h:112:16: warning: ‘struct NativeCodeVersion::<anonymous union>::SyntheticStorage’ invalid; an anonymous union can only have non-static data members [-fpermissive] struct SyntheticStorage * Remove class declaration Remove extra class declaration * Remove extern C * Add implicit paranthesis src/vm/amd64/virtualcallstubcpu.hpp:735:103: warning: suggest parentheses around ‘-’ in operand of ‘&’ [-Wparentheses] resolveInit.toMiss1 = offsetof(ResolveStub,miss)-(offsetof(ResolveStub,toMiss1)+1) & 0xFF; ^ src/vm/amd64/virtualcallstubcpu.hpp:741:103: warning: suggest parentheses around ‘-’ in operand of ‘&’ [-Wparentheses] resolveInit.toMiss2 = offsetof(ResolveStub,miss)-(offsetof(ResolveStub,toMiss2)+1) & 0xFF; Add parenthesis src/vm/dataimage.cpp:631:55: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] previousRvaInfo->rva == rvaInfo->rva && previousRvaInfo->size >= rvaInfo->size Add parenthesis src/debug/daccess/daccess.cpp:6871:29: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] _ASSERTE(peFile == NULL && reflectionModule != NULL || peFile != NULL && reflectionModule == NULL); Add parenthesis src/vm/dataimage.cpp:631:57: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] (previousRvaInfo->rva == rvaInfo->rva) && (previousRvaInfo->size >= rvaInfo->size) * Initialize member 1 src/ilasm/method.cpp:35:36: warning: operation on ‘((Method*)this)->Method::m_ulColumns[0]’ may be undefined [-Wsequence-point] m_ulColumns[0]=m_ulColumns[0]=0; * Remove unknown compiler option * Abstract DLLEXPORT
2019-02-09Set visibility option to hidden (#21924)Adeel Mujahid2-8/+8
2019-01-08Fixed potential memory leak (#21872)Oded Hanson1-0/+1
2018-12-12Added support for debugging a sandboxed app on Mac (#21068)Oded Hanson19-95/+176
* Fixed bug in StackString where the size is not initialized correctly to STACK_COUNT * Added CharString and WCharString template classes and a generic CharStringFromLPCWSTR method * Added support for debugging a sandboxed app on Mac This change fixes the usage of IPC while debugging while running in a sandbox. When running in a sandbox, the temporary folder for each process will be different. Thus the pipes being created in TwoWayPipe right now would be created in different directories in the debugger process and the process being debugged. This change configures the folder to be used based on the application group ID that the sandboxed app belongs to. For the same reasons, the names sempahores being used to synchronize the debugger attach need to be prefixed with the application group ID. This change was abit more involved since the name of the semaphore is limited to 31 characters, so we had to encode the semaphore names differently to make them shorter. Last, new APIs to the debugger shim were added to support this new feature. This change only handles the runtime side and the dbgshim. An additional change to vsdbg needs to be done to use the new APIs. fixes #21066 * Fixed build breaks on non Mac Unix platforms * Fixed usage of gApplicationGroupId in non apple environments * Fixed bug in semaphore names * Got rid of usage of StackString * Made PAL_GetApplicationGroupId Apple specific * Added comment about pragma pack * Fixed comment * Added exported symbols * Duplicated applicationGroupId so it can be used from another thread during register complete callback * Renamed BitNum2ByteNum to GetExtraEncodedAreaSize to make intent clearer * Fixed nit comments * Removed redundant changes in StackString * Fixed windows build break * Fixed compilation switch from __APPLE to __APPLE__ * Added missing exports
2018-11-26Fix a use after free for Managed Data BP (#21205)Chuck Ries1-4/+6
ShimProxyCallback::DataBreakpoint::DataBreakpointEvent was holding onto a bare BYTE* for the CONTEXT rather than copying the buffer and taking ownership. Due to lifetime, this resulted in a use after free. Apparently in retail code we got lucky and this worked enough of the time that we never noticed it.
2018-11-23Fix debugger collectible thread statics access (#21175)Jan Vorlicek1-13/+16
The CordbClass::GetStaticFieldValue2 was missing support for accessing thread statics in collectible classes. Fortunately the fix was simple, we can use the same code path as for non-collectible thread statics.
2018-11-12Passing the CONTEXT in ICorDebugManagedCallback4::DataBreakpoint (#20960)Andrew Au4-9/+14
* Passing the CONTEXT in ICorDebugManagedCallback4::DataBreakpoint * ifdef out the message sending on configurations that does not support data breakpoint
2018-11-08Revert "Passing the CONTEXT in ICorDebugManagedCallback4::DataBreakpoint"Jan Kotas4-12/+8
This reverts commit 9dd2a3688320fa197a3a2a412523416f10e7fa3b.
2018-11-08Passing the CONTEXT in ICorDebugManagedCallback4::DataBreakpointAndrew Au4-8/+12
2018-11-06Pull out GetContainingObjectAndrew Au3-164/+5
2018-11-06More code review feedbackAndrew Au3-5/+12
2018-11-06GetContainingObject should be a method of ICorDebugValueAndrew Au3-58/+111
2018-11-06Change GetContainingObject APIAndrew Au3-7/+76
2018-11-06More code review feedbackAndrew Au1-1/+7
2018-11-06Code review feedbackAndrew Au1-1/+1
2018-11-06Use proper macros for GetContainingObject()Andrew Au1-4/+3
2018-11-06Fix a couple bugs in GetContainingObjectAndrew Au1-2/+14
2018-11-06Turn GarbageCollection events off by default and allow VS turning them onAndrew Au2-0/+6
2018-11-06Fix collision with ICorDebugProcess9 to 10Andrew Wang2-4/+4
2018-11-06Return better HR for failing to get managed thread contextAndrew Au1-6/+1
2018-11-06Do not handle the thread context for garbage collection eventsAndrew Au2-28/+6
2018-11-06Eliminate dataBreakpointMask from ICorDebugAndrew Au4-10/+8
2018-11-06Fixing linux buildAndrew Au1-0/+8
2018-11-06Get/Set the ThreadContext natively if the debuggee is block on garbage ↵Andrew Au2-6/+27
collection events
2018-11-06Hacking CordbProcess::GetThreadContext / SetThreadContext to retrieve/modify ↵Andrew Au1-54/+101
managed ThreadContext
2018-11-06Removing unnecessary hacksAndrew Au4-91/+13
2018-11-06ContainerObject -> ContainingObjectAndrew Au2-3/+3
2018-11-06Pass databreakpoint mask into debuggerTom McDonald4-10/+18
2018-11-06Implement ICorDebugManagedCallback4::DataBreakpointTom McDonald6-166/+48
2018-11-06ICorDebugValue -> ICorDebugObjectValue on GetContainerObject()Andrew Au2-10/+3
2018-11-06A dummy implementation of the GetContainerObject APIAndrew Au2-4/+30
2018-11-06Boilerplate for adding new DBI methodAndrew Au2-0/+17