Skip to content

asm instructions only available for cortex-a and cortex-r#46

Closed
robamu wants to merge 1 commit into
mainfrom
asm-instructions-feature-gate
Closed

asm instructions only available for cortex-a and cortex-r#46
robamu wants to merge 1 commit into
mainfrom
asm-instructions-feature-gate

Conversation

@robamu

@robamu robamu commented Jul 16, 2025

Copy link
Copy Markdown
Contributor

I had a transitive dependency to cortex-ar for an auto-generator tool, and the assembler instructions were problematic.

I introduced feature-gating, similary to how it is done in cortex-m

@jonathanpallant jonathanpallant left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Should we gate the asm inside the function, or the function itself? This PR does either, randomly.

@robamu

robamu commented Jul 17, 2025

Copy link
Copy Markdown
Contributor Author

I guess I can gate all the functions. For some reason, cortex-m gated the asm inside the function for the nop function..

@robamu

robamu commented Jul 17, 2025

Copy link
Copy Markdown
Contributor Author

the asm module is already feature gated, just did not see it. But maybe the feature gate can be made cortex-ar specific?

@robamu
robamu marked this pull request as draft July 17, 2025 18:54
@jonathanpallant

Copy link
Copy Markdown
Contributor

What host were you on?

@robamu

robamu commented Jul 18, 2025

Copy link
Copy Markdown
Contributor Author

x86_64

@jonathanpallant

Copy link
Copy Markdown
Contributor

Then the module shouldn't be compiled?

@robamu

robamu commented Jul 18, 2025

Copy link
Copy Markdown
Contributor Author

Yes. I think that was a mistake on my side (I was able to solve the issue since then). I think this can be closed. Do you think a cortex-a/r specific feature gate would be useful? it would prevent using them on cortex-m, but cortex-m and cortex-ar assembler routines look really similar

@jonathanpallant

Copy link
Copy Markdown
Contributor

I don't think we need to worry about someone using cortex-ar on cortex-m.

@robamu
robamu deleted the asm-instructions-feature-gate branch July 18, 2025 14:25
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.

2 participants