Skip to content

prof only works on amd64 #385

@gopherbot

Description

@gopherbot

by bslesinsky:

Running the profiler on 32-bit x86 results in:

$ 6prof main
prof: can't read registers: can't translate address 90
1 samples (avg 1 threads) 

This is because the code includes ureg_amd64.h and no provision is made for
other architectures.

I've attached a patch that makes it work for a 32-bit Mac and looks like it
should work for all 32-bit x86. (It looks like the code could be made
portable with suitable application of #ifdef.)

What is your $GOOS?  $GOARCH?

darwin 386

Which revision are you using?  (hg identify)

bdfc3faa253a+ tip

Attachments:

  1. fix_prof.patch (1754 bytes)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions