mirror of
https://github.com/EmbarkStudios/rust-gpu.git
synced 2024-10-29 21:42:20 +00:00
rustup: update to nightly-2023-12-21
.
This is the last nightly tagged as 1.76.0
This commit is contained in:
parent
d70c077559
commit
5f545076d3
@ -33,7 +33,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
- [PR#1127](https://github.com/EmbarkStudios/rust-gpu/pull/1127) updated `spirv-tools` to `0.10.0`, which follows `vulkan-sdk-1.3.275`
|
||||
- [PR#1101](https://github.com/EmbarkStudios/rust-gpu/pull/1101) added `ignore` and `no_run` to documentation to make `cargo test` pass
|
||||
- [PR#1112](https://github.com/EmbarkStudios/rust-gpu/pull/1112) updated wgpu and winit in example runners
|
||||
- [PR#1102](https://github.com/EmbarkStudios/rust-gpu/pull/1102) updated toolchain to `nightly-2023-11-26`
|
||||
- [PR#1134](https://github.com/EmbarkStudios/rust-gpu/pull/1134) updated toolchain to `nightly-2023-12-21`
|
||||
- [PR#1100](https://github.com/EmbarkStudios/rust-gpu/pull/1100) updated toolchain to `nightly-2023-09-30`
|
||||
- [PR#1091](https://github.com/EmbarkStudios/rust-gpu/pull/1091) updated toolchain to `nightly-2023-08-29`
|
||||
- [PR#1085](https://github.com/EmbarkStudios/rust-gpu/pull/1085) updated toolchain to `nightly-2023-07-08`
|
||||
|
@ -10,9 +10,9 @@ use std::process::{Command, ExitCode};
|
||||
/// `cargo publish`. We need to figure out a way to do this properly, but let's hardcode it for now :/
|
||||
//const REQUIRED_RUST_TOOLCHAIN: &str = include_str!("../../rust-toolchain.toml");
|
||||
const REQUIRED_RUST_TOOLCHAIN: &str = r#"[toolchain]
|
||||
channel = "nightly-2023-11-26"
|
||||
channel = "nightly-2023-12-21"
|
||||
components = ["rust-src", "rustc-dev", "llvm-tools"]
|
||||
# commit_hash = f5dc2653fdd8b5d177b2ccbd84057954340a89fc"#;
|
||||
# commit_hash = 5ac4c8a63ee305742071ac6dd11817f7c24adce2"#;
|
||||
|
||||
fn get_rustc_commit_hash() -> Result<String, Box<dyn Error>> {
|
||||
let rustc = std::env::var("RUSTC").unwrap_or_else(|_| String::from("rustc"));
|
||||
|
@ -148,13 +148,13 @@ impl AggregatedSpirvAttributes {
|
||||
pub fn parse<'tcx>(cx: &CodegenCx<'tcx>, attrs: &'tcx [Attribute]) -> Self {
|
||||
let mut aggregated_attrs = Self::default();
|
||||
|
||||
// NOTE(eddyb) `delay_span_bug` ensures that if attribute checking fails
|
||||
// NOTE(eddyb) `span_delayed_bug` ensures that if attribute checking fails
|
||||
// to see an attribute error, it will cause an ICE instead.
|
||||
for parse_attr_result in crate::symbols::parse_attrs_for_checking(&cx.sym, attrs) {
|
||||
let (span, parsed_attr) = match parse_attr_result {
|
||||
Ok(span_and_parsed_attr) => span_and_parsed_attr,
|
||||
Err((span, msg)) => {
|
||||
cx.tcx.sess.delay_span_bug(span, msg);
|
||||
cx.tcx.sess.span_delayed_bug(span, msg);
|
||||
continue;
|
||||
}
|
||||
};
|
||||
@ -166,7 +166,7 @@ impl AggregatedSpirvAttributes {
|
||||
}) => {
|
||||
cx.tcx
|
||||
.sess
|
||||
.delay_span_bug(span, format!("multiple {category} attributes"));
|
||||
.span_delayed_bug(span, format!("multiple {category} attributes"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -290,7 +290,8 @@ impl<'tcx> ConstMethods<'tcx> for CodegenCx<'tcx> {
|
||||
}
|
||||
}
|
||||
Scalar::Ptr(ptr, _) => {
|
||||
let (alloc_id, offset) = ptr.into_parts();
|
||||
let (prov, offset) = ptr.into_parts();
|
||||
let alloc_id = prov.alloc_id();
|
||||
let (base_addr, _base_addr_space) = match self.tcx.global_alloc(alloc_id) {
|
||||
GlobalAlloc::Memory(alloc) => {
|
||||
let pointee = match self.lookup_type(ty) {
|
||||
|
@ -99,7 +99,7 @@ use rustc_codegen_ssa::traits::{
|
||||
};
|
||||
use rustc_codegen_ssa::{CodegenResults, CompiledModule, ModuleCodegen, ModuleKind};
|
||||
use rustc_data_structures::fx::FxIndexMap;
|
||||
use rustc_errors::{ErrorGuaranteed, FatalError, Handler};
|
||||
use rustc_errors::{DiagCtxt, ErrorGuaranteed, FatalError};
|
||||
use rustc_metadata::EncodedMetadata;
|
||||
use rustc_middle::dep_graph::{WorkProduct, WorkProductId};
|
||||
use rustc_middle::mir::mono::{MonoItem, MonoItemData};
|
||||
@ -294,7 +294,7 @@ impl WriteBackendMethods for SpirvCodegenBackend {
|
||||
|
||||
fn run_link(
|
||||
_cgcx: &CodegenContext<Self>,
|
||||
_diag_handler: &Handler,
|
||||
_diag_handler: &DiagCtxt,
|
||||
_modules: Vec<ModuleCodegen<Self::Module>>,
|
||||
) -> Result<ModuleCodegen<Self::Module>, FatalError> {
|
||||
todo!()
|
||||
@ -326,7 +326,7 @@ impl WriteBackendMethods for SpirvCodegenBackend {
|
||||
|
||||
unsafe fn optimize(
|
||||
_: &CodegenContext<Self>,
|
||||
_: &Handler,
|
||||
_: &DiagCtxt,
|
||||
_: &ModuleCodegen<Self::Module>,
|
||||
_: &ModuleConfig,
|
||||
) -> Result<(), FatalError> {
|
||||
@ -357,7 +357,7 @@ impl WriteBackendMethods for SpirvCodegenBackend {
|
||||
|
||||
unsafe fn codegen(
|
||||
cgcx: &CodegenContext<Self>,
|
||||
_diag_handler: &Handler,
|
||||
_diag_handler: &DiagCtxt,
|
||||
module: ModuleCodegen<Self::Module>,
|
||||
_config: &ModuleConfig,
|
||||
) -> Result<CompiledModule, FatalError> {
|
||||
@ -500,7 +500,7 @@ pub fn __rustc_codegen_backend() -> Box<dyn CodegenBackend> {
|
||||
rustc_driver::install_ice_hook(
|
||||
"https://github.com/EmbarkStudios/rust-gpu/issues/new",
|
||||
|handler| {
|
||||
handler.note_without_error(concat!(
|
||||
handler.note(concat!(
|
||||
"`rust-gpu` version `",
|
||||
env!("CARGO_PKG_VERSION"),
|
||||
"`"
|
||||
|
@ -350,7 +350,7 @@ fn do_spirv_opt(
|
||||
}
|
||||
Level::Error => sess.struct_err(msg.message).forget_guarantee(),
|
||||
Level::Warning => sess.struct_warn(msg.message),
|
||||
Level::Info | Level::Debug => sess.struct_note_without_error(msg.message),
|
||||
Level::Info | Level::Debug => sess.struct_note(msg.message),
|
||||
};
|
||||
|
||||
err.note(format!("module `{}`", filename.display()));
|
||||
|
@ -534,7 +534,7 @@ pub fn link(
|
||||
}
|
||||
|
||||
if any_spirt_bugs {
|
||||
let mut note = sess.struct_note_without_error("SPIR-T bugs were reported");
|
||||
let mut note = sess.struct_note("SPIR-T bugs were reported");
|
||||
note.help(format!(
|
||||
"pretty-printed SPIR-T was saved to {}.html",
|
||||
dump_spirt_file_path.as_ref().unwrap().display()
|
||||
|
@ -122,9 +122,9 @@ fn link_with_linker_opts(
|
||||
// is really a silent unwinding device, that should be treated the same as
|
||||
// `Err(ErrorGuaranteed)` returns from `link`).
|
||||
rustc_driver::catch_fatal_errors(|| {
|
||||
let mut early_error_handler = rustc_session::EarlyErrorHandler::new(
|
||||
rustc_session::config::ErrorOutputType::default(),
|
||||
);
|
||||
let mut early_error_handler =
|
||||
rustc_session::EarlyDiagCtxt::new(rustc_session::config::ErrorOutputType::default());
|
||||
early_error_handler.initialize_checked_jobserver();
|
||||
let matches = rustc_driver::handle_options(
|
||||
&early_error_handler,
|
||||
&["".to_string(), "x.rs".to_string()],
|
||||
@ -135,7 +135,7 @@ fn link_with_linker_opts(
|
||||
|
||||
rustc_span::create_session_globals_then(sopts.edition, || {
|
||||
let mut sess = rustc_session::build_session(
|
||||
&early_error_handler,
|
||||
early_error_handler,
|
||||
sopts,
|
||||
CompilerIO {
|
||||
input: Input::Str {
|
||||
@ -160,7 +160,7 @@ fn link_with_linker_opts(
|
||||
|
||||
// HACK(eddyb) inject `write_diags` into `sess`, to work around
|
||||
// the removals in https://github.com/rust-lang/rust/pull/102992.
|
||||
sess.parse_sess.span_diagnostic = {
|
||||
sess.parse_sess.dcx = {
|
||||
let fallback_bundle = {
|
||||
extern crate rustc_error_messages;
|
||||
rustc_error_messages::fallback_fluent_bundle(
|
||||
@ -172,8 +172,8 @@ fn link_with_linker_opts(
|
||||
rustc_errors::emitter::EmitterWriter::new(Box::new(buf), fallback_bundle)
|
||||
.sm(Some(sess.parse_sess.clone_source_map()));
|
||||
|
||||
rustc_errors::Handler::with_emitter(Box::new(emitter))
|
||||
.with_flags(sess.opts.unstable_opts.diagnostic_handler_flags(true))
|
||||
rustc_errors::DiagCtxt::with_emitter(Box::new(emitter))
|
||||
.with_flags(sess.opts.unstable_opts.dcx_flags(true))
|
||||
};
|
||||
|
||||
let res = link(
|
||||
|
@ -569,7 +569,7 @@ fn parse_local_size_attr(arg: &NestedMetaItem) -> Result<[u32; 3], ParseAttrErro
|
||||
}
|
||||
Ok(local_size)
|
||||
}
|
||||
Some(tuple) if tuple.is_empty() => Err((
|
||||
Some([]) => Err((
|
||||
arg.span,
|
||||
"#[spirv(compute(threads(x, y, z)))] must have the x dimension specified, trailing ones may be elided".to_string(),
|
||||
)),
|
||||
|
@ -2,7 +2,7 @@
|
||||
<!-- markdownlint-disable-file MD033 -->
|
||||
# `spirv-builder`
|
||||
|
||||
![Rust version](https://img.shields.io/badge/rust-nightly--2023--05--27-purple.svg)
|
||||
![Rust version](https://img.shields.io/badge/rust-nightly--2023--12--21-purple.svg)
|
||||
|
||||
This crate gives you `SpirvBuilder`, a tool to build shaders using [rust-gpu][rustgpu].
|
||||
|
||||
@ -31,12 +31,13 @@ const SHADER: &[u8] = include_bytes!(env!("my_shaders.spv"));
|
||||
|
||||
As `spirv-builder` relies on `rustc_codegen_spirv` being built for it (by Cargo, as a direct dependency), and due to the special nature of the latter (as a `rustc` codegen backend "plugin"), both end up sharing the requirement for a very specific nightly toolchain version of Rust.
|
||||
|
||||
**The current Rust toolchain version is: `nightly-2023-05-27`.**
|
||||
**The current Rust toolchain version is: `nightly-2023-12-21`.**
|
||||
|
||||
Rust toolchain version history across [rust-gpu releases](https://github.com/EmbarkStudios/rust-gpu/releases) (since `0.4`):
|
||||
|
||||
|`spirv-builder`<br>version|Rust toolchain<br>version|
|
||||
|:-:|:-:|
|
||||
|`0.10`|`nightly-2023-12-21`|
|
||||
|`0.9`|`nightly-2023-05-27`|
|
||||
|`0.8`|`nightly-2023-04-15`|
|
||||
|`0.7`|`nightly-2023-03-04`|
|
||||
|
@ -1,7 +1,7 @@
|
||||
[toolchain]
|
||||
channel = "nightly-2023-11-26"
|
||||
channel = "nightly-2023-12-21"
|
||||
components = ["rust-src", "rustc-dev", "llvm-tools"]
|
||||
# commit_hash = f5dc2653fdd8b5d177b2ccbd84057954340a89fc
|
||||
# commit_hash = 5ac4c8a63ee305742071ac6dd11817f7c24adce2
|
||||
|
||||
# Whenever changing the nightly channel, update the commit hash above, and make
|
||||
# sure to change `REQUIRED_TOOLCHAIN` in `crates/rustc_codegen_spirv/build.rs` also.
|
||||
|
@ -4,7 +4,7 @@ OpLine %5 11 12
|
||||
%6 = OpLoad %7 %8
|
||||
OpLine %5 11 35
|
||||
%9 = OpLoad %7 %10
|
||||
OpLine %11 1142 4
|
||||
OpLine %11 1145 4
|
||||
%12 = OpBitwiseAnd %7 %9 %13
|
||||
%14 = OpISub %7 %15 %12
|
||||
%16 = OpShiftLeftLogical %7 %6 %12
|
||||
|
@ -1,13 +1,13 @@
|
||||
error: cannot memcpy dynamically sized data
|
||||
--> $CORE_SRC/intrinsics.rs:2776:9
|
||||
--> $CORE_SRC/intrinsics.rs:2794:9
|
||||
|
|
||||
2776 | copy(src, dst, count)
|
||||
2794 | copy(src, dst, count)
|
||||
| ^^^^^^^^^^^^^^^^^^^^^
|
||||
|
|
||||
note: used from within `core::intrinsics::copy::<f32>`
|
||||
--> $CORE_SRC/intrinsics.rs:2762:21
|
||||
--> $CORE_SRC/intrinsics.rs:2780:21
|
||||
|
|
||||
2762 | pub const unsafe fn copy<T>(src: *const T, dst: *mut T, count: usize) {
|
||||
2780 | pub const unsafe fn copy<T>(src: *const T, dst: *mut T, count: usize) {
|
||||
| ^^^^
|
||||
note: called by `ptr_copy::copy_via_raw_ptr`
|
||||
--> $DIR/ptr_copy.rs:28:18
|
||||
|
@ -2,7 +2,7 @@
|
||||
%4 = OpFunctionParameter %5
|
||||
%6 = OpFunctionParameter %5
|
||||
%7 = OpLabel
|
||||
OpLine %8 1200 8
|
||||
OpLine %8 1215 8
|
||||
%9 = OpLoad %10 %4
|
||||
OpLine %11 7 13
|
||||
OpStore %6 %9
|
||||
|
@ -2,7 +2,7 @@
|
||||
%4 = OpFunctionParameter %5
|
||||
%6 = OpFunctionParameter %5
|
||||
%7 = OpLabel
|
||||
OpLine %8 1200 8
|
||||
OpLine %8 1215 8
|
||||
%9 = OpLoad %10 %4
|
||||
OpLine %11 7 13
|
||||
OpStore %6 %9
|
||||
|
@ -4,7 +4,7 @@
|
||||
%7 = OpLabel
|
||||
OpLine %8 7 35
|
||||
%9 = OpLoad %10 %4
|
||||
OpLine %11 1400 8
|
||||
OpLine %11 1415 8
|
||||
OpStore %6 %9
|
||||
OpNoLine
|
||||
OpReturn
|
||||
|
@ -4,7 +4,7 @@
|
||||
%7 = OpLabel
|
||||
OpLine %8 7 37
|
||||
%9 = OpLoad %10 %4
|
||||
OpLine %11 1400 8
|
||||
OpLine %11 1415 8
|
||||
OpStore %6 %9
|
||||
OpNoLine
|
||||
OpReturn
|
||||
|
@ -1,3 +1,12 @@
|
||||
warning: the feature `ptr_internals` is internal to the compiler or standard library
|
||||
--> $DIR/allocate_const_scalar.rs:6:12
|
||||
|
|
||||
6 | #![feature(ptr_internals)]
|
||||
| ^^^^^^^^^^^^^
|
||||
|
|
||||
= note: using it is strongly discouraged
|
||||
= note: `#[warn(internal_features)]` on by default
|
||||
|
||||
error: pointer has non-null integer address
|
||||
|
|
||||
note: used from within `allocate_const_scalar::main`
|
||||
@ -11,5 +20,5 @@ note: called by `main`
|
||||
15 | pub fn main(output: &mut Unique<[u8; 4]>) {
|
||||
| ^^^^
|
||||
|
||||
error: aborting due to 1 previous error
|
||||
error: aborting due to 1 previous error; 1 warning emitted
|
||||
|
||||
|
11
tests/ui/lang/core/ptr/allocate_vec_like.stderr
Normal file
11
tests/ui/lang/core/ptr/allocate_vec_like.stderr
Normal file
@ -0,0 +1,11 @@
|
||||
warning: the feature `ptr_internals` is internal to the compiler or standard library
|
||||
--> $DIR/allocate_vec_like.rs:4:12
|
||||
|
|
||||
4 | #![feature(ptr_internals)]
|
||||
| ^^^^^^^^^^^^^
|
||||
|
|
||||
= note: using it is strongly discouraged
|
||||
= note: `#[warn(internal_features)]` on by default
|
||||
|
||||
warning: 1 warning emitted
|
||||
|
Loading…
Reference in New Issue
Block a user