Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cross platform disassembler doensn't output anything on macOS #1499

Open
NinoFloris opened this issue Jul 15, 2020 · 2 comments
Open

Cross platform disassembler doensn't output anything on macOS #1499

NinoFloris opened this issue Jul 15, 2020 · 2 comments

Comments

@NinoFloris
Copy link

NinoFloris commented Jul 15, 2020

Cross platform disassembler doesn't output anything on macOS

Details: .net core 5.0 preview 6, BDN 0.12.1 (which should have xplat support)

For a benchmark like

open BenchmarkDotNet.Attributes
open BenchmarkDotNet.Running

type Service =
    abstract Prop : int

[<Sealed>]
type Impl() =
    interface Service with
        member x.Prop = 1

[<DisassemblyDiagnoser(exportGithubMarkdown= true)>]
type Devirt() =
    [<Benchmark>]
    member _.DevirtProp() = (Impl() :> Service).Prop

[<EntryPoint>]
let main argv =
   BenchmarkRunner.Run<Devirt>() |> ignore
   0

BDN returns

// * Diagnostic Output - DisassemblyDiagnoser *
No benchmarks were disassembled

This does not seem to be an F# issue, a quick port of this benchmark to C# bore no fruit either.

@0xd4d
Copy link

0xd4d commented Jul 23, 2020

Could be that clrmd is unable to read anything from the process. Updating to latest 1.x or trying 2.x could possibly fix that https://www.nuget.org/packages/Microsoft.Diagnostics.Runtime/

@adamsitnik
Copy link
Member

I've ported BDN to use ClrMd2 (#2040) but I was not able to get macOS support: microsoft/clrmd#1034

It seems that attaching a debugger to another process requires a lot of work on macOS: http://os-tres.net/blog/2010/02/17/mac-os-x-and-task-for-pid-mach-call/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants