Skip to content

RISCV: Backport some upstream changes #71

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

Closed
wants to merge 1 commit into from

Conversation

Ast-x64
Copy link

@Ast-x64 Ast-x64 commented Jun 28, 2022

Based on dlang#8477,
dlang#8478, and
dlang#8479.
Also adjust the order of some version conditions in std/math/hardware.d
to allow compilation using a RISCV64 port of LDC.

Based on dlang#8477,
dlang#8478, and
dlang#8479.
Also adjust the order of some version conditions in std/math/hardware.d
to allow compilation using a RISCV64 port of LDC.
version (LDC)
version (RISCV_Any)
{
mixin(`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why is a mixin used here?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your review. I'm not so sure why the previous implementation uses mixin. All I've done is moving this RISCV_Any condition above the LDC condition. It was first committed in dlang@3d84369.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IIRC, that was a problem of the dscanner linter not supporting GDC-style inline asm...

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah ok. Well it's OK. Refactoring is usually better done separately :)

kinke added a commit that referenced this pull request Feb 26, 2023
The missing relevant pieces from #71.
kinke added a commit to kinke/ldc that referenced this pull request Feb 26, 2023
kinke added a commit to ldc-developers/ldc that referenced this pull request Feb 26, 2023
@kinke
Copy link
Member

kinke commented Feb 26, 2023

I've added the missing LDC-specific asm blocks; the other stuff had already been added (I haven't checked the unittests).

@kinke kinke closed this Feb 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants