google / google/xls

[enhancement] Harmonize names of flags meaning the same thing

Open
#2,365 0 comments 1 reaction 0 assignees View on GitHub
enhancement
Dominant language
C++
Stars
1.9k
Forks
283
Avg merge
2d 10h
Merged PRs (30d)
135

Description

### What's hard to do? (limit 100 words)

Semantically similar flags have different names in various binaries: Say the main output of a binay:

* `ir_converter_main` uses `--output_file` for its main output
* `opt_main` calls its output `--output_path`
* `codegen_main` uses `--output_verilog_path` (it has a bunch of other output flags for other side outputs, which are probably good names but the main output should be easily discoverable)

Or the standlib path
* `ir_converter_main` and `interpreter_main` use `--dslx_stdlib_path` while `dslx_ls` uses `--stdlib_path`

### Current best alternative workaround (limit 100 words)

The main output of binaries should probably be harmonized to a short `-o` option which is the discoverable name for anyone using any kind of Unix tool.

The standard-lib path should probably be `--dslx_stdlib_path`.

There probably needs to be a fallback support for the old flags, wich loud warnings that it will go away and then eventually removing the old flags.

### Your view of the "best case XLS enhancement" (limit 100 words)

Use `-o` for main outputs. Use `--dslx_stdlib_path` for stdlib.

This issue is not exhaustive: There are probably more flags in main binaries that should be surveyed to see if the semantically same thing is called the same.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.