Skip to content

Conversation

@wyfcyx
Copy link

@wyfcyx wyfcyx commented Jan 19, 2022

The feature llvm_asm has been deprecated in the newest Rust nightly channel. Therefore, we should remove the llvm_asm feature and replace all the llvm_asm! with asm! to keep up with Rust. By the way, macros.rs is from the upstream.

Copy link
Member

@wangrunji0408 wangrunji0408 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@wangrunji0408 wangrunji0408 merged commit 11d43cf into rcore-os:master Jan 20, 2022
@x931890193
Copy link

hey man:
it is not cool for me!

 Finished dev [unoptimized + debuginfo] target(s) in 0.00s
Targets: hello_world notebook
Image resized.
   Compiling bitvec v0.22.3
   Compiling riscv v0.6.0 (https://github.com/rcore-os/riscv#11d43cf7)
error[E0433]: failed to resolve: could not find `asm` in `arch`
  --> /Users/sato/.cargo/git/checkouts/riscv-ab2abd16c438337b/11d43cf/src/asm.rs:10:35
   |
10 |                   () => core::arch::asm!($asm),
   |                                     ^^^ could not find `asm` in `arch`
...
28 | / instruction!(
29 | |     /// `EBREAK` instruction wrapper
30 | |     ///
31 | |     /// Generates a breakpoint exception.
32 | |     , ebreak, "ebreak", __ebreak);
   | |__________________________________- in this macro invocation
   |
   = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0433]: failed to resolve: could not find `asm` in `arch`
  --> /Users/sato/.cargo/git/checkouts/riscv-ab2abd16c438337b/11d43cf/src/asm.rs:10:35
   |
10 |                   () => core::arch::asm!($asm),
   |                                     ^^^ could not find `asm` in `arch`
...
33 | / instruction!(
34 | |     /// `WFI` instruction wrapper
35 | |     ///
36 | |     /// Provides a hint to the implementation that the current hart can be stalled until an interrupt might need servicing.
37 | |     /// The WFI instruction is just a hint, and a legal implementation is to implement WFI as a NOP.
38 | |     , wfi, "wfi", __wfi);
   | |_________________________- in this macro invocation
   |
   = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)

@wangrunji0408
Copy link
Member

Hi @x931890193, it seems that your Rust toolchain is outdated. Try to update by rustup update nightly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants