Git Product home page Git Product logo

Comments (9)

KodrAus avatar KodrAus commented on August 18, 2024 1

@guncha I think log is doing the right thing now by not concerning itself with that level of platform specific behaviour. It follows what the target_has_atomic config tells it.

It seems like there might be ongoing work in Rust to enable atomics for RISCV but I’m not across it myself. Maybe rust-lang/rust#98333 is relevant?

from log.

KodrAus avatar KodrAus commented on August 18, 2024

Thanks for the report @Anders429. It’s possible this is just a bug after I needed to apply my clumsy git-fu to split our release into two. I’ll check it out.

from log.

KodrAus avatar KodrAus commented on August 18, 2024

I do think you should probably use the racy versions of those functions, it is possible the allow-list in the old build script might have been missing this target. If this was actually intentional then we should at least call it out in our release notes.

from log.

Anders429 avatar Anders429 commented on August 18, 2024

Looks like the old build.rs file previously explicitly listed this target in the target_has_atomics() function. This was originally added in #488.

I'm not entirely sure on the atomic story for this target. Should thumbv4t-none-eabi not have been included in this list originally? The target spec does seem to indicate it should have some atomic support, but I don't know to how that fits in with the atomic support needed for log. I'm certainly not an expert on this by any means.

I'm definitely fine with just using the racy versions if that's the actual proper thing to do going forward.

from log.

KodrAus avatar KodrAus commented on August 18, 2024

Ok, it looks like this was intentional, and we were incorrectly enabling the atomic versions on thumbv4t-none-eabi, and probably others too. Our old build script was just thoroughly insufficient for target detection. Sorry about the mixup @Anders429! I'll update the release notes to call this out.

from log.

KodrAus avatar KodrAus commented on August 18, 2024

I've updated our release notes and will leave this issue open for a while for others using affected targets.

from log.

Anders429 avatar Anders429 commented on August 18, 2024

Great, thanks for the quick response!

from log.

guncha avatar guncha commented on August 18, 2024

Same issue with riscv32imc-unknown-none-elf. The target doesn't have atomic instructions, but according to the RISC-V spec for RV32I:

naturally aligned loads and stores are guaranteed to execute atomically

Which should be enough to safely update the max log level, no?

from log.

KodrAus avatar KodrAus commented on August 18, 2024

This issue has been open for a few months and we've just queued up an 0.4.20 release, so I think it's a reasonable to point to close this one now. Thanks everyone for all the input!

from log.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.