Skip to content

Commit

Permalink
Fixes compile error with unique_ptr, and doc bug
Browse files Browse the repository at this point in the history
Signed-off-by: Ethan Mahintorabi <[email protected]>
  • Loading branch information
QuantamHD committed Feb 20, 2025
1 parent d39b006 commit f68ae2a
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 31 deletions.
52 changes: 26 additions & 26 deletions src/utl/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,32 @@ The utility module contains the `man` command.
- Parameters without square brackets `-param2 param2` are required.
```

### Prometheus Metrics

OpenROAD includes a metrics endpoint server that can track internal tool metrics over time.

![page](/docs/images/grafana.png)

To use this feature you need to do the following start the prometheus and grafana collectors

[Detailed instructions](/etc/monitoring/README.md):
```shell
$ cd etc/monitoring
$ docker compose up -d
```

This will start a grafana endpoint ready to collect from the OpenROAD application you would
like to track. By default it's looking for an http server running on port 8080 on your localhost.

To start the metrics endpoint in OpenROAD, run:
```tcl
utl::startPrometheusEndpoint 8080
```

This is all configurable in the docker compose file, and you should be able to access grafana by going to
http://localhost:3000 username: admin, password: grafana. Go to the dashboard tab and click service,
then OpenROAD to see the pre-made dashboard.

## Man installation

The `man` command can be installed optionally as part of the OpenROAD
Expand Down Expand Up @@ -95,32 +121,6 @@ Simply run the following script:
./test/regression
```

## Prometheus Metrics

OpenROAD includes a metrics endpoint server that can track internal tool metrics over time.

![page](/docs/images/grafana.png)

To use this feature you need to do the following start the prometheus and grafana collectors

[Detailed instructions](/etc/monitoring/README.md):
```shell
$ cd etc/monitoring
$ docker compose up -d
```

This will start a grafana endpoint ready to collect from the OpenROAD application you would
like to track. By default it's looking for an http server running on port 8080 on your localhost.

To start the metrics endpoint in OpenROAD, run:
```tcl
utl::startPrometheusEndpoint 8080
```

This is all configurable in the docker compose file, and you should be able to access grafana by going to
http://localhost:3000 username: admin, password: grafana. Go to the dashboard tab and click service,
then OpenROAD to see the pre-made dashboard.

## Limitations

## FAQs
Expand Down
10 changes: 5 additions & 5 deletions src/utl/include/utl/Logger.h
Original file line number Diff line number Diff line change
Expand Up @@ -359,8 +359,8 @@ class Logger
std::unique_ptr<std::ofstream> file_redirect_;

// Prometheus server metrics collection
std::shared_ptr<Registry> prometheus_registry_ = nullptr;
std::unique_ptr<PrometheusMetricsServer> prometheus_metrics_ = nullptr;
std::shared_ptr<Registry> prometheus_registry_;
std::unique_ptr<PrometheusMetricsServer> prometheus_metrics_;

// This matrix is pre-allocated so it can be safely updated
// from multiple threads without locks.
Expand Down Expand Up @@ -398,9 +398,9 @@ struct test_ostream
{
public:
template <class T>
static auto test(int)
-> decltype(std::declval<std::ostream>() << std::declval<T>(),
std::true_type());
static auto test(int) -> decltype(std::declval<std::ostream>()
<< std::declval<T>(),
std::true_type());

template <class>
static auto test(...) -> std::false_type;
Expand Down

0 comments on commit f68ae2a

Please sign in to comment.