diff --git a/Readme.md b/Readme.md index 3201afbd7820..b473f79a526b 100644 --- a/Readme.md +++ b/Readme.md @@ -172,7 +172,7 @@ debug_gimple_stmt(gimple_struct) To get the `rustc` command to run in `gdb`, add the `--verbose` flag to `cargo build`. -To have the correct file paths in `gdb` instead of `/usr/src/debug/gcc/libstdc++-v3/libsupc++/eh_personality.cc`, TODO +To have the correct file paths in `gdb` instead of `/usr/src/debug/gcc/libstdc++-v3/libsupc++/eh_personality.cc`: Maybe by calling the following at the beginning of gdb: @@ -180,7 +180,7 @@ Maybe by calling the following at the beginning of gdb: set substitute-path /usr/src/debug/gcc /path/to/gcc-repo/gcc ``` -TODO: but that's not what I remember I was doing. +TODO(antoyo): but that's not what I remember I was doing. ### How to use a custom-build rustc diff --git a/failing-ui-tests.txt b/failing-ui-tests.txt index f3784e65ce90..a51a7f1428e3 100644 --- a/failing-ui-tests.txt +++ b/failing-ui-tests.txt @@ -13,7 +13,6 @@ src/test/ui/debuginfo/debuginfo-emit-llvm-ir-and-split-debuginfo.rs src/test/ui/functions-closures/parallel-codegen-closures.rs src/test/ui/linkage-attr/linkage1.rs src/test/ui/lto/dylib-works.rs -src/test/ui/macros/rfc-2011-nicer-assert-messages/assert-without-captures-does-not-create-unnecessary-code.rs src/test/ui/numbers-arithmetic/saturating-float-casts.rs src/test/ui/polymorphization/promoted-function.rs src/test/ui/process/nofile-limit.rs @@ -47,6 +46,18 @@ src/test/ui/oom_unwind.rs src/test/ui/panic-runtime/abort-link-to-unwinding-crates.rs src/test/ui/panic-runtime/abort.rs src/test/ui/panic-runtime/link-to-abort.rs +src/test/ui/unwind-no-uwtable.rs +src/test/ui/issues/issue-14875.rs +src/test/ui/issues/issue-29948.rs +src/test/ui/issues/issue-40883.rs +src/test/ui/issues/issue-43853.rs +src/test/ui/issues/issue-47364.rs +src/test/ui/simd/issue-17170.rs +src/test/ui/simd/issue-39720.rs +src/test/ui/simd/issue-85915-simd-ptrs.rs +src/test/ui/simd/issue-89193.rs +src/test/ui/statics/issue-91050-1.rs +src/test/ui/statics/issue-91050-2.rs +src/test/ui/macros/rfc-2011-nicer-assert-messages/assert-without-captures-does-not-create-unnecessary-code.rs src/test/ui/rfc-2091-track-caller/std-panic-locations.rs src/test/ui/rfcs/rfc1857-drop-order.rs -src/test/ui/unwind-no-uwtable.rs diff --git a/failing-ui-tests12.txt b/failing-ui-tests12.txt index 64c8bcdf5c2c..22441efeee9f 100644 --- a/failing-ui-tests12.txt +++ b/failing-ui-tests12.txt @@ -37,4 +37,3 @@ src/test/ui/cfg/cfg-panic.rs src/test/ui/generator/size-moved-locals.rs src/test/ui/macros/rfc-2011-nicer-assert-messages/all-not-available-cases.rs src/test/ui/runtime/rt-explody-panic-payloads.rs -src/test/ui/simd/issue-17170.rs diff --git a/src/builder.rs b/src/builder.rs index 0150f5ba8c14..6ac1daeca5d9 100644 --- a/src/builder.rs +++ b/src/builder.rs @@ -375,8 +375,7 @@ impl<'tcx> FnAbiOfHelpers<'tcx> for Builder<'_, '_, 'tcx> { impl<'a, 'gcc, 'tcx> Deref for Builder<'a, 'gcc, 'tcx> { type Target = CodegenCx<'gcc, 'tcx>; - fn deref<'b>(&'b self) -> &'a Self::Target - { + fn deref<'b>(&'b self) -> &'a Self::Target { self.cx } } @@ -1216,7 +1215,7 @@ impl<'a, 'gcc, 'tcx> BuilderMethods<'a, 'tcx> for Builder<'a, 'gcc, 'tcx> { let value = self.current_func().new_local(None, struct_type.as_type(), "landing_pad"); let ptr = self.cx.context.new_cast(None, ptr, field1_type); self.block.add_assignment(None, value.access_field(None, field1), ptr); - self.block.add_assignment(None, value.access_field(None, field2), zero); // TODO: set the proper value here (the type of exception?). + self.block.add_assignment(None, value.access_field(None, field2), zero); // TODO(antoyo): set the proper value here (the type of exception?). value.to_rvalue() } @@ -1232,7 +1231,7 @@ impl<'a, 'gcc, 'tcx> BuilderMethods<'a, 'tcx> for Builder<'a, 'gcc, 'tcx> { #[cfg(feature="master")] fn resume(&mut self, exn: RValue<'gcc>) { - // TODO: check if this is normal that we need to dereference the value. + // TODO(antoyo): check if this is normal that we need to dereference the value. // NOTE: the type is wrong, so in order to get a pointer for parameter, cast it to a // pointer of pointer that is later dereferenced. let exn_type = exn.get_type().make_pointer(); diff --git a/src/callee.rs b/src/callee.rs index 70cdece7f0af..bc68340e7a07 100644 --- a/src/callee.rs +++ b/src/callee.rs @@ -30,7 +30,7 @@ pub fn get_fn<'gcc, 'tcx>(cx: &CodegenCx<'gcc, 'tcx>, instance: Instance<'tcx>) let func = if let Some(_func) = cx.get_declared_value(&sym) { - // FIXME: we never reach this because get_declared_value only returns global variables + // FIXME(antoyo): we never reach this because get_declared_value only returns global variables // and here we try to get a function. unreachable!(); /* diff --git a/src/context.rs b/src/context.rs index a66e13b6008a..07222c534401 100644 --- a/src/context.rs +++ b/src/context.rs @@ -258,7 +258,6 @@ impl<'gcc, 'tcx> CodegenCx<'gcc, 'tcx> { pub fn rvalue_as_function(&self, value: RValue<'gcc>) -> Function<'gcc> { let function: Function<'gcc> = unsafe { std::mem::transmute(value) }; - // FIXME: seems like self.functions get overwritten for rust_eh_personality. debug_assert!(self.functions.borrow().values().find(|value| **value == function).is_some(), "{:?} is not a function", function); function @@ -334,6 +333,7 @@ impl<'gcc, 'tcx> MiscMethods<'tcx> for CodegenCx<'gcc, 'tcx> { fn get_fn(&self, instance: Instance<'tcx>) -> RValue<'gcc> { let func = get_fn(self, instance); *self.current_func.borrow_mut() = Some(func); + // FIXME(antoyo): this is a wrong cast. That requires changing the compiler API. unsafe { std::mem::transmute(func) } } diff --git a/src/intrinsic/mod.rs b/src/intrinsic/mod.rs index 46471096e910..6ca171801159 100644 --- a/src/intrinsic/mod.rs +++ b/src/intrinsic/mod.rs @@ -1158,8 +1158,6 @@ fn try_intrinsic<'a, 'b, 'gcc, 'tcx>(bx: &'b mut Builder<'a, 'gcc, 'tcx>, try_fu // the right personality function. #[cfg(feature="master")] fn codegen_gnu_try<'gcc>(bx: &mut Builder<'_, 'gcc, '_>, try_func: RValue<'gcc>, data: RValue<'gcc>, catch_func: RValue<'gcc>, dest: RValue<'gcc>) { - //use std::ops::Deref; - //let cx: &CodegenCx<'gcc, '_> = bx.deref(); let cx: &CodegenCx<'gcc, '_> = bx.cx; let (llty, func) = get_rust_try_fn(cx, &mut |mut bx| { // Codegens the shims described above: @@ -1204,7 +1202,7 @@ fn codegen_gnu_try<'gcc>(bx: &mut Builder<'_, 'gcc, '_>, try_func: RValue<'gcc>, // NOTE: the blocks must be filled before adding the try/catch, otherwise gcc will not // generate a try/catch. - // FIXME: add a check in the libgccjit API to prevent this. + // FIXME(antoyo): add a check in the libgccjit API to prevent this. bx.switch_to_block(current_block); bx.invoke(try_func_ty, try_func, &[data], then, catch, None); });