Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rust upgrade to 1.68.0 after cargo run error #11832

Closed
Yakumo-Yukari opened this issue Mar 11, 2023 · 7 comments
Closed

rust upgrade to 1.68.0 after cargo run error #11832

Yakumo-Yukari opened this issue Mar 11, 2023 · 7 comments
Labels
C-bug Category: bug S-needs-info Status: Needs more info, such as a reproduction or more background for a feature request.

Comments

@Yakumo-Yukari
Copy link

Yakumo-Yukari commented Mar 11, 2023

Problem

$ cargo run
   Compiling hellorust v0.1.0 (E:\Klee\code\hellorust)
error: could not compile `hellorust`

Caused by:
  process didn't exit successfully: `rustc --crate-name hellorust --edition=2021 'src\main.rs' --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --diagnostic-width=79 --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debuginfo=2 -C metadata=31af1aa08fb0c465 --out-dir 'E:\Klee\code\hellorust\target\debug\deps' -C 'incremental=E:\Klee\code\hellorust\target\debug\incremental' -L 'dependency=E:\Klee\code\hellorust\target\debug\deps'` (exit code: 0xc000001d, STATUS_ILLEGAL_INSTRUCTION)

Steps

No response

Possible Solution(s)

No response

Notes

No response

Version

hellorust v0.1.0 (E:\Klee\code\hellorust)
rustc 1.68.0 (2c8cc3432 2023-03-06)
cargo 1.68.0 (115f34552 2023-02-26)
Default host: x86_64-pc-windows-msvc
rustup home:  C:\Users\Alice\.rustup
stable-x86_64-pc-windows-msvc (default)
@Yakumo-Yukari Yakumo-Yukari added the C-bug Category: bug label Mar 11, 2023
@weihanglo
Copy link
Member

Hello. I suspect it panicked. Do you have a reproducible code example to share?

Also, could you run again with backtrace? Something like

$env:RUST_BACKTRACE=1; cargo run

will give us richer error information.
(Use set RUST_BACKTRACE=1 if on cmd)

@weihanglo weihanglo added the S-needs-info Status: Needs more info, such as a reproduction or more background for a feature request. label Mar 11, 2023
@Yakumo-Yukari
Copy link
Author

Yakumo-Yukari commented Mar 11, 2023

Hello. I suspect it panicked. Do you have a reproducible code example to share?

Also, could you run again with backtrace? Something like

$env:RUST_BACKTRACE=1; cargo run

will give us richer error information. (Use if on cmd)set RUST_BACKTRACE=1

The code that reports the error is cargo new newly created project without any changes, it reports the error when it runs, but it works fine when I don't upgrade rust

@Yakumo-Yukari
Copy link
Author

Yakumo-Yukari commented Mar 11, 2023

Hello. I suspect it panicked. Do you have a reproducible code example to share?

Also, could you run again with backtrace? Something like

$env:RUST_BACKTRACE=1; cargo run

will give us richer error information. (Use set RUST_BACKTRACE=1 if on cmd)

$ set RUST_BACKTRACE=1
$ $env:RUST_BACKTRACE=1; cargo run
bash: :RUST_BACKTRACE=1: command not found
   Compiling hellorust v0.1.0 (E:\Klee\code\hellorust)
error: could not compile `hellorust`

Caused by:
  process didn't exit successfully: `rustc --crate-name hellorust --edition=2021 'src\main.rs' --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --diagnostic-width=79 --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debuginfo=2 -C metadata=31af1aa08fb0c465 --out-dir 'E:\Klee\code\hellorust\target\debug\deps' -C 'incremental=E:\Klee\code\hellorust\target\debug\incremental' -L 'dependency=E:\Klee\code\hellorust\target\debug\deps'` (exit code: 0xc000001d, STATUS_ILLEGAL_INSTRUCTION)

set RUST_BACKTRACE=1
$env:RUST_BACKTRACE=1; cargo run

Still not working after use

@Yakumo-Yukari
Copy link
Author

I can use rustc main.rs to compile and run normally, but using cargo run, I get an error

@ehuss
Copy link
Contributor

ehuss commented Mar 11, 2023

This looks like it could be a duplicate of rust-lang/rust#108978.

Which CPU do you have?

@GregGorin
Copy link

I have the same problem. CPU AMD Phenom II X6 1090T

@weihanglo
Copy link
Member

Going to close this as rust-lang/rust#108978 states it has been resolved. I guess the latest stable (1.69) is fine. If the issue still ocurrs please reply back.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: bug S-needs-info Status: Needs more info, such as a reproduction or more background for a feature request.
Projects
None yet
Development

No branches or pull requests

4 participants