Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

upgrade to memchr 2.6 to bring in aarch64 improvements #1079

Merged
merged 1 commit into from
Aug 29, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 2 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ std = [
# to actually emit the log messages somewhere.
logging = [
"aho-corasick?/logging",
"memchr?/logging",
"regex-automata/logging",
]
# The 'use_std' feature is DEPRECATED. It will be removed in regex 2. Until
Expand Down Expand Up @@ -167,7 +168,7 @@ optional = true

# For skipping along search text quickly when a leading byte is known.
[dependencies.memchr]
version = "2.5.0"
version = "2.6.0"
optional = true

# For the actual regex engines.
Expand Down
9 changes: 5 additions & 4 deletions fuzz/fuzz_targets/ast_fuzz_match.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,12 @@ fuzz_target!(|data: FuzzData| -> Corpus {
let _ = env_logger::try_init();

let pattern = format!("{}", data.ast);
let Ok(re) = RegexBuilder::new(&pattern).size_limit(1<<20).build() else {
let Ok(re) = RegexBuilder::new(&pattern).size_limit(1 << 20).build()
else {
return Corpus::Reject;
};
re.is_match(&data.haystack);
re.find(&data.haystack);
re.captures(&data.haystack).map_or(0, |c| c.len());
let _ = re.is_match(&data.haystack);
let _ = re.find(&data.haystack);
let _ = re.captures(&data.haystack).map_or(0, |c| c.len());
Corpus::Keep
});
9 changes: 5 additions & 4 deletions fuzz/fuzz_targets/ast_fuzz_match_bytes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,12 @@ fuzz_target!(|data: FuzzData| -> Corpus {
let _ = env_logger::try_init();

let pattern = format!("{}", data.ast);
let Ok(re) = RegexBuilder::new(&pattern).size_limit(1<<20).build() else {
let Ok(re) = RegexBuilder::new(&pattern).size_limit(1 << 20).build()
else {
return Corpus::Reject;
};
re.is_match(&data.haystack);
re.find(&data.haystack);
re.captures(&data.haystack).map_or(0, |c| c.len());
let _ = re.is_match(&data.haystack);
let _ = re.find(&data.haystack);
let _ = re.captures(&data.haystack).map_or(0, |c| c.len());
Corpus::Keep
});
4 changes: 2 additions & 2 deletions regex-automata/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ bench = false
default = ["std", "syntax", "perf", "unicode", "meta", "nfa", "dfa", "hybrid"]
std = ["regex-syntax?/std", "memchr?/std", "aho-corasick?/std", "alloc"]
alloc = []
logging = ["dep:log", "aho-corasick?/logging"]
logging = ["dep:log", "aho-corasick?/logging", "memchr?/logging"]

syntax = ["dep:regex-syntax", "alloc"]

Expand Down Expand Up @@ -84,7 +84,7 @@ internal-instrument-pikevm = ["logging", "std"]
[dependencies]
aho-corasick = { version = "1.0.0", optional = true, default-features = false }
log = { version = "0.4.14", optional = true }
memchr = { version = "2.5.0", optional = true, default-features = false }
memchr = { version = "2.6.0", optional = true, default-features = false }
regex-syntax = { path = "../regex-syntax", version = "0.7.4", optional = true, default-features = false }

[dev-dependencies]
Expand Down