about summary refs log tree commit diff
path: root/tests/ui/amdgpu-require-explicit-cpu.rs
blob: d40cb97977d94b0a95f0079435e7eb4d1b9bdd9a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
//@ revisions: nocpu cpu
//@ no-prefer-dynamic
//@ compile-flags: --crate-type=cdylib --target=amdgcn-amd-amdhsa
//@ needs-llvm-components: amdgpu
//@ needs-rust-lld
//@[nocpu] build-fail
//@[cpu] compile-flags: -Ctarget-cpu=gfx900
//@[cpu] build-pass

#![feature(no_core, lang_items)]
#![no_core]

#[lang="sized"]
trait Sized {}

pub fn foo() {}

//[nocpu]~? ERROR target requires explicitly specifying a cpu with `-C target-cpu`