Skip to content
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.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions dsl/gunbc/ci_gate.dag
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,5 @@ type Gate
| GeneratedArtifactDriftGate
| SourceRootIngestGate
| RegenVerifyGate
| SelfHostRealizedComparisonGate
| EmitDeterminismGate
2 changes: 1 addition & 1 deletion dsl/gunbc/ci_spec.dag
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import gunbc.ci_gate {
Gate,
RustMonolithGate, EmitHostGate, LayeringImportsGate,
ExtdepsExternalAuthorityGate, DslCompileCleanGate, GeneratedArtifactDriftGate,
SourceRootIngestGate, RegenVerifyGate, EmitDeterminismGate
SourceRootIngestGate, RegenVerifyGate, SelfHostRealizedComparisonGate, EmitDeterminismGate
}
import gunbc.ci_layer_roots {
witness_layer_roots,
Expand Down
7 changes: 6 additions & 1 deletion dsl/gunbc/commit_workflow.dag
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import gunbc.ci_gate {
Gate,
RustMonolithGate, EmitHostGate, LayeringImportsGate,
ExtdepsExternalAuthorityGate, DslCompileCleanGate, GeneratedArtifactDriftGate,
SourceRootIngestGate, RegenVerifyGate, EmitDeterminismGate
SourceRootIngestGate, RegenVerifyGate, SelfHostRealizedComparisonGate, EmitDeterminismGate
}
import gunbc.generated_artifact {
GeneratedArtifact, CiYamlArtifact, GithooksPrePushArtifact, artifact_path
Expand Down Expand Up @@ -72,6 +72,10 @@ data commit_gate_roster: List<CommitCheckEnrollment> = [
check: CommitSpecGate { gate: RegenVerifyGate },
surfaces: [GithubActionsCiJob]
},
CommitCheckEnrollment {
check: CommitSpecGate { gate: SelfHostRealizedComparisonGate },
surfaces: [GithubActionsCiJob]
},
CommitCheckEnrollment {
check: CommitSpecGate { gate: EmitDeterminismGate },
surfaces: [GithubActionsCiJob]
Expand Down Expand Up @@ -140,6 +144,7 @@ fn gate_eq(a: Gate, b: Gate) -> Bool {
GeneratedArtifactDriftGate => match b { GeneratedArtifactDriftGate => true _ => false }
SourceRootIngestGate => match b { SourceRootIngestGate => true _ => false }
RegenVerifyGate => match b { RegenVerifyGate => true _ => false }
SelfHostRealizedComparisonGate => match b { SelfHostRealizedComparisonGate => true _ => false }
EmitDeterminismGate => match b { EmitDeterminismGate => true _ => false }
}
}
Expand Down
3 changes: 2 additions & 1 deletion dsl/gunbc/merge_admission.dag
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import gunbc.ci_gate {
Gate,
RustMonolithGate, EmitHostGate, LayeringImportsGate,
ExtdepsExternalAuthorityGate, DslCompileCleanGate, GeneratedArtifactDriftGate,
SourceRootIngestGate, RegenVerifyGate, EmitDeterminismGate,
SourceRootIngestGate, RegenVerifyGate, SelfHostRealizedComparisonGate, EmitDeterminismGate,
}
import std.content_hash { content_hash_atom, content_hash_combine, content_hash_tagged }
import std.disposition { Disposition, Scaffold, SingleAuthority }
Expand Down Expand Up @@ -74,6 +74,7 @@ fn gate_content_hash(g: Gate) -> ContentHash {
GeneratedArtifactDriftGate => content_hash_atom(value: "GeneratedArtifactDriftGate")
SourceRootIngestGate => content_hash_atom(value: "SourceRootIngestGate")
RegenVerifyGate => content_hash_atom(value: "RegenVerifyGate")
SelfHostRealizedComparisonGate => content_hash_atom(value: "SelfHostRealizedComparisonGate")
EmitDeterminismGate => content_hash_atom(value: "EmitDeterminismGate")
}
}
Expand Down
5 changes: 4 additions & 1 deletion dsl/tools/ci_gates.dag
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import gunbc.ci_spec {
gunbc_ci_gates, CiSpec, Gate,
RustMonolithGate, EmitHostGate, LayeringImportsGate,
ExtdepsExternalAuthorityGate, DslCompileCleanGate, GeneratedArtifactDriftGate,
SourceRootIngestGate, RegenVerifyGate, EmitDeterminismGate
SourceRootIngestGate, RegenVerifyGate, SelfHostRealizedComparisonGate, EmitDeterminismGate
}
import tools.rust_gates_ci { run_rust_monolith_gate }
import tools.emit_host_gate { run_emit_host_ci_gate }
Expand All @@ -32,6 +32,9 @@ fn run_spec_gate(g: Gate) -> ProcessExit {
reason: "SourceRootIngestGate: run via ci_floor_plan v2.workflow.source_root_ingest_gate (slice 3)"
)
RegenVerifyGate => run_regen_verify_gate()
SelfHostRealizedComparisonGate => exit_failure(
reason: "SelfHostRealizedComparisonGate: run via ci_floor_plan v2.workflow.self_host_realized_comparison_gate"
)
EmitDeterminismGate => run_emit_determinism_gate()
}
}
Expand Down
11 changes: 10 additions & 1 deletion dsl/tools/regen_verify_transport.dag
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ import extdeps.languages.bash.program {
lit, var_ref, command, serialize_bash
}
import tools.host_prelude { ensure_regen_stage0_built }
import tools.self_host_realized_comparison_transport {
realized_comparison_stable_dir,
realized_comparison_roster_manifest_path
}
import std.disposition { Disposition, Scaffold, RealizationDispatch }
import std.decl_ref { DeclarationRef, WholeDeclaration }

Expand All @@ -17,7 +21,12 @@ fn regen_verify_program() -> ShellProgram {
set_e: true,
statements: concat(ensure_regen_stage0_built(), [
command(words: [lit(text: "cd"), root]),
command(words: [regen, lit(text: "--verify")])
command(words: [
regen,
lit(text: "--emit-fresh"), lit(text: realized_comparison_stable_dir),
lit(text: "--write-manifest"), lit(text: realized_comparison_roster_manifest_path),
lit(text: "--verify")
])
])
}
}
Expand Down
46 changes: 46 additions & 0 deletions dsl/tools/self_host_realized_comparison_transport.dag
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
module tools.self_host_realized_comparison_transport

import extdeps.shell
import extdeps.languages.bash.program {
ShellProgram, ShellStmt,
lit, var_ref, command, serialize_bash
}
import tools.host_prelude { ensure_regen_stage0_built }
import std.disposition { Disposition, Scaffold, RealizationDispatch }
import std.decl_ref { DeclarationRef, WholeDeclaration }

data realized_comparison_stable_dir: String = "target/v2-emit-fresh-realize"
data realized_comparison_emitted_src_root: String = "target/v2-emit-fresh-realize/src"
data realized_comparison_committed_src_root: String = "src/v1/stage0/src"
data realized_comparison_roster_manifest_path: String = "target/v2-emit-fresh-realize/roster_manifest.txt"

data realized_comparison_ci_subset_roster: List<String> = ["lib.rs", "v1_rt.rs"]

fn realized_comparison_program() -> ShellProgram {
let regen = var_ref(name: "REGEN_STAGE0")
ShellProgram {
set_e: true,
statements: concat(ensure_regen_stage0_built(), [
command(words: [lit(text: "cd"), var_ref(name: "ROOT")]),
command(words: [
regen,
lit(text: "--emit-fresh"), lit(text: realized_comparison_stable_dir),
lit(text: "--write-manifest"), lit(text: realized_comparison_roster_manifest_path)
])
])
}
}

data self_host_realized_comparison_transport_disposition: Disposition = Scaffold {
dissolves_to: RealizationDispatch,
bind: DeclarationRef {
module_path: "extdeps.languages.bash.program",
decl_name: "serialize_bash",
field: WholeDeclaration
}
}

fn run_self_host_realized_comparison_emit() -> Bool {
let result = shell.Exec.Run(script: serialize_bash(p: realized_comparison_program()))
result.success
}
Loading