This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #[bench] | |
| fn game_of_life(b: &mut Bencher) { | |
| // naive Vec implementation | |
| const size_board_side: usize = 1024 * 8; | |
| // 1d vec | |
| let mut board = vec![0u8; size_board_side * size_board_side]; | |
| let mut next_state: Vec<u8> = vec![0; size_board_side * size_board_side]; | |
| // random initialization | |
| // outermost ring is invalid | |
| for i in 1..size_board_side - 1 { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| """ | |
| Download and extract Trivy Windows binary (trivy.exe) into a "trivy" folder. | |
| Usage: | |
| python download_trivy_windows.py [--version X.Y.Z] | |
| If --version is omitted the script queries the GitHub API for the latest release. | |
| """ | |
| import argparse |
OlderNewer