-
Notifications
You must be signed in to change notification settings - Fork 2k
Super fast extended tests #21084
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
base: main
Are you sure you want to change the base?
Super fast extended tests #21084
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -40,7 +40,7 @@ use std::cmp::{Ordering, min}; | |
| use std::collections::HashSet; | ||
| use std::num::NonZero; | ||
| use std::ops::Range; | ||
| use std::sync::Arc; | ||
| use std::sync::{Arc, LazyLock}; | ||
| use std::thread::available_parallelism; | ||
|
|
||
| /// Applies an optional projection to a [`SchemaRef`], returning the | ||
|
|
@@ -923,10 +923,15 @@ pub fn combine_limit( | |
| /// | ||
| /// This is a wrapper around `std::thread::available_parallelism`, providing a default value | ||
| /// of `1` if the system's parallelism cannot be determined. | ||
| /// | ||
| /// The result is cached after the first call. | ||
| pub fn get_available_parallelism() -> usize { | ||
| available_parallelism() | ||
| .unwrap_or(NonZero::new(1).expect("literal value `1` shouldn't be zero")) | ||
| .get() | ||
| static PARALLELISM: LazyLock<usize> = LazyLock::new(|| { | ||
|
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this obviously affects not only tests, happy to apply to only tests, but feels like a good change overall? 🤔
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Hmm great find! Perhaps there also seems to go something wrong with |
||
| available_parallelism() | ||
| .unwrap_or(NonZero::new(1).expect("literal value `1` shouldn't be zero")) | ||
| .get() | ||
| }); | ||
| *PARALLELISM | ||
| } | ||
|
|
||
| /// Converts a collection of function arguments into a fixed-size array of length N | ||
|
|
||

Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this sets
RUST_BACKTRACE=1and we have a lot of expected failures in sqlogictests - getting backtrace for those is pointless and expensive