Граф коммитов

388 Коммитов

Автор SHA1 Сообщение Дата
Juan Hoyos 9afb8ece50
Fix flushing of string builder for multi-parameter conditions (#625) 2019-11-19 09:47:59 -08:00
Mike McLaughlin 367aa5cd43
Fix bpmd on Windows and other changes (#622)
Fix bpmd on Windows by implementing IDataTarget2 which allows the DAC to allocate a JIT notification
table which is empty on Windows. Issue https://github.com/dotnet/diagnostics/issues/584.

Add SetRuntimeLoadedCallback lldb service for bpmd

Allow bpmd to work before coreclr is loaded. Issue https://github.com/dotnet/diagnostics/issues/15

Upgrade to symstore 1.0.55801

Set/reset symbol server path anytime .sympath changes

Add lldb h files to plugin project

Add bpmd tests. Update readme and help docs
2019-11-18 14:59:18 -08:00
Juan Hoyos b7a24c4019
Fix config parser and logging path to support (#620)
* Fix flaw in configuration parser error detection for negative clauses
* Logging paths can't have wildcards, but runtime specifiers can and this is used in our log names. In that case I resorted to use <Major.Minor.Patch> as the version for the log while preserving old behavior. That way xUnit still displays the full arg list for test disambiguation, but the logs only contain valid file names
2019-11-15 10:50:26 -08:00
Juan Hoyos 878f220fb8
Try using the test reporter to report tests (#615)
Use the AzDO pipeline reporter for xUnit style tests:

- This adds a per test report per run.
- Reports are now seen in the tests tab of a pipeline run as well as a tally in GitHub
2019-11-14 11:54:22 -08:00
Juan Hoyos 850fa77cf9
Add new function options to conditions in test runner (#611)
Adds the following options to the test helper condition attributes:

* Contains(string, string)
* StartsWith(string, string)
* EndsWith(string, string)

And adds argument validation that throws exception - to prevent any more tests to be skipped silently.
2019-11-14 11:40:42 -08:00
John Salem 2fc71674ef
Fix default PID value and add rollforward forgcdump (#614)
* Prevent default value for pid
add roll forward runtimeconfig to dotnet-gcdump

* Change default to 0 and modify error message

* Change error message
2019-11-14 10:57:27 -08:00
Juan Hoyos f43ad930d2
Wait for process exit independently of waiting for stream flushing (#612)
* Wait for process exit independently of waiting for stream flushing
Before, the ProcessRunner waited for the process completion as well as stream
buffer flushing for stdout and stderr. This is problematic if the process
it ran dies, but its spawned child processes keep the defunct's standard
streams alive by redirecting to them. We have had no way of harvesting
the children, so this process hung the runner.

After this change, we wait for the spawned process to die. As soon as that happens,
we give the pipes a grace period of 15 seconds to flush, after which we assume
the process is dead. This has the shortcoming of two potentially problematic
situations:
- We've potentially left an unobserved aggregate exception unobserved that will throw
on the finalizer thread once the tasks get collected in exceptional cases.
- This might leak threadpool threads.
2019-11-13 15:53:48 -08:00
Sung Yoon Whang a38b048e24
Draft Proposal for Diagnostics Client Library (a.k.a. "Runtime Client Library") (#574) 2019-11-13 15:05:28 -08:00
Sung Yoon Whang aa15cffb4b
Add counters tests to the diagnostics solution file to get it tested on automation (#609) 2019-11-12 15:34:45 -08:00
Denis Andrejew 40080dd548 fix typo in README.md (#608) 2019-11-09 02:21:19 -08:00
Sung Yoon Whang 7ab497e2f8
Fix formatting error in dotnet-counters doc (#604) 2019-11-08 14:36:46 -08:00
Mike McLaughlin 7d343eedf8
Revert "Update the docker images used to have a newer version of CMake. (#597)" (#598)
This reverts commit 0efe77744d.

Not ready for the new CentOS 7 image with lldb 9.0 and the cross build images fail because build-native.sh needs to use clang 9.0 and the alpine image fails just building managed code with:

##[error].packages/microsoft.build.tasks.git/1.0.0-beta2-19270-01/build/Microsoft.Build.Tasks.Git.targets(16,5): error : The type initializer for 'LibGit2Sharp.Core.NativeMethods' threw an exception.
   at LibGit2Sharp.Core.NativeMethods.git_buf_free(GitBuf buf)
   at LibGit2Sharp.Core.Proxy.git_buf_free(GitBuf buf)
   at LibGit2Sharp.Core.Handles.GitBuf.Dispose()
   at LibGit2Sharp.Core.Proxy.ConvertPath(Func`2 pathRetriever)
   at LibGit2Sharp.Core.Proxy.git_repository_discover(FilePath start_path)
   at LibGit2Sharp.Repository.Discover(String startingPath)
   at Microsoft.Build.Tasks.Git.GitOperations.LocateRepository(String directory) in /_/src/Microsoft.Build.Tasks.Git.Operations/GitOperations.cs:line 26
   at Microsoft.Build.Tasks.Git.RepositoryTasks.LocateRepository(LocateRepository task) in /_/src/Microsoft.Build.Tasks.Git.Operations/RepositoryTasks.cs:line 58
/datadisks/disk1/workspace/_work/1/s/.dotnet/sdk/3.0.100/Roslyn/Microsoft.Managed.Core.targets(102,5): error : SourceRoot items must include at least one top-level (not nested) item when DeterministicSourcePaths is true [/datadisks/disk1/workspace/_work/1/s/src/SOS/lldbplugin.tests/TestDebuggee/TestDebuggee.csproj]
2019-11-06 18:24:12 -08:00
Jeremy Koritzinsky 0efe77744d Update the docker images used to have a newer version of CMake. (#597) 2019-11-06 16:32:29 -08:00
John Salem f69f285806 Add dotnet-gcdump to diagnostics.sln so it builds in official builds (#594) 2019-11-04 18:25:50 -08:00
Juan Hoyos 5542632e1f Use OSX 10.13 as the build agent for public CI (#593)
Thanks Juan!
2019-11-04 16:18:00 -08:00
John Salem 13fe841dd0
Merge pull request #581 from josalem/dev/josalem/gcdump-tool
dotnet-gcdump
2019-11-01 18:15:05 -07:00
John Salem d4155991c6 * Refactoring to remove polling for type cache clearing session
* Switch to a static function on Stopwatch to avoid multi-threading
concerns with Stopwatch.Elapsed

* Change tool name when writing memory graph

* Add explicit null check on gcDumpSession to catch NRE in the event
EventPipe failed to connect.

* Add comment in README about future of code shared with PerfView

* Refactor to remove wrapping task for type flush session
* make EventPipeSession disposable to ensure stream is closed in case of
exception in the reader
* add using statements around source.Process calls
* add additional logging to verbose log

* Add additional logging
* add timeout option

* Remove unnecessary using statements

* Update src/Tools/dotnet-gcdump/CommandLine/CollectCommandHandler.cs

Co-Authored-By: Noah Falk <noahfalk@users.noreply.github.com>

* Update src/Tools/dotnet-gcdump/DotNetHeapDump/README.md

Co-Authored-By: Noah Falk <noahfalk@users.noreply.github.com>

* Fix weird unintended docs change

* Refactor to reduce multi-threading
* use cancellation token to cancel tasks on ctrl-c
* swallow TaskCancellationExceptions
* use volatile members for bools that are used between threads

* Check dump status on return to amke sure we don't throw additional
errors if event collection fails

* fix last whitespace issue
2019-11-01 18:10:17 -07:00
John Salem 7ab0fdd00f
Add spec for gcdump tool (#512) 2019-11-01 14:48:41 -07:00
Mike McLaughlin a1b0e4e851
Update core dump debugging work flow (#587)
Update the Linux core dump debugging work flow
2019-10-29 22:02:59 -07:00
Shiming Ge 8b7c251a77 replace obsoleted attribute CoreJobAttribute with SimpleJob (#585) 2019-10-29 01:23:13 -07:00
Sung Yoon Whang ed400df374
Fix incorrect value displayed for rate counters (#583)
* Fix incorrect value displayed for rate counters

* Add tests
2019-10-26 19:30:10 -07:00
John Salem 603e5c468a Change PerfView Utilities usage to BCL 2019-10-25 15:04:16 -07:00
John Salem bc210aa496 Initial commit of dotnet-gcdump
* NOTE: use this commit as baseline for file copied from Microsoft/PerfView
2019-10-25 14:55:32 -07:00
Sung Yoon Whang c7a9317aa2
Export feature for dotnet-counters (#493)
* Command line stuff

* Implement CSV/JSON Exporters

* some cleanup

* Overwrite the output if needed

* remove newline

* build error

* Refactor to remove duplicacy between ConsoleWriter and Exporters

* Remove ICounterExporter

* Add license headers

* Docs change

* Remove unused using

* Add file extension to output path only when necessary, remove some remaining comments and useless code

* Add unit tests for dotnet-counters

* remove useless binaries from the commit

* change comment

* tabs -> spaces

* Remove unused tests

* Address PR feedback on tests

* More PR feedback

* Fix PR comments
2019-10-25 13:03:40 -07:00
Sung Yoon Whang 217a320787
Update benchmarkdotnet version to 0.12.0 (#582) 2019-10-25 11:06:05 -07:00
Sung Yoon Whang f6eda5af57
Fix incorrect description of CreateCoreDump command - diagnostics argument (#579) 2019-10-23 10:20:03 -07:00
Felipe Pessoto 95e92dbc74 Updated profiles (#566) 2019-10-16 13:17:16 -07:00
Mike McLaughlin 66d976fda6
Fix dumpheap failures on certain dumps. (#561)
Fix dumpheap failures on certain dumps.

Issue: https://github.com/dotnet/diagnostics/issues/503

Add MemoryService to package up all the read memory "mapping" logic.

Add MemoryCache to module mapping logic.

Rewrote ReadVirtualCache because of a couple of bugs that caused
some test failures on triage dumps making !pe displaying the exception
message string  not reliable.

Add SystemMemoryVersion property to Versions.props
2019-10-15 14:58:46 -07:00
John Salem 8338ba741c
[test] Profile-Provider Merging Tests (#541) 2019-10-14 09:19:49 -07:00
Sung Yoon Whang 51c99d114c
[dotnet-trace] Allow user to specify text version of event level (#540)
* Allow user to specify text version of event level

* Throw on unknown event level

* add tests

* docs change

* more docs change

* make case insensitive comparison
2019-10-07 19:16:20 -07:00
Mike McLaughlin 87609fcd75
Fix CI build failures (Microsoft.SymbolStore version missing) (#545)
Fix SOS failure in daily scheduled build.
2019-10-07 14:25:07 -07:00
Sung Yoon Whang b1757d5b43
Refactor out list-processes command handler and add it to dotnet-dump (#534)
* Refactor out ps command handler and add it to dotnet-dump

* More refactoring

* Some renaming

* update doc

* More docs update

* fix broken renamed file reference

* catch InvalidOperationException only
2019-10-07 11:59:03 -07:00
Sung Yoon Whang 2c23d3265d
Add /ContinueOnError option to speedscope converter (#526)
* Add /ContinueOnError option to speedscope converter

* Display a warning message when we have to continue on error

* Only retry if the exception thrown is from a broken trace
2019-10-05 15:59:36 -07:00
John Doe d5054bbbbe Typos (#524)
* arbitary -> arbitrary

* buffes -> buffer

* loggging -> logging

* preceeding -> preceding

* succesful -> successful

* capablity -> capability

* commited -> committed

* diagose -> diagnose

* flamegrah -> flamegraph

* Hepers -> Helpers
2019-10-05 15:22:18 -07:00
Sung Yoon Whang 1116d88182
Fix dotnet-counters documentation (#525) 2019-10-03 12:08:36 -07:00
Mike McLaughlin b8d9f91f60
Publish symbols part 2 (#523)
Both Windows and Portable PDBs are published.

Change to Windows PDB for SOS.NETCore.dll in sos symbol zip file

Publish Microsoft.Diagnostics.TestHelpers, DebugServices, Repl and RuntimeClient symbols
2019-10-02 22:15:17 -07:00
John Salem f850a35d22
Initial batch of dotnet trace provider tests (#514) 2019-10-02 13:42:45 -07:00
Mike McLaughlin 667723e073
Display internal SOS status with sosstatus command (#519)
Display internal SOS status with sosstatus command

Add dumpvc to dotnet-dump/lldb commands.

Remove reductant dotnet-dump error message when SOS command fails.

Fixes issues:

    https://github.com/dotnet/diagnostics/issues/511
    https://github.com/dotnet/diagnostics/issues/508
    https://github.com/dotnet/diagnostics/issues/509

Change SyncBlk test not to run on xplat.
2019-10-02 10:25:39 -07:00
Andrew Au 2be426e239 Fix BitConverter calls (#516) 2019-10-01 14:35:47 -07:00
Mike McLaughlin 9a0df696f5
Add webapp debuggees and more SOS commmand tests (#507)
Add webapp debuggees and more SOS commmand tests

Add runtime version to TestConfiguration.ToString()

Added WebApp and WebApp3 as prebuilts. Use pipe to sync webapps. "dotnet-dump collect" to collect a dump from these apps.

Enable "dbgout" command logging

Speed up SOS tests by reworking ScriptLogger removing the .EndsWith on the last command output string.

Upgrade to 3.0.100 SDK

Switch to prebuilt debuggees except desktop (net462). Add debuggees.sln. Don't optimize debuggees.

Add the lldb plugin test python script as an xunit test

Publish the dump and bin artifacts on failure

Enable triage dump testing.

Switch to BYOC pools
2019-09-30 21:04:32 -07:00
Peter Bons 0800fb2e9e Fix output of console writer of dotnet-counters when displayname is not set. (#505) 2019-09-26 14:30:23 -07:00
Sung Yoon Whang f92d920369
Fix the error message when not a valid process ID is specified (#501) 2019-09-25 14:40:45 -07:00
Neeraj 6c4dbb395a Complete the !u -il SOS command 2019-09-24 20:50:50 -07:00
Mike McLaughlin d2be8fc974
Verbose logging for symbol publish, etc. (#495)
Change to preview version

Update docs with release instructions

Remove source link disabling

Change symbol publish verbosity to normal
2019-09-21 12:32:24 -07:00
Sung Yoon Whang ec26ac10bf
Fix a timeout exception causing unhandled exception crash (#492)
* Fix a timeout exception causing unhandled exception crash

* Fix the same issue on Unix too

* Move the exception handling to StopMonitor to distinguish actually incompatible runtimes from early exits

* fix build error
2019-09-20 17:14:41 -07:00
Sung Yoon Whang 1f01e7bcf8
Counter benchmark tests (#475)
* Basic benchmark test added

* don't include benchmarkdotnet artifacts in the git repo

* Some README changes, added gitignore
2019-09-18 17:32:20 -07:00
Mike McLaughlin 1571f7242c
Publish SOS symbols (#482)
Publish SOS symbols

Issue: https://github.com/dotnet/diagnostics/issues/481
2019-09-16 18:33:41 -07:00
Sung Yoon Whang c38d9dac59
Show warning when providers are specified via GUID (#476)
* Show warning when providers are specified via GUID

* Lets not throw useless exceptions

* Fix typo
2019-09-13 22:12:26 -07:00
Mike McLaughlin ecd7223a32
Various fixes and update cdb (#477)
Various fixes

Change cdb version in config

Fix symbol not found problem caused by directory symstore not setting the stream position to 0.
2019-09-13 21:08:15 -07:00
Sung Yoon Whang 8ccd54cde5
dotnet-trace CLI changes (#473)
* Fix dotnet-trace CLI according to the newest spec changes

* Add some configuration strings to help users understand where providers came from

* Some typos

* More UI changes suggested from PR

* Some strange Console bug causing issues... Clear the console before printing anything to make it work better

* remove provider/profile string from enabledBy column
2019-09-12 22:32:12 -07:00