code: func convertPerfData(perfPath string, ui plugin.UI) (*os.File, error) {
  	ui.Print(fmt.Sprintf(
  		"Converting %s to a profile.proto... (May take a few minutes)",
  		perfPath))
  	profile, err := newTempFile(os.TempDir(), "pprof_", ".pb.gz")
  	if err != nil {
  		return nil, err
  	}
  	deferDeleteTempFile(profile.Name())
  	cmd := exec.Command("perf_to_profile", "-i", perfPath, "-o", profile.Name(), "-f")
  	cmd.Stdout, cmd.Stderr = os.Stdout, os.Stderr
  	if err := cmd.Run(); err != nil {
  		profile.Close()
  		return nil, fmt.Errorf("failed to convert perf.data file. Try github.com/google/perf_data_converter: %v", err)
  	}
  	return profile, nil
  }
docs: // convertPerfData converts the file at path which should be in perf.data format
  // using the perf_to_profile tool and returns the file containing the
  // profile.proto formatted data.