Fix renamed paths (include_str of window_launches, a function imported from its planner module), drop the unused var_os of two settings modules
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 5.5
parent
2f562efa36
commit
4655baefaf
@@ -63,7 +63,7 @@ fn the_window_and_journal_modules_never_clone_a_handle() {
|
||||
let window_ops = [
|
||||
include_str!("../original_verify_window_ops.rs"),
|
||||
include_str!("../original_verify_window_ops/gdn_stages.rs"),
|
||||
include_str!("../original_verify_window_ops/original_verify_window_ops_methods.rs"),
|
||||
include_str!("../original_verify_window_ops/window_launches.rs"),
|
||||
include_str!("../original_verify_window_ops/qsa_prelude_ops.rs"),
|
||||
include_str!("../original_verify_window_ops/side_qsa_branches.rs"),
|
||||
include_str!("../original_verify_window_ops/side_shared_expert.rs"),
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
//! The only place of this crate that reads the process environment (`env-read` ratchet of `architecture.json`).
|
||||
//! The reads keep their call sites and their parsing; a later step replaces these two functions by a parsed settings value.
|
||||
//! The reads keep their call sites and their parsing; a later step replaces these functions by a parsed settings value.
|
||||
|
||||
use std::env::{self, VarError};
|
||||
use std::ffi::{OsStr, OsString};
|
||||
|
||||
@@ -161,7 +161,7 @@ pub use s2_gemv_planners::plan_s2_gemv_fast;
|
||||
#[allow(unused_imports)]
|
||||
pub use s2_gemv_planners::plan_s2_gemv_q8;
|
||||
#[allow(unused_imports)]
|
||||
pub use s2_gemv_planners::s2_gemv_planners;
|
||||
pub use s2_gemv_planners::plan_s2_gemv_quads;
|
||||
#[allow(unused_imports)]
|
||||
pub use s2_gemv_planners::q8_0_dequant;
|
||||
#[allow(unused_imports)]
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
//! The only place of this crate that reads the process environment (`env-read` ratchet of `architecture.json`).
|
||||
//! The reads keep their call sites and their parsing; a later step replaces these two functions by a parsed settings value.
|
||||
//! The reads keep their call sites and their parsing; a later step replaces these functions by a parsed settings value.
|
||||
|
||||
use std::env::{self, VarError};
|
||||
use std::ffi::{OsStr, OsString};
|
||||
|
||||
@@ -1,17 +1,11 @@
|
||||
//! The only place of this crate that reads the process environment (`env-read` ratchet of `architecture.json`).
|
||||
//! The reads keep their call sites and their parsing; a later step replaces these two functions by a parsed settings value.
|
||||
//! The reads keep their call sites and their parsing; a later step replaces these functions by a parsed settings value.
|
||||
|
||||
use std::env::{self, VarError};
|
||||
use std::ffi::{OsStr, OsString};
|
||||
use std::ffi::OsStr;
|
||||
|
||||
/// `std::env::var`: the text of an environment variable.
|
||||
#[inline]
|
||||
pub(crate) fn var<K: AsRef<OsStr>>(key: K) -> Result<String, VarError> {
|
||||
env::var(key)
|
||||
}
|
||||
|
||||
/// `std::env::var_os`: an environment variable that may not be valid text.
|
||||
#[inline]
|
||||
pub(crate) fn var_os<K: AsRef<OsStr>>(key: K) -> Option<OsString> {
|
||||
env::var_os(key)
|
||||
}
|
||||
|
||||
@@ -1,17 +1,11 @@
|
||||
//! The only place of this crate that reads the process environment (`env-read` ratchet of `architecture.json`).
|
||||
//! The reads keep their call sites and their parsing; a later step replaces these two functions by a parsed settings value.
|
||||
//! The reads keep their call sites and their parsing; a later step replaces these functions by a parsed settings value.
|
||||
|
||||
use std::env::{self, VarError};
|
||||
use std::ffi::{OsStr, OsString};
|
||||
use std::ffi::OsStr;
|
||||
|
||||
/// `std::env::var`: the text of an environment variable.
|
||||
#[inline]
|
||||
pub(crate) fn var<K: AsRef<OsStr>>(key: K) -> Result<String, VarError> {
|
||||
env::var(key)
|
||||
}
|
||||
|
||||
/// `std::env::var_os`: an environment variable that may not be valid text.
|
||||
#[inline]
|
||||
pub(crate) fn var_os<K: AsRef<OsStr>>(key: K) -> Option<OsString> {
|
||||
env::var_os(key)
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
//! The only place of this crate that reads the process environment (`env-read` ratchet of `architecture.json`).
|
||||
//! The reads keep their call sites and their parsing; a later step replaces these two functions by a parsed settings value.
|
||||
//! The reads keep their call sites and their parsing; a later step replaces these functions by a parsed settings value.
|
||||
|
||||
use std::env::{self, VarError};
|
||||
use std::ffi::{OsStr, OsString};
|
||||
|
||||
@@ -19,6 +19,7 @@ import shutil
|
||||
import subprocess
|
||||
import sys
|
||||
import tempfile
|
||||
import time
|
||||
|
||||
sys.path.insert(0, str(pathlib.Path(__file__).parent))
|
||||
from rust_modtree import IDENT, OPAQUE, Crate, _attribute_end, _skip_balanced, cfg_exprs, statements, strip_code # noqa: E402
|
||||
@@ -49,8 +50,21 @@ RUSTFMT = shutil.which("rustfmt") or "rustfmt"
|
||||
WORK = pathlib.Path(tempfile.gettempdir()) / "explicit-imports"
|
||||
|
||||
|
||||
def wait_for_gpu_idle(wt):
|
||||
"""The laptop is also the GPU test machine: no build starts while its wanted flag or run lock exists."""
|
||||
common = subprocess.run(
|
||||
["git", "rev-parse", "--git-common-dir"], cwd=wt, capture_output=True, text=True, check=False
|
||||
).stdout.strip()
|
||||
git_dir = (pathlib.Path(wt) / common).resolve()
|
||||
names = ("laptop-gpu-wanted.flag", "laptop-gpu-run.lock")
|
||||
while any((git_dir / n).exists() for n in names):
|
||||
print(" GPU stretch wanted or running: build paused", flush=True)
|
||||
time.sleep(60)
|
||||
|
||||
|
||||
def run_cargo(wt, args, out_name):
|
||||
"""Messages of `cargo check --message-format=json ARGS` run in `wt`; the log is kept in WORK."""
|
||||
wait_for_gpu_idle(wt)
|
||||
WORK.mkdir(parents=True, exist_ok=True)
|
||||
out = WORK / (pathlib.Path(wt).resolve().name + "-" + out_name)
|
||||
check = ["check", "--message-format=json"] + args.split()
|
||||
|
||||
@@ -12,7 +12,7 @@ import re
|
||||
import sys
|
||||
|
||||
SETTINGS = '''//! The only place of this crate that reads the process environment (`env-read` ratchet of `architecture.json`).
|
||||
//! The reads keep their call sites and their parsing; a later step replaces these two functions by a parsed settings value.
|
||||
//! The reads keep their call sites and their parsing; a later step replaces these functions by a parsed settings value.
|
||||
|
||||
use std::env::{self, VarError};
|
||||
use std::ffi::{OsStr, OsString};
|
||||
|
||||
Reference in New Issue
Block a user