Skip to content
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

Asm support #98

Closed
ghost opened this issue Jul 9, 2010 · 3 comments
Closed

Asm support #98

ghost opened this issue Jul 9, 2010 · 3 comments
Labels
A-codegen Area: Code generation A-frontend Area: Compiler frontend (errors, parsing and HIR) A-syntaxext Area: Syntax extensions E-hard Call for participation: Hard difficulty. Experience needed to fix: A lot.

Comments

@ghost
Copy link

ghost commented Jul 9, 2010

Has Rust support for inline assembly? You known, smothing like:

[Rust code]

asm
{
[asm code]
}

[Rust code]

Thank you.

@graydon
Copy link
Contributor

graydon commented Jul 9, 2010

Yeah, we'll probably support this kind of thing as a syntax extension once we have those working sensibly in the self-hosted compiler. I'll leave this bug open to track status of the feature though, thanks for noting it.

@ghost ghost assigned espindola Jun 21, 2011
@boggle
Copy link
Contributor

boggle commented Nov 15, 2011

This goes beyond syntax translation as it involves trans. Likely this needs a way to put extra information in the ast during parsing for later use by trans. Since there is no any type currently the only way to do this in a generic fashion would be for syntax plugins to maintain their own state that maps ast node ids to whatever they need to store (i.e. asm code in strings), with any there could be an astTransExtensionNode({extName: str, payload: any}) that would be picked up by trans later on.

@z0w0
Copy link
Contributor

z0w0 commented Mar 14, 2013

Closing, as pull request #5317 added initial support - it's still being polished, but it seems to satisfy this issue.

@z0w0 z0w0 closed this as completed Mar 14, 2013
oli-obk pushed a commit to oli-obk/rust that referenced this issue Jul 19, 2017
keeperofdakeys pushed a commit to keeperofdakeys/rust that referenced this issue Dec 12, 2017
Add PATH_MAX for FreeBSDlike, defined in /usr/src/sys/sys/syslimits.h
kazcw pushed a commit to kazcw/rust that referenced this issue Oct 23, 2018
* sse4.1: _mm_blendv_ps and _mm_blendv_pd

* sse4.1: _mm_blend_ps and _mm_blend_pd

- HACK warning: messing with the constify macros
- Selecting only one buffer gets optimized away and tests need to take this into account

* sse4.1: _mm_blend_epi16

* sse4.1: _mm_extract_ps

* sse4.1: _mm_extract_epi8

* see4.1: _mm_extract_epi32

* sse4.1: _mm_extract_epi64

* sse4.1: _mm_insert_ps

* sse4.1: _mm_insert_epi8

* sse4.1: _mm_insert_epi32 and _mm_insert_epi64

* Formmating

* sse4.1: _mm_max_epi8, _mm_max_epu16, _mm_max_epi32 and _mm_max_epu32

* Fix wrong compiler flag

- avx -> sse4.1

* Fix intrinsics that only work with x86-64

* sse4.1: use appropriate types

* Revert '_mm_extract_ps' to return i32

* sse4.1: Use the v128 types for consistency

* Try fix for windows

* Try "vectorcall" calling convention

* Revert "Try "vectorcall" calling convention"

This reverts commit 12936e9976bc6b0e4e538d82f55f0ee2d87a7f25.

* Revert "Try fix for windows"

This reverts commit 9c473808d334acedd46060b32ceea116662bf6a3.

* Change tests for windows

* Remove useless Windows test
dlrobertson pushed a commit to dlrobertson/rust that referenced this issue Nov 29, 2018
Document rvalue promotion to 'static.
eddyb pushed a commit to eddyb/rust that referenced this issue Jun 30, 2020
antoyo added a commit to antoyo/rust that referenced this issue Sep 28, 2021
bors pushed a commit to rust-lang-ci/rust that referenced this issue Oct 1, 2021
celinval pushed a commit to celinval/rust-dev that referenced this issue Jun 4, 2024
* Allow cast of any pointer to cast to a trait pointer

Also:
* Add predicates `use_*_pointer(mir_type)` to use mir pointer metadata
  to identify the correct type of pointer to a mir type.
* Use predicates `use_*_pointer(mir_type)` in fat pointer construction

Resolves model-checking/kani#83

Co-authored-by: Mark R. Tuttle <mrtuttle@amazon.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-codegen Area: Code generation A-frontend Area: Compiler frontend (errors, parsing and HIR) A-syntaxext Area: Syntax extensions E-hard Call for participation: Hard difficulty. Experience needed to fix: A lot.
Projects
None yet
Development

No branches or pull requests

4 participants