Skip to content

Commit b90091e

Browse files
Jethro Beekmangnzlbg
Jethro Beekman
authored andcommitted
Add SGX target
1 parent 7fbd636 commit b90091e

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

Diff for: coresimd/x86/cpuid.rs

+6-2
Original file line numberDiff line numberDiff line change
@@ -80,11 +80,15 @@ pub unsafe fn __cpuid(leaf: u32) -> CpuidResult {
8080
/// Does the host support the `cpuid` instruction?
8181
#[inline]
8282
pub fn has_cpuid() -> bool {
83-
#[cfg(target_arch = "x86_64")]
83+
#[cfg(target_env = "sgx")]
84+
{
85+
false
86+
}
87+
#[cfg(all(not(target_env = "sgx"), target_arch = "x86_64"))]
8488
{
8589
true
8690
}
87-
#[cfg(target_arch = "x86")]
91+
#[cfg(all(not(target_env = "sgx"), target_arch = "x86"))]
8892
{
8993
// Optimization for i586 and i686 Rust targets which SSE enabled
9094
// and support cpuid:

0 commit comments

Comments
 (0)