Skip to content

Commit

Permalink
Merge branch 'exp'
Browse files Browse the repository at this point in the history
  • Loading branch information
ShinobuAmasaki committed Sep 1, 2024
2 parents 0b38eeb + f26e9e0 commit 270d607
Showing 1 changed file with 11 additions and 19 deletions.
30 changes: 11 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -203,31 +203,19 @@ end block

### Command Line Interface Tool

Version 3.2 introduces a command line tool that is called `forgex-cli` and uses the Forgex engine for debugging, testing, and benchmarking regex matches. It performs matching with commands such as the one shown in below, and outputs the results directly to standard output. [For detailed information, please refer to the documentation.](https://shinobuamasaki.github.io/forgex/page/English/forgex_on_command_line_en.html)
Version 3.2 introduces a command line tool that is called `forgex-cli` and uses the Forgex engine for debugging, testing, and benchmarking regex matches. It performs matching with commands such as the one shown in below, and outputs the results directly to standard output.

Command:

```shell
forgex-cli find match lazy-dfa '([a-z]*g+)n?' .match. 'assign'
```

If you run it through `fpm run`:

```shell
fpm run forgex-cli --profile release -- find match lazy-dfa '([a-z]*g+)n?' .match. 'assign'
```
% forgex-cli find match lazy-dfa '([a-z]*g+)n?' .match. 'assign'
Output:

```
pattern: ([a-z]*g+)n?
text: 'assign'
parse time: 42.9us
extract literal time: 23.0us
parse time: 64.0μs
extract literal time: 6.9μs
runs engine: T
compile nfa time: 26.5us
dfa initialize time: 4.6us
search time: 617.1us
compile nfa time: 47.8μs
dfa initialize time: 5.4μs
search time: 704.9μs
matching result: T
memory (estimated): 10324
Expand All @@ -253,6 +241,10 @@ state 4A = ( 2 4 5 6 )
===================================
```

Starting with version 3.5, the command line tools are provided in a separate repository, see the link below:

[ShinobuAmasaki/forgex-cli](https://github.com/ShinobuAmasaki/forgex-cli)

### Notes

- A program built by `gfortran` on Windows and macOS may crash if an allocatable character is used in an OpenMP parallel block.
Expand Down

0 comments on commit 270d607

Please sign in to comment.