Skip to content

Commit 46f826c

Browse files
authored
Rollup merge of #133599 - esp-rs:target/esp32s2-forced-atomics, r=Amanieu
Add `+forced-atomics` feature to esp32s2 no_std target Similar to #114499 but for the Xtensa backend. The ESP32-S2 doesn't have native atomic support, but can have atomic load/stores as part of the ISA with this LLVM codegen feature. Note: The current rev of LLVM that rustc is using doesn't contain the `+forced-atomics` feature for Xtensa, but I'm pushing this now to remove the patch from our fork in `esp-rs/rust`. r? ``@Amanieu`` because you reviewed the related RISC-V PR
2 parents ab4588a + 727f6a6 commit 46f826c

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

compiler/rustc_target/src/spec/targets/xtensa_esp32s2_none_elf.rs

+1
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ pub(crate) fn target() -> Target {
1919
cpu: "esp32-s2".into(),
2020
linker: Some("xtensa-esp32s2-elf-gcc".into()),
2121
max_atomic_width: Some(32),
22+
features: "+forced-atomics".into(),
2223
..xtensa::opts()
2324
},
2425
}

0 commit comments

Comments
 (0)